Class OnInsertSplitStreamClause
java.lang.Object
com.espertech.esper.common.client.soda.OnClause
com.espertech.esper.common.client.soda.OnInsertSplitStreamClause
- All Implemented Interfaces:
Serializable
A clause to insert into zero, one or more streams based on criteria.
- See Also:
-
Constructor Summary
ConstructorDescriptionCtor.OnInsertSplitStreamClause
(boolean isFirst, List<OnInsertSplitStreamItem> items) Ctor. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Add a insert-into, select and where-clause.static OnInsertSplitStreamClause
create()
Creates an split-stream on-insert clause considering only the first where-clause that matches.static OnInsertSplitStreamClause
create
(boolean isFirst, List<OnInsertSplitStreamItem> items) Creates a split-stream on-insert clause from an indicator whether to consider the first of all where-clauses, and a list of items.boolean
getFirst()
Returns true for firing the insert-into for only the first where-clause that matches, or false for firing the insert-into for all where-clauses that match.getItems()
Returns a list of insert-into, select and where-clauses.boolean
isFirst()
Returns true for firing the insert-into for only the first where-clause that matches, or false for firing the insert-into for all where-clauses that match.void
setFirst
(boolean first) Set to true for firing the insert-into for only the first where-clause that matches, or false for firing the insert-into for all where-clauses that match.void
setItems
(List<OnInsertSplitStreamItem> items) Sets a list of insert-into, select and where-clauses.void
toEPL
(StringWriter writer, EPStatementFormatter formatter) Renders the clause in textual representation.Methods inherited from class com.espertech.esper.common.client.soda.OnClause
createOnDelete, createOnInsertSplitStream, createOnSelect, createOnSet, createOnUpdate
-
Constructor Details
-
OnInsertSplitStreamClause
public OnInsertSplitStreamClause()Ctor. -
OnInsertSplitStreamClause
Ctor.- Parameters:
isFirst
- indicator whether only the first where-clause is to match or all where-clauses.items
- tuples of insert-into, select and where-clauses.
-
-
Method Details
-
create
public static OnInsertSplitStreamClause create(boolean isFirst, List<OnInsertSplitStreamItem> items) Creates a split-stream on-insert clause from an indicator whether to consider the first of all where-clauses, and a list of items.- Parameters:
isFirst
- true for first where-clause, false for all where-clauses fireitems
- is a list of insert-into, select and optional where-clauses- Returns:
- split-stream on-insert clause
-
create
Creates an split-stream on-insert clause considering only the first where-clause that matches.- Returns:
- split-stream on-insert clause
-
toEPL
Renders the clause in textual representation.- Parameters:
writer
- to output toformatter
- for newline-whitespace formatting
-
isFirst
public boolean isFirst()Returns true for firing the insert-into for only the first where-clause that matches, or false for firing the insert-into for all where-clauses that match.- Returns:
- indicator first or all
-
getFirst
public boolean getFirst()Returns true for firing the insert-into for only the first where-clause that matches, or false for firing the insert-into for all where-clauses that match.- Returns:
- indicator first or all
-
setFirst
public void setFirst(boolean first) Set to true for firing the insert-into for only the first where-clause that matches, or false for firing the insert-into for all where-clauses that match.- Parameters:
first
- indicator first or all
-
getItems
Returns a list of insert-into, select and where-clauses.- Returns:
- split-stream lines
-
setItems
Sets a list of insert-into, select and where-clauses.- Parameters:
items
- split-stream lines
-
addItem
Add a insert-into, select and where-clause.- Parameters:
item
- to add
-