|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectptolemy.domains.rendezvous.kernel.RendezvousReceiver.TopologicalSort
private static class RendezvousReceiver.TopologicalSort
Topological sort for the set of receivers to be committed. The
set of receivers may have dependencies among them, because
receivers in the up-stream of a Merge or Barrier must be
committed before those in the down-stream. This sort takes a
set of receivers, and returns one of them at a time in the
topological order. Cycles must not exist in the set of
receivers; Otherwise, there will be InternalErrorException
or infinite loop.
Field Summary | |
---|---|
private java.util.Set |
_receivers
The set of receivers given to the constructor. |
private java.util.Set |
_zeroInDegree
The set of receivers with zero in-degree, with can be immediately returned by next() . |
Constructor Summary | |
---|---|
RendezvousReceiver.TopologicalSort(java.util.Set receivers)
Construct a topological sort object with a set of receivers ready to commit. |
Method Summary | |
---|---|
private void |
_initialize()
Initialize the set of zero in-degree receivers. |
boolean |
hasNext()
Test whether there are more receiver to be returned. |
Receiver |
next()
Return the next receiver. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private java.util.Set _receivers
private java.util.Set _zeroInDegree
next()
.
Constructor Detail |
---|
RendezvousReceiver.TopologicalSort(java.util.Set receivers)
receivers
- The set of receivers.Method Detail |
---|
public boolean hasNext()
public Receiver next()
private void _initialize()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |