public class DistributedSDFDirector extends SDFDirector
A DistributedSDFDirector is the class that controls execution of actors under the distributed version of the SDF domain. It extends SDFDirector.
By default, actor scheduling is handled by the DistributedSDFScheduler class. Furthermore, the newReceiver method creates Receivers of type DistributedSDFReceiver, which extends SDFReceiver.
See ptolemy.domains.sdf.kernel.SDFScheduler for more information about the SDF Domain.
DistributedServerRMIGeneric
,
DistributedSDFReceiver
,
DistributedSDFScheduler
,
SDFDirector
,
SDFScheduler
Red (cxh) |
Red (kapokasa) |
NamedObj.ContainedObjectsIterator
Modifier and Type | Field and Description |
---|---|
(package private) java.util.HashMap |
commandsMap
Map of commands to be executed.
|
Parameter |
parallelExecution
A Parameter representing whether a sequential or parallel execution
will be performed.
|
Parameter |
parallelSchedule
A Parameter representing whether a sequential or parallel schedule
will be computed.
|
Parameter |
pipelining
A Parameter representing whether a pipelined parallel execution
will be performed.
|
_iterationCount, _periodicDirectorHelper, allowDisconnectedGraphs, allowRateChanges, AUTO_INTTOKEN, AUTO_NAME, constrainBufferSizes, iterations, ITERATIONS_NAME, period, synchronizeToRealTime, UNBOUNDED_INTTOKEN, UNBOUNDED_NAME, vectorizationFactor
_postfireReturns, _prefire
_actorsFinishedExecution, _aspectForActor, _aspectsPresent, _defaultMicrostep, _executionAspects, _finishRequested, _initializables, _nextScheduleTime, _stopRequested, _tokenSentToCommunicationAspect, _zeroTime, localClock, startTime, stopTime
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
COMPLETED, NOT_READY, STOP_ITERATING
Constructor and Description |
---|
DistributedSDFDirector()
Construct a director in the default workspace with an empty string
as its name.
|
DistributedSDFDirector(CompositeEntity container,
java.lang.String name)
Construct a director in the given container with the given name.
|
DistributedSDFDirector(Workspace workspace)
Construct a director in the workspace with an empty name.
|
Modifier and Type | Method and Description |
---|---|
void |
attributeChanged(Attribute attribute)
React to a change in an attribute.
|
void |
fire()
Calculate the current schedule, if necessary, and iterate the
contained actors in the order given by the schedule.
|
void |
initialize()
Initialize the actors associated with this director (super).
|
Receiver |
newReceiver()
Return a new receiver consistent with the Distributed-SDF domain.
|
void |
preinitialize()
Preinitialize the actors associated with this director and
compute the schedule (super).
|
void |
wrapup()
Invoke the wrapup() method of all the actors contained in the
director's container (super).
|
clone, createSchedule, fireAt, getIterations, getModelNextIterationTime, periodValue, postfire, prefire, suggestedModalModelDirectors, supportMultirateFiring, transferInputs, transferOutputs
_setScheduler, addDebugListener, getScheduler, invalidateSchedule, isScheduleValid, removeDebugListener, resumeActor, setScheduler
_actorFinished, _consultTimeRegulators, _description, _isEmbedded, _isTopLevel, _schedule, _transferInputs, _transferOutputs, addInitializable, defaultDependency, delayDependency, finish, fireAt, fireAt, fireAtCurrentTime, fireContainerAt, fireContainerAt, getCausalityInterface, getCurrentTime, getDeadline, getEnvironmentTime, getErrorTolerance, getExecutionAspect, getGlobalTime, getModelStartTime, getModelStopTime, getModelTime, getNextIterationTime, getStartTime, getStopTime, getTimeResolution, implementsStrictActorSemantics, initialize, invalidateResolvedTypes, isEmbedded, isFireFunctional, isStopRequested, isStrict, iterate, mutexLockObject, notifyTokenSentToCommunicationAspect, preinitialize, removeInitializable, requestInitialization, resume, scheduleContainedActors, setContainer, setCurrentTime, setEmbedded, setModelTime, setTimeResolution, stop, stopFire, suspend, terminate, transferOutputs
_checkContainer, _getContainedObject, _propagateExistence, getContainer, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, setName, updateContent
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _executeChangeRequests, _exportMoMLContents, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, _validateSettables, addChangeListener, addHierarchyListener, attributeDeleted, attributeList, attributeList, attributeTypeChanged, clone, containedObjectsIterator, decorators, deepContains, depthInHierarchy, description, description, event, executeChangeRequests, exportMoML, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttribute, getAttributes, getChangeListeners, getClassName, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getElementName, getFullName, getModelErrorHandler, getName, getName, getPrototypeList, getSource, handleModelError, isDeferringChangeRequests, isOverridden, isPersistent, lazyContainedObjectsIterator, message, notifyOfNameChange, propagateExistence, propagateValue, propagateValues, removeAttribute, removeChangeListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, uniqueName, validateSettables, workspace
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
isEmbedded
isFireFunctional, isStrict, iterate, stop, stopFire, terminate
addInitializable, removeInitializable
description, getContainer, getDisplayName, getFullName, getName, getName, setName
public Parameter parallelSchedule
public Parameter pipelining
public Parameter parallelExecution
java.util.HashMap commandsMap
public DistributedSDFDirector() throws IllegalActionException, NameDuplicationException
IllegalActionException
- If the name has a period in it, or
the director is not compatible with the specified container.NameDuplicationException
- If the container already contains
an entity with the specified name.public DistributedSDFDirector(Workspace workspace) throws IllegalActionException, NameDuplicationException
workspace
- The workspace for this object.IllegalActionException
- If the name has a period in it, or
the director is not compatible with the specified container.NameDuplicationException
- If the container already contains
an entity with the specified name.public DistributedSDFDirector(CompositeEntity container, java.lang.String name) throws IllegalActionException, NameDuplicationException
container
- Container of the director.name
- Name of this director.IllegalActionException
- If the director is not compatible
with the specified container. May be thrown in a derived class.NameDuplicationException
- If the container is not a
CompositeActor and the name collides with an entity in the container.public void attributeChanged(Attribute attribute) throws IllegalActionException
attributeChanged
in class SDFDirector
attribute
- The changed parameter.IllegalActionException
- If the parameter set is not valid.public void fire() throws IllegalActionException
Iterating an actor involves calling the actor's iterate() method, which is equivalent to calling the actor's prefire(), fire() and postfire() methods in succession. If iterate() returns NOT_READY, indicating that the actor is not ready to execute, then an IllegalActionException will be thrown. The values returned from iterate() are recorded and are used to determine the value that postfire() will return at the end of the director's iteration.
This method may be overridden by some domains to perform additional domain-specific operations.
fire
in interface Executable
fire
in class SDFDirector
IllegalActionException
- If any actor executed by this
actor return false in prefire.public void initialize() throws IllegalActionException
initialize
in interface Initializable
initialize
in class SDFDirector
IllegalActionException
- If the initialize() method of
one of the associated actors throws it, or if there is no
scheduler.public Receiver newReceiver()
newReceiver
in class SDFDirector
public void preinitialize() throws IllegalActionException
preinitialize
in interface Initializable
preinitialize
in class SDFDirector
IllegalActionException
- If the preinitialize() method of
one of the associated actors throws it.public void wrapup() throws IllegalActionException
wrapup
in interface Initializable
wrapup
in class Director
IllegalActionException
- If the wrapup() method of
one of the associated actors throws it.ClientThread