groovyx.gpars.dataflow.expression
Class DataflowExpression.DataflowExpressionsCollector

java.lang.Object
  extended by groovyx.gpars.serial.WithSerialId
      extended by groovyx.gpars.actor.impl.MessageStream
          extended by groovyx.gpars.dataflow.expression.DataflowExpression.DataflowExpressionsCollector
All Implemented Interfaces:
java.io.Serializable
Enclosing class:
DataflowExpression<T>

final class DataflowExpression.DataflowExpressionsCollector
extends MessageStream

Listener for availability of data flow expressions we depend on. Keeps a counter of monitored dataflow expressions. The counter gets decreased with each expression becoming available. Once the counter reaches 0, the Collector evaluates itself and becomes bound to the resulting value.


Nested Class Summary
 
Nested classes/interfaces inherited from class groovyx.gpars.actor.impl.MessageStream
MessageStream.RemoteMessageStream, MessageStream.SendTo
 
Field Summary
private  java.util.concurrent.atomic.AtomicInteger count
           
private static long serialVersionUID
           
 
Fields inherited from class groovyx.gpars.serial.WithSerialId
serialHandle
 
Constructor Summary
DataflowExpression.DataflowExpressionsCollector()
           
 
Method Summary
 MessageStream send(java.lang.Object message)
          Send message to stream and return immediately
(package private)  void start()
           
(package private)  java.lang.Object subscribe(java.lang.Object element)
           
 
Methods inherited from class groovyx.gpars.actor.impl.MessageStream
call, getRemoteClass, leftShift, send, send, sendAndWait, sendAndWait, sendAndWait
 
Methods inherited from class groovyx.gpars.serial.WithSerialId
createRemoteHandle, getOrCreateSerialHandle, writeReplace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

count

private final java.util.concurrent.atomic.AtomicInteger count
Constructor Detail

DataflowExpression.DataflowExpressionsCollector

DataflowExpression.DataflowExpressionsCollector()
Method Detail

send

public MessageStream send(java.lang.Object message)
Description copied from class: MessageStream
Send message to stream and return immediately

Specified by:
send in class MessageStream
Parameters:
message - message to send
Returns:
always return message stream itself

subscribe

java.lang.Object subscribe(java.lang.Object element)

start

void start()

Copyright © 2008–2012 Václav Pech. All Rights Reserved.