public class LifeCycleManager extends TypedCompositeActor
ModelReference
,
SetVariable
Red (eal) |
Yellow (eal) |
CompositeEntity.ContainedObjectsIterator
_actorFiringListeners, _causalityInterface, _derivedPiggybacks, _initializables, _notifyingActorFiring, _piggybacks, _publishedPorts, _publisherRelations, _stopRequested, _subscribedPorts
_levelCrossingLinks
_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 |
---|
LifeCycleManager()
Construct an actor in the default workspace with no
container and an empty string as its name.
|
LifeCycleManager(CompositeEntity container,
java.lang.String name)
Construct a LifeCycleManager with a name and a container.
|
LifeCycleManager(Workspace workspace)
Construct a LifeCycleManager in the specified workspace with
no container and an empty string as a name.
|
Modifier and Type | Method and Description |
---|---|
protected int |
_executeInsideModel()
Run a complete execution of the contained model.
|
protected void |
_fireInsideModel()
Invoke the fire() method of its local director.
|
protected TypedCompositeActor |
_getManagedActor()
Return the actor whose life cycle is being managed by this actor.
|
protected void |
_readInputs()
Iterate over input ports and read any available values into
the referenced model parameters.
|
protected void |
_writeOutputs()
Iterate over output ports and read any available values from
the referenced model parameters and produce them on the outputs.
|
void |
addChangeListener(ChangeListener listener)
Override the base class to delegate to the container AND
also record the listener locally.
|
void |
executeChangeRequests()
Override the base class to not delegate up the hierarchy
but rather to handle the request locally.
|
boolean |
isDeferringChangeRequests()
Override the base class to not delegate to the container.
|
void |
removeChangeListener(ChangeListener listener)
Override the base class to remove the listener in
the container AND locally.
|
void |
requestChange(ChangeRequest change)
Override the base class to not delegate up the hierarchy.
|
void |
setDeferringChangeRequests(boolean isDeferring)
Override the base class to not delegate to the container.
|
_addEntity, _addPort, _addRelation, _checkTypesFromTo, _destinationTypeConstraints, attributeChanged, attributeTypeChanged, isBackwardTypeInferenceEnabled, newPort, newRelation, resolveTypes, typeConstraintList, typeConstraints
_actorFiring, _actorFiring, _finishedAddEntity, _setDirector, _transferPortParameterInputs, addActorFiringListener, addInitializable, addPiggyback, clone, connectionsChanged, createReceivers, createSchedule, fire, getCausalityInterface, getDirector, getExecutiveDirector, getManager, getPublishedPort, getPublishedPortChannel, getPublishedPorts, getSubscribedPortChannel, inferringWidths, inferWidths, initialize, inputPortList, isFireFunctional, isOpaque, isPublishedPort, isStrict, iterate, linkToPublishedPort, linkToPublishedPort, linkToPublishedPort, linkToPublishedPort, needsWidthInference, newInsideReceiver, newReceiver, notifyConnectivityChange, outputPortList, postfire, prefire, preinitialize, recordFiring, registerPublisherPort, registerPublisherPort, removeActorFiringListener, removeInitializable, removePiggyback, setContainer, setDirector, setManager, stop, stopFire, terminate, unlinkToPublishedPort, unlinkToPublishedPort, unlinkToPublishedPort, unlinkToPublishedPort, unregisterPublisherPort, unregisterPublisherPort, wrapup
_adjustDeferrals, _containedDecorators, _deepOpaqueEntityList, _description, _exportMoMLContents, _removeEntity, _removeRelation, _validateSettables, allAtomicEntityList, allowLevelCrossingConnect, classDefinitionList, connect, connect, containedObjectsIterator, deepCompositeEntityList, deepEntityList, deepGetEntities, deepNamedObjList, deepOpaqueEntityList, deepRelationSet, entityList, entityList, exportLinks, exportMoML, getAttribute, getEntities, getEntity, getPort, getRelation, getRelations, isAtomic, lazyAllAtomicEntityList, lazyAllCompositeEntityList, lazyAllCompositeTransparentAndOpaqueEntityList, lazyClassDefinitionList, lazyDeepEntityList, lazyEntityList, lazyRelationList, numberOfEntities, numberOfRelations, numEntities, numRelations, relationList, removeAllEntities, removeAllRelations, setClassDefinition, statistics, uniqueName
_checkContainer, _getContainedObject, _propagateExistence, getContainer, instantiate, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, propagateExistence, setName
_removePort, connectedPortList, connectedPorts, getPorts, linkedRelationList, linkedRelations, portList, removeAllPorts
_setParent, getChildren, getElementName, getParent, getPrototypeList, isClassDefinition, isWithinClassDefinition
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _executeChangeRequests, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, addDebugListener, addHierarchyListener, attributeDeleted, attributeList, attributeList, clone, decorators, deepContains, depthInHierarchy, description, description, event, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttributes, getChangeListeners, getClassName, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getFullName, getModelErrorHandler, getName, getName, getSource, handleModelError, isOverridden, isPersistent, lazyContainedObjectsIterator, message, notifyOfNameChange, propagateValue, propagateValues, removeAttribute, removeDebugListener, removeHierarchyListener, setClassName, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, validateSettables, workspace
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
createReceivers, getCausalityInterface, getDirector, getExecutiveDirector, getManager, inputPortList, newReceiver, outputPortList
fire, isFireFunctional, isStrict, iterate, postfire, prefire, stop, stopFire, terminate
addInitializable, initialize, preinitialize, removeInitializable, wrapup
description, getContainer, getDisplayName, getFullName, getName, getName, setName
getDerivedLevel, getDerivedList, propagateValue
public LifeCycleManager()
public LifeCycleManager(Workspace workspace)
workspace
- The workspace that will list the actor.public LifeCycleManager(CompositeEntity container, java.lang.String name) throws IllegalActionException, NameDuplicationException
container
- The container.name
- The name of this actor.IllegalActionException
- If the container is incompatible
with this actor.NameDuplicationException
- If the name coincides with
an actor already in the container.public void addChangeListener(ChangeListener listener)
addChangeListener
in interface Changeable
addChangeListener
in class NamedObj
listener
- The listener to add.removeChangeListener(ChangeListener)
,
requestChange(ChangeRequest)
,
Changeable
public void executeChangeRequests()
executeChangeRequests
in interface Changeable
executeChangeRequests
in class NamedObj
addChangeListener(ChangeListener)
,
requestChange(ChangeRequest)
,
isDeferringChangeRequests()
,
Changeable
public boolean isDeferringChangeRequests()
isDeferringChangeRequests
in interface Changeable
isDeferringChangeRequests
in class NamedObj
setDeferringChangeRequests(boolean)
,
Changeable
public void removeChangeListener(ChangeListener listener)
removeChangeListener
in interface Changeable
removeChangeListener
in class NamedObj
listener
- The listener to remove.addChangeListener(ChangeListener)
,
Changeable
public void requestChange(ChangeRequest change)
requestChange
in interface Changeable
requestChange
in class CompositeActor
change
- The requested change.executeChangeRequests()
,
setDeferringChangeRequests(boolean)
,
Changeable
public void setDeferringChangeRequests(boolean isDeferring)
setDeferringChangeRequests
in interface Changeable
setDeferringChangeRequests
in class NamedObj
isDeferring
- If true, defer change requests.addChangeListener(ChangeListener)
,
executeChangeRequests()
,
isDeferringChangeRequests()
,
requestChange(ChangeRequest)
,
Changeable
protected int _executeInsideModel() throws IllegalActionException
IllegalActionException
- If there is no director, or if
the director's action methods throw it.protected void _fireInsideModel() throws IllegalActionException
IllegalActionException
- If there is no director, or if
the director's fire() method throws it.protected TypedCompositeActor _getManagedActor()
protected void _readInputs() throws IllegalActionException
IllegalActionException
- If reading the ports or
setting the parameters causes it.protected void _writeOutputs() throws IllegalActionException
IllegalActionException
- If reading the parameters or
writing to the ports causes it.