Fennel: ExecStreamBuilder Class Reference (original) (raw)

ExecStreamBuilder builds a prepared ExecStreamGraph from its Java representation. More...

#include <[ExecStreamBuilder.h](ExecStreamBuilder%5F8h-source.html)>

List of all members.

Public Member Functions
ExecStreamBuilder (ExecStreamGraphEmbryo &graphEmbryo, ExecStreamFactory &streamFactory)
Creates a new ExecStreamBuilder.
virtual ~ExecStreamBuilder ()
void buildStreamGraph (ProxyCmdPrepareExecutionStreamGraph &cmd, bool assumeOutputFromSinks)
Main builder entry point.
Private Member Functions
void buildStream (ProxyExecutionStreamDef &)
Allocates a stream based on stream definition, adds the stream to a graph and records how to prepare the stream.
void buildStreamInputs (ProxyExecutionStreamDef &streamDef)
Adds dataflows between a stream and its inputs, in the case where the source input has only one output.
int getExplicitOutputCount (ProxyExecutionStreamDef &streamDef)
**Returns:**number of explicit dataflow outputs from a stream
void buildStreamOutputs (ProxyExecutionStreamDef &streamDef)
Adds dataflows between a stream and its outputs, preserving order in the case where a stream has multiple outputs.
Private Attributes
ExecStreamGraphEmbryo & graphEmbryo
Embryo for graph being built up.
ExecStreamFactory & streamFactory
Factory for creating ExecStream objects.

Detailed Description

ExecStreamBuilder builds a prepared ExecStreamGraph from its Java representation.

It builds a graph in three phases:

Cache. A new scratch segment is allocated by the builder and is shared between the graph and its streams.

Tracing. All streams are assigned a trace name of: xo._streamName_ Depending on a the TraceTarget, this typically corresponds to a trace property like org.eigenbase.fennel.xo._streamName_

Buffer Provisioning. Provisioning adapters are special streams interposed between two other streams when the producer's result provisioning does not meet the consumer's input requirements. They are interposed during the dataflow phase. They are named: _producerName_.provisioner

Interposition. When provisioning adapters are appended to a stream, they consume the original stream's output and produce a new output. To make the appended streams work transparently, the chain of streams is treated as a single unit. Subsequent access to the stream's output is available through the graph by finding the "last" stream registered under the original stream's name.

Definition at line 71 of file ExecStreamBuilder.h.


Constructor & Destructor Documentation

| ExecStreamBuilder::~ExecStreamBuilder | ( | | ) | [virtual] | | -------------------------------------- | - | | - | ----------- |


Member Function Documentation

Main builder entry point.

Parameters:

cmd Java representation for command containing collection of stream definitions
assumeOutputFromSinks if true, sinks in the graph are assumed to be dataflow output nodes; if false, sinks in the graph are not treated specially

Definition at line 44 of file ExecStreamBuilder.cpp.

References ExecStreamGraphEmbryo::addAdapterFor(), ExecStreamGraph::addOutputDataflow(), BUFPROV_PRODUCER, buildStream(), buildStreamInputs(), buildStreamOutputs(), ExecStreamFactory::getDatabase(), getExplicitOutputCount(), ExecStreamGraphEmbryo::getGraph(), ExecStreamGraphEmbryo::getScratchAccessor(), ProxyCmdPrepareExecutionStreamGraph::getStreamDefs(), graphEmbryo, ExecStreamGraphEmbryo::prepareGraph(), ExecStreamFactory::setScratchAccessor(), and streamFactory.

Referenced by CmdInterpreter::visit().


Member Data Documentation


The documentation for this class was generated from the following files:


Generated on Mon Jun 22 04:00:30 2009 for Fennel by doxygen 1.5.1