net.esper.eql.join.assemble
Class CartesianProdAssemblyNode

java.lang.Object
  extended by net.esper.eql.join.assemble.BaseAssemblyNode
      extended by net.esper.eql.join.assemble.CartesianProdAssemblyNode
All Implemented Interfaces:
ResultAssembler

public class CartesianProdAssemblyNode
extends BaseAssemblyNode

Assembly node for an event stream that is a branch with a two or more child nodes (required and optional) below it.


Nested Class Summary
static class CartesianProdAssemblyNode.ChildStreamResults
          Structure to represent a list of event result rows per stream.
 
Field Summary
 
Fields inherited from class net.esper.eql.join.assemble.BaseAssemblyNode
childNodes, numStreams, parentNode, streamNum
 
Constructor Summary
CartesianProdAssemblyNode(int streamNum, int numStreams, boolean allSubStreamsOptional)
          Ctor.
 
Method Summary
 void addChild(BaseAssemblyNode childNode)
          Add a child node.
 void init(java.util.List<Node>[] result)
          Provides results to assembly nodes for initialization.
 void print(IndentWriter indentWriter)
          Output this node using writer, not outputting child nodes.
 void process(java.util.List<Node>[] result)
          Process results.
 void result(EventBean[] row, int fromStreamNum, EventBean myEvent, Node myNode)
          Publish a result row.
 
Methods inherited from class net.esper.eql.join.assemble.BaseAssemblyNode
getChildNodes, getDescendentNodesBottomUp, getParentAssembler, getStreamNum, getSubstreams, printDescendends, setParentAssembler
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CartesianProdAssemblyNode

public CartesianProdAssemblyNode(int streamNum,
                                 int numStreams,
                                 boolean allSubStreamsOptional)
Ctor.

Parameters:
streamNum - - is the stream number
numStreams - - is the number of streams
allSubStreamsOptional - - true if all child nodes to this node are optional, or false if one or more child nodes are required for a result.
Method Detail

addChild

public void addChild(BaseAssemblyNode childNode)
Description copied from class: BaseAssemblyNode
Add a child node.

Overrides:
addChild in class BaseAssemblyNode
Parameters:
childNode - to add

init

public void init(java.util.List<Node>[] result)
Description copied from class: BaseAssemblyNode
Provides results to assembly nodes for initialization.

Specified by:
init in class BaseAssemblyNode
Parameters:
result - is a list of result nodes per stream

process

public void process(java.util.List<Node>[] result)
Description copied from class: BaseAssemblyNode
Process results.

Specified by:
process in class BaseAssemblyNode
Parameters:
result - is a list of result nodes per stream

result

public void result(EventBean[] row,
                   int fromStreamNum,
                   EventBean myEvent,
                   Node myNode)
Description copied from interface: ResultAssembler
Publish a result row.

Parameters:
row - is the result to publish
fromStreamNum - is the originitor that publishes the row
myEvent - is optional and is the event that led to the row result
myNode - is optional and is the result node of the event that led to the row result

print

public void print(IndentWriter indentWriter)
Description copied from class: BaseAssemblyNode
Output this node using writer, not outputting child nodes.

Specified by:
print in class BaseAssemblyNode
Parameters:
indentWriter - to use for output