|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.farrago.fennel.FennelStreamGraph
public class FennelStreamGraph
FennelStreamGraphs are FarragoAllocations for FemStreamGraphHandles.
Field Summary | |
---|---|
private FennelDbHandle |
fennelDbHandle
|
private long |
streamGraphHandle
|
private static Logger |
tracer
|
Constructor Summary | |
---|---|
FennelStreamGraph(FennelDbHandle fennelDbHandle,
FemStreamGraphHandle streamGraphHandle)
|
Method Summary | |
---|---|
void |
abort()
Aborts the current execution (but does not close the graph). |
void |
close()
Closes the stream graph (but does not deallocate it). |
void |
closeAllocation()
Closes this object. |
int |
fetch(FennelStreamHandle streamHandle,
byte[] byteArray)
Fetches a buffer of rows from a stream. |
FennelStreamHandle |
findStream(FarragoMetadataFactory metadataFactory,
String streamName,
boolean isInput)
Finds a particular stream within the graph. |
String[] |
getInputStreams(String streamName)
Find the inputs of a specified stream in the graph. |
long |
getLongHandle()
|
FemStreamGraphHandle |
getStreamGraphHandle()
|
void |
open(FennelTxnContext fennelTxnContext,
FennelJavaStreamMap javaStreamMap,
FennelJavaErrorTarget javaErrorTarget)
Opens a prepared stream graph. |
void |
restart(FennelStreamHandle streamHandle)
Restarts a particular stream in this graph. |
private void |
traceGraphHandle(String operation)
|
private void |
traceStreamHandle(String operation,
FennelStreamHandle streamHandle)
|
private void |
traceStreamHandle(String operation,
FennelStreamHandle streamHandle,
int execStreamInputOrdinal)
|
int |
transformFetch(FennelStreamHandle streamHandle,
int execStreamInputOrdinal,
byte[] byteArray)
Fetches a buffer of rows from a stream. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final Logger tracer
private final FennelDbHandle fennelDbHandle
private long streamGraphHandle
Constructor Detail |
---|
FennelStreamGraph(FennelDbHandle fennelDbHandle, FemStreamGraphHandle streamGraphHandle)
Method Detail |
---|
public FennelStreamHandle findStream(FarragoMetadataFactory metadataFactory, String streamName, boolean isInput)
metadataFactory
- factory for creating Fem instancesstreamName
- name of stream to findisInput
-
public String[] getInputStreams(String streamName)
streamName
- names a stream
public FemStreamGraphHandle getStreamGraphHandle()
public long getLongHandle()
private void traceGraphHandle(String operation)
private void traceStreamHandle(String operation, FennelStreamHandle streamHandle)
private void traceStreamHandle(String operation, FennelStreamHandle streamHandle, int execStreamInputOrdinal)
public void open(FennelTxnContext fennelTxnContext, FennelJavaStreamMap javaStreamMap, FennelJavaErrorTarget javaErrorTarget)
fennelTxnContext
- transaction context in which stream graph should
participatejavaStreamMap
- optional FennelJavaStreamMapjavaErrorTarget
- error target handles row errorspublic int fetch(FennelStreamHandle streamHandle, byte[] byteArray)
streamHandle
- handle to stream from which to fetchbyteArray
- output buffer receives complete tuples
public int transformFetch(FennelStreamHandle streamHandle, int execStreamInputOrdinal, byte[] byteArray)
streamHandle
- handle to JavaTransformExecStream from which to fetchexecStreamInputOrdinal
- ordinal of the stream's inputbyteArray
- output buffer receives complete tuples
public void close()
public void abort()
public void closeAllocation()
ClosableAllocation
closeAllocation
in interface ClosableAllocation
public void restart(FennelStreamHandle streamHandle)
streamHandle
- handle to stream to restart
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |