
DDEDirector |
ptolemy.domains.dde.kernel.DDEDirector |
A DDEDirector governs the execution of actors operating according to the DDE
model of computation (MoC). The DDE MoC incorporates a distributed notion of
time into a dataflow style communication semantic. Blocking reads occur if
attempts to consume data are made when the corresponding receiver is empty
and blocking writes occur if attempts to produce data are made when the
corresponding receiver is full.
<P>
In conjunction with the blocking read/write facilities, the DDE domain uses a
distributed, local notion of time. In a network of actors governed by a
DDEDirector each actor has a local notion of time. Several features of the
DDEDirector are intended to facilitate these local notions of time.
<P>
All DDE models have a completion time. The completion time is a preset time
after which all execution ceases. The completion time for a DDEDirector is
specified via the <I>stopTime</I> parameter. The value of the stopTime
parameter is passed to the receivers of all actors that the DDEDirector
governs via newReceiver() during initialize(). After initialize() has been
called, the value of stopTime can not be changed.
<P>
The default value of the stopTime parameter is
PrioritizedTimedQueue.ETERNITY. Given this value, a DDE model will continue
executing without regard for a completion time.
<P>
Deadlock due to feedback loops is dealt with via NullTokens. When an actor in
a DDE model receives a NullToken, it may advance its local time value even
though no computation results directly from consumption of the NullToken. For
models with feedback topologies, the FeedBackDelay actor should be used in
the feedback loop.
<P>
The DDE model of computation assumes that valid time stamps have non-negative
values. Three special purpose negative time values are reserved with the
following meanings. The value of PrioritizedTimedQueue.INACTIVE is reserved
to indicate the termination of a receiver. The value of
PrioritizedTimedQueue.ETERNITY is reserved to indicate that a receiver has
not begun to participate in a model's execution. The value of
PrioritizedTimedQueue.IGNORE is reserved to indicate that the current token
at the head of a DDEReceiver should be ignored in favor of the tokens
contained in the other receivers of the actor in question. More details of
IGNORE can be found in FeedBackDelay.
<P>
NOTE: The current implementation of this director does not include an
infrastructure for mutations. Hence, ChangeRequest and other facilities for
changing the topology of a model are not included in this director.
Author(s): John S. Davis II, Mudit Goel
Version:$Id: DDEDirector.doc.html,v 1.1 2006/02/22 18:40:26 mangal Exp $
Pt.Proposed Rating:Red (davisj)
Pt.Accepted Rating:Red (cxh)
stopTime
The stopTime parameter specifies the completion time of a model's
execution. During the initialize() method the value of this parameter is
passed to all receivers governed by this director. The default value of
stopTime is <I>PrioritizedTimedQueue.ETERNITY</I> indicating that
execution will continue indefinitely.