com.espertech.esper.client.soda
Class OnMergeClause

java.lang.Object
  extended by com.espertech.esper.client.soda.OnClause
      extended by com.espertech.esper.client.soda.OnMergeClause
All Implemented Interfaces:
java.io.Serializable

public class OnMergeClause
extends OnClause

A clause to insert, update or delete to/from a named window based on a triggering event arriving and correlated to the named window events to be updated.

See Also:
Serialized Form

Constructor Summary
OnMergeClause()
          Ctor.
OnMergeClause(java.lang.String windowName, java.lang.String optionalAsName, java.util.List<OnMergeMatchItem> matchItems)
          Ctor.
 
Method Summary
 OnMergeClause addAction(OnMergeMatchItem action)
          Add a new action to the list of actions.
static OnMergeClause create(java.lang.String windowName, java.lang.String optionalAsName, java.util.List<OnMergeMatchItem> matchItems)
          Creates an on-update clause.
 java.util.List<OnMergeMatchItem> getMatchItems()
          Returns all actions.
 java.lang.String getOptionalAsName()
          Returns the as-provided name for the named window.
 java.lang.String getWindowName()
          Returns the name of the named window to update.
 void setMatchItems(java.util.List<OnMergeMatchItem> matchItems)
          Sets all actions.
 void setOptionalAsName(java.lang.String optionalAsName)
          Sets the as-provided for the named window.
 void setWindowName(java.lang.String windowName)
          Sets the name of the named window.
 void toEPL(java.io.StringWriter writer, Expression optionalWhereClause, EPStatementFormatter formatter)
          Renders the clause in textual representation.
 
Methods inherited from class com.espertech.esper.client.soda.OnClause
createOnDelete, createOnInsertSplitStream, createOnSelect, createOnSet, createOnUpdate
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

OnMergeClause

public OnMergeClause()
Ctor.


OnMergeClause

public OnMergeClause(java.lang.String windowName,
                     java.lang.String optionalAsName,
                     java.util.List<OnMergeMatchItem> matchItems)
Ctor.

Parameters:
windowName - is the named window name
optionalAsName - is the as-provided name of the named window
matchItems - is the matched and non-matched action items
Method Detail

create

public static OnMergeClause create(java.lang.String windowName,
                                   java.lang.String optionalAsName,
                                   java.util.List<OnMergeMatchItem> matchItems)
Creates an on-update clause.

Parameters:
windowName - is the named window name
optionalAsName - is the optional as-provided name
matchItems - is the matched and non-matched action items
Returns:
on-update clause without assignments

toEPL

public void toEPL(java.io.StringWriter writer,
                  Expression optionalWhereClause,
                  EPStatementFormatter formatter)
Renders the clause in textual representation.

Parameters:
writer - to output to
optionalWhereClause - where clause if present, or null
formatter - for newline-whitespace formatting

getWindowName

public java.lang.String getWindowName()
Returns the name of the named window to update.

Returns:
named window name

setWindowName

public void setWindowName(java.lang.String windowName)
Sets the name of the named window.

Parameters:
windowName - window name

getOptionalAsName

public java.lang.String getOptionalAsName()
Returns the as-provided name for the named window.

Returns:
name or null

setOptionalAsName

public void setOptionalAsName(java.lang.String optionalAsName)
Sets the as-provided for the named window.

Parameters:
optionalAsName - name to set for window

addAction

public OnMergeClause addAction(OnMergeMatchItem action)
Add a new action to the list of actions.

Parameters:
action - to add
Returns:
clause

getMatchItems

public java.util.List<OnMergeMatchItem> getMatchItems()
Returns all actions.

Returns:
actions

setMatchItems

public void setMatchItems(java.util.List<OnMergeMatchItem> matchItems)
Sets all actions.

Parameters:
matchItems - to set

© 2006-2015 EsperTech Inc.
All rights reserved.
Visit us at espertech.com