|
org.codehaus.gpars | |||||||
FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object groovyx.gpars.dataflow.stream.DataflowStreamReadAdapter
@java.lang.SuppressWarningsthis.head.addUpdateListener(new DataflowChannelListener() { public class DataflowStreamReadAdapter
Adapts a DataflowStream to accommodate for the DataflowReadChannel interface. To minimize the overhead and stay in-line with the DataflowStream semantics, the DataflowStreamReadAdapter class is not thread-safe and should only be used from within a single thread. If multiple threads need to read from a DataflowStream, they should each create their own wrapping DataflowStreamReadAdapter.
- The type of messages to pass through the streamField Summary | |
---|---|
private StreamCore |
asyncHead
|
private DataflowChannelEventOrchestrator |
eventManager
|
private StreamCore |
head
|
Constructor Summary | |
DataflowStreamReadAdapter(StreamCore stream)
|
Method Summary | |
---|---|
protected java.util.List
|
allUnprocessedDFVs()
|
void
|
binaryChoice(DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
|
void
|
binaryChoice(Pool pool, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
|
void
|
binaryChoice(PGroup group, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
|
void
|
binaryChoice(java.util.Map params, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
|
void
|
binaryChoice(Pool pool, java.util.Map params, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
|
void
|
binaryChoice(PGroup group, java.util.Map params, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
|
DataflowReadChannel
|
chainWith(groovy.lang.Closure closure)
|
DataflowReadChannel
|
chainWith(Pool pool, groovy.lang.Closure closure)
|
DataflowReadChannel
|
chainWith(PGroup group, groovy.lang.Closure closure)
|
DataflowReadChannel
|
chainWith(java.util.Map params, groovy.lang.Closure closure)
|
DataflowReadChannel
|
chainWith(Pool pool, java.util.Map params, groovy.lang.Closure closure)
|
DataflowReadChannel
|
chainWith(PGroup group, java.util.Map params, groovy.lang.Closure closure)
|
void
|
choice(java.util.List outputs, groovy.lang.Closure code)
|
void
|
choice(Pool pool, java.util.List outputs, groovy.lang.Closure code)
|
void
|
choice(PGroup group, java.util.List outputs, groovy.lang.Closure code)
|
void
|
choice(java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
|
void
|
choice(Pool pool, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
|
void
|
choice(PGroup group, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
|
DataflowReadChannel
|
filter(groovy.lang.Closure closure)
|
DataflowReadChannel
|
filter(Pool pool, groovy.lang.Closure closure)
|
DataflowReadChannel
|
filter(PGroup group, groovy.lang.Closure closure)
|
DataflowReadChannel
|
filter(java.util.Map params, groovy.lang.Closure closure)
|
DataflowReadChannel
|
filter(Pool pool, java.util.Map params, groovy.lang.Closure closure)
|
DataflowReadChannel
|
filter(PGroup group, java.util.Map params, groovy.lang.Closure closure)
|
private void
|
fireOnMessage(java.lang.Object value)
|
DataflowChannelEventListenerManager
|
getEventManager()
|
java.lang.Object
|
getVal()
|
java.lang.Object
|
getVal(long timeout, java.util.concurrent.TimeUnit units)
|
void
|
getValAsync(MessageStream callback)
|
void
|
getValAsync(java.lang.Object attachment, MessageStream callback)
|
void
|
into(DataflowWriteChannel target)
|
void
|
into(Pool pool, DataflowWriteChannel target)
|
void
|
into(PGroup group, DataflowWriteChannel target)
|
void
|
into(java.util.Map params, DataflowWriteChannel target)
|
void
|
into(Pool pool, java.util.Map params, DataflowWriteChannel target)
|
void
|
into(PGroup group, java.util.Map params, DataflowWriteChannel target)
|
boolean
|
isBound()
|
java.util.Iterator
|
iterator()
|
int
|
length()
|
DataflowReadChannel
|
merge(DataflowReadChannel other, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(Pool pool, DataflowReadChannel other, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(PGroup group, DataflowReadChannel other, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(java.util.List others, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(Pool pool, java.util.List others, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(PGroup group, java.util.List others, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(java.util.Map params, DataflowReadChannel other, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(Pool pool, java.util.Map params, DataflowReadChannel other, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(PGroup group, java.util.Map params, DataflowReadChannel other, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(java.util.Map params, java.util.List others, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(Pool pool, java.util.Map params, java.util.List others, groovy.lang.Closure closure)
|
DataflowReadChannel
|
merge(PGroup group, java.util.Map params, java.util.List others, groovy.lang.Closure closure)
|
private void
|
moveAsyncHead()
|
private void
|
moveHead()
|
DataflowReadChannel
|
or(groovy.lang.Closure closure)
|
void
|
or(DataflowWriteChannel target)
|
DataflowExpression
|
poll()
|
Promise
|
rightShift(groovy.lang.Closure closure)
|
void
|
separate(java.util.List outputs, groovy.lang.Closure code)
|
void
|
separate(Pool pool, java.util.List outputs, groovy.lang.Closure code)
|
void
|
separate(PGroup group, java.util.List outputs, groovy.lang.Closure code)
|
void
|
separate(java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
|
void
|
separate(Pool pool, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
|
void
|
separate(PGroup group, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
|
private boolean
|
shouldReportTimeout()
|
void
|
split(DataflowWriteChannel target1, DataflowWriteChannel target2)
|
void
|
split(Pool pool, DataflowWriteChannel target1, DataflowWriteChannel target2)
|
void
|
split(PGroup group, DataflowWriteChannel target1, DataflowWriteChannel target2)
|
void
|
split(java.util.List targets)
|
void
|
split(Pool pool, java.util.List targets)
|
void
|
split(PGroup group, java.util.List targets)
|
void
|
split(java.util.Map params, DataflowWriteChannel target1, DataflowWriteChannel target2)
|
void
|
split(Pool pool, java.util.Map params, DataflowWriteChannel target1, DataflowWriteChannel target2)
|
void
|
split(PGroup group, java.util.Map params, DataflowWriteChannel target1, DataflowWriteChannel target2)
|
void
|
split(java.util.Map params, java.util.List targets)
|
void
|
split(Pool pool, java.util.Map params, java.util.List targets)
|
void
|
split(PGroup group, java.util.Map params, java.util.List targets)
|
DataflowReadChannel
|
tap(DataflowWriteChannel target)
|
DataflowReadChannel
|
tap(Pool pool, DataflowWriteChannel target)
|
DataflowReadChannel
|
tap(PGroup group, DataflowWriteChannel target)
|
DataflowReadChannel
|
tap(java.util.Map params, DataflowWriteChannel target)
|
DataflowReadChannel
|
tap(Pool pool, java.util.Map params, DataflowWriteChannel target)
|
DataflowReadChannel
|
tap(PGroup group, java.util.Map params, DataflowWriteChannel target)
|
Promise
|
then(groovy.lang.Closure closure)
|
Promise
|
then(Pool pool, groovy.lang.Closure closure)
|
Promise
|
then(PGroup group, groovy.lang.Closure closure)
|
java.lang.String
|
toString()
|
void
|
whenBound(groovy.lang.Closure closure)
|
void
|
whenBound(Pool pool, groovy.lang.Closure closure)
|
void
|
whenBound(PGroup group, groovy.lang.Closure closure)
|
void
|
whenBound(MessageStream stream)
|
void
|
wheneverBound(groovy.lang.Closure closure)
|
void
|
wheneverBound(MessageStream stream)
|
Methods inherited from class java.lang.Object | |
---|---|
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Field Detail |
---|
private StreamCore asyncHead
private DataflowChannelEventOrchestrator eventManager
private StreamCore head
Constructor Detail |
---|
public DataflowStreamReadAdapter(StreamCore stream)
Method Detail |
---|
protected final java.util.List allUnprocessedDFVs()
@java.lang.Override public void binaryChoice(DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
@java.lang.Override public void binaryChoice(Pool pool, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
@java.lang.Override public void binaryChoice(PGroup group, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
@java.lang.Override public void binaryChoice(java.util.Map params, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
@java.lang.Overridepublic void choice(final List> outputs, final Closure code) { public void binaryChoice(Pool pool, java.util.Map params, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
@java.lang.Overridepublic void choice(final Pool pool, final List> outputs, final Closure code) { public void binaryChoice(PGroup group, java.util.Map params, DataflowWriteChannel trueBranch, DataflowWriteChannel falseBranch, groovy.lang.Closure code)
@java.lang.Override} public final DataflowReadChannel chainWith(groovy.lang.Closure closure)
@java.lang.Override} public final DataflowReadChannel chainWith(Pool pool, groovy.lang.Closure closure)
@java.lang.Override} public DataflowReadChannel chainWith(PGroup group, groovy.lang.Closure closure)
@java.lang.Overrideparameters.put("outputs", asList(result)); public final DataflowReadChannel chainWith(java.util.Map params, groovy.lang.Closure closure)
@java.lang.Override public final DataflowReadChannel chainWith(Pool pool, java.util.Map params, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel chainWith(PGroup group, java.util.Map params, groovy.lang.Closure closure)
@java.lang.Override public void choice(java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void choice(Pool pool, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void choice(PGroup group, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void choice(java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Overridepublic void separate(final List> outputs, final Closure > code) { public void choice(Pool pool, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Overridepublic void separate(final Pool pool, final List> outputs, final Closure > code) { public void choice(PGroup group, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public DataflowReadChannel filter(groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel filter(Pool pool, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel filter(PGroup group, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel filter(java.util.Map params, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel filter(Pool pool, java.util.Map params, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel filter(PGroup group, java.util.Map params, groovy.lang.Closure closure)
private void fireOnMessage(java.lang.Object value)
@java.lang.Overridereturn head.getFirstDFV().isBound(); public DataflowChannelEventListenerManager getEventManager()
@java.lang.OverridemoveHead(); public java.lang.Object getVal()
@java.lang.Override} public java.lang.Object getVal(long timeout, java.util.concurrent.TimeUnit units)
@java.lang.Override} public void getValAsync(MessageStream callback)
@java.lang.Override} public void getValAsync(java.lang.Object attachment, MessageStream callback)
@java.lang.Override public void into(DataflowWriteChannel target)
@java.lang.Override public void into(Pool pool, DataflowWriteChannel target)
@java.lang.Override public void into(PGroup group, DataflowWriteChannel target)
@java.lang.Overridegroup.operator(parameters, new ChainWithClosure(new CopyChannelsClosure())); public void into(java.util.Map params, DataflowWriteChannel target)
@java.lang.Overrideinto(target); public void into(Pool pool, java.util.Map params, DataflowWriteChannel target)
@java.lang.Overridesplit(Dataflow.retrieveCurrentDFPGroup(), target1, target2); public void into(PGroup group, java.util.Map params, DataflowWriteChannel target)
@java.lang.Overridelength += 1; public boolean isBound()
public java.util.Iterator iterator()
@java.lang.OverridemoveHead(); public int length()
@java.lang.Override public DataflowReadChannel merge(DataflowReadChannel other, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(Pool pool, DataflowReadChannel other, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(PGroup group, DataflowReadChannel other, groovy.lang.Closure closure)
@java.lang.Overrideinputs.addAll(others); public DataflowReadChannel merge(java.util.List others, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(Pool pool, java.util.List others, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(PGroup group, java.util.List others, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(java.util.Map params, DataflowReadChannel other, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(Pool pool, java.util.Map params, DataflowReadChannel other, groovy.lang.Closure closure)
@java.lang.Override public DataflowReadChannel merge(PGroup group, java.util.Map params, DataflowReadChannel other, groovy.lang.Closure closure)
@java.lang.Overrideinputs.addAll(others); public DataflowReadChannel merge(java.util.Map params, java.util.List others, groovy.lang.Closure closure)
@java.lang.Overridereturn result; public DataflowReadChannel merge(Pool pool, java.util.Map params, java.util.List others, groovy.lang.Closure closure)
@java.lang.OverridebinaryChoice(Dataflow.retrieveCurrentDFPGroup(), trueBranch, falseBranch, code); public DataflowReadChannel merge(PGroup group, java.util.Map params, java.util.List others, groovy.lang.Closure closure)
private void moveAsyncHead()
private void moveHead()
@java.lang.Override public DataflowReadChannel or(groovy.lang.Closure closure)
@java.lang.Override public void or(DataflowWriteChannel target)
@java.lang.Override} public DataflowExpression poll()
@java.lang.Override* public Promise rightShift(groovy.lang.Closure closure)
@java.lang.Override public void separate(java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void separate(Pool pool, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void separate(PGroup group, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void separate(java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Override public void separate(Pool pool, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
@java.lang.Overridereturn eventManager; public void separate(PGroup group, java.util.Map params, java.util.List outputs, groovy.lang.Closure code)
private boolean shouldReportTimeout()
@java.lang.Override public void split(DataflowWriteChannel target1, DataflowWriteChannel target2)
@java.lang.Override public void split(Pool pool, DataflowWriteChannel target1, DataflowWriteChannel target2)
@java.lang.Override public void split(PGroup group, DataflowWriteChannel target1, DataflowWriteChannel target2)
@java.lang.Override public void split(java.util.List targets)
@java.lang.Override public void split(Pool pool, java.util.List targets)
@java.lang.Override public void split(PGroup group, java.util.List targets)
@java.lang.Override public void split(java.util.Map params, DataflowWriteChannel target1, DataflowWriteChannel target2)
@java.lang.Override public void split(Pool pool, java.util.Map params, DataflowWriteChannel target1, DataflowWriteChannel target2)
@java.lang.Override public void split(PGroup group, java.util.Map params, DataflowWriteChannel target1, DataflowWriteChannel target2)
@java.lang.Override public void split(java.util.Map params, java.util.List targets)
@java.lang.Overridepublic DataflowReadChanneltap(final DataflowWriteChannel target) { public void split(Pool pool, java.util.Map params, java.util.List targets)
@java.lang.Overridepublic DataflowReadChanneltap(final Pool pool, final DataflowWriteChannel target) { public void split(PGroup group, java.util.Map params, java.util.List targets)
@java.lang.Override} public DataflowReadChannel tap(DataflowWriteChannel target)
@java.lang.Override} public DataflowReadChannel tap(Pool pool, DataflowWriteChannel target)
@java.lang.Override} public DataflowReadChannel tap(PGroup group, DataflowWriteChannel target)
@java.lang.Overrideparameters.put("outputs", asList(result, target)); public DataflowReadChannel tap(java.util.Map params, DataflowWriteChannel target)
@java.lang.Override public DataflowReadChannel tap(Pool pool, java.util.Map params, DataflowWriteChannel target)
@java.lang.Override public DataflowReadChannel tap(PGroup group, java.util.Map params, DataflowWriteChannel target)
@java.lang.Override*/ public final Promise then(groovy.lang.Closure closure)
@java.lang.Override*/ public Promise then(Pool pool, groovy.lang.Closure closure)
@java.lang.Override} public Promise then(PGroup group, groovy.lang.Closure closure)
@java.lang.SuppressWarningsfinal T value = head.getFirstDFV().getVal(timeout, units); @java.lang.Overrideif (value == null) { public final java.lang.String toString()
@java.lang.Overridepublicvoid whenBound(final Pool pool, final Closure closure) { public void whenBound(groovy.lang.Closure closure)
@java.lang.OverridemoveAsyncHead(); public void whenBound(Pool pool, groovy.lang.Closure closure)
@java.lang.Override* will not happen immediately but will be scheduled public void whenBound(PGroup group, groovy.lang.Closure closure)
@java.lang.Overridepublic finalPromise then(final Closure closure) { public void whenBound(MessageStream stream)
@java.lang.Override public void wheneverBound(groovy.lang.Closure closure)
@java.lang.Override public void wheneverBound(MessageStream stream)
Copyright © 2008–2013 Václav Pech. All Rights Reserved.