|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectptolemy.kernel.util.NamedObj
ptolemy.kernel.util.Attribute
ptolemy.actor.Director
ptolemy.domains.fsm.kernel.FSMDirector
ptolemy.domains.fsm.kernel.HSDirector
An HSDirector governs the execution of the discrete dynamics of a hybrid system model.
Hierarchical Hybrid System Simulation describes how hybrid system models are built and simulated in Ptolemy II.
Note: this class is still under development.
| Red (liuxj) |
| Red (liuxj) |
| Nested Class Summary |
| Nested classes inherited from class ptolemy.kernel.util.NamedObj |
NamedObj.ContainedObjectsIterator |
| Field Summary |
| Fields inherited from class ptolemy.domains.fsm.kernel.FSMDirector |
_currentLocalReceiverMap, _enabledRefinements, _fireRefinement, _firstFire, _localReceiverMaps, controllerName |
| Fields inherited from class ptolemy.actor.Director |
_currentTime, _stopRequested |
| Fields inherited from class ptolemy.kernel.util.NamedObj |
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _elementName, _isPersistent, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS |
| Fields inherited from interface ptolemy.actor.Executable |
COMPLETED, NOT_READY, STOP_ITERATING |
| Constructor Summary | |
HSDirector()
Construct a director in the default workspace with an empty string as its name. |
|
HSDirector(CompositeEntity container,
java.lang.String name)
Construct a director in the given container with the given name. |
|
HSDirector(Workspace workspace)
Construct a director in the workspace with an empty name. |
|
| Method Summary | |
void |
fire()
Set the values of input variables in the mode controller. |
double |
getCurrentTime()
Return the current time obtained from the executive director, if there is one, and otherwise return the local view of current time. |
double |
getNextIterationTime()
Return the next iteration time obtained from the executive director. |
boolean |
hasCurrentEvent()
Return true if the current refinement produces events. |
boolean |
isThisStepAccurate()
Return true if there are no refinements, or if the current integration step is accurate with the respect of all the enabled refinements, which are refinements that returned true in their prefire() methods in this iteration, or if a refinement is not a CTStepSizeControlActor; and if the current time is exactly the same time the transition is enabled. |
Receiver |
newReceiver()
Return a CTReceiver. |
boolean |
postfire()
Return true if the mode controller wishes to be scheduled for another iteration. |
double |
predictedStepSize()
Return the smallest next step size predicted by the all the enabled refinements, which are refinements that returned true in their prefire() methods in this iteration. |
boolean |
prefire()
Set the controller. |
double |
refinedStepSize()
Return the step size refined by all the enabled refinements, which are refinements that returned true in their prefire() methods in this iteration, or the enabled transition which requires the current time be the same with the time it is enabled. |
| Methods inherited from class ptolemy.domains.fsm.kernel.FSMDirector |
_buildLocalReceiverMaps, _chooseTransition, _currentLocalReceivers, _getLastChosenTransition, _readInputs, _readOutputsFromRefinement, _setCurrentConnectionMap, _setCurrentState, attributeChanged, clone, fireAt, getContext, getController, getModifiedVariables, handleModelError, initialize, setContainer, setCurrentTime, transferInputs |
| Methods inherited from class ptolemy.actor.Director |
_description, _isEmbedded, _isTopLevel, _writeAccessRequired, domainPolymorphicTransferInputs, domainPolymorphicTransferOutputs, fireAtCurrentTime, getTimeResolution, initialize, invalidateResolvedTypes, invalidateSchedule, iterate, needWriteAccess, preinitialize, requestInitialization, setTimeResolution, stop, stopFire, terminate, transferOutputs, wrapup |
| Methods inherited from class ptolemy.kernel.util.Attribute |
_getContainedObject, _propagateExistence, getContainer, setName |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface ptolemy.kernel.util.Nameable |
description, getContainer, getFullName, getName, getName, setName |
| Constructor Detail |
public HSDirector()
public HSDirector(Workspace workspace)
workspace - The workspace of this director.
public HSDirector(CompositeEntity container,
java.lang.String name)
throws IllegalActionException,
NameDuplicationException
container - Container of this director.name - Name of this director.
IllegalActionException - If the name has a period in it, or
the director is not compatible with the specified container.
NameDuplicationException - If the container is not a
CompositeActor and the name collides with an entity in the container.| Method Detail |
public void fire()
throws IllegalActionException
fire in interface Executablefire in class FSMDirectorIllegalActionException - If there is more than one
transition enabled, or there is no controller, or thrown by any
choice action.public double getCurrentTime()
getCurrentTime in class Directorpublic double getNextIterationTime()
getNextIterationTime in class FSMDirectorpublic boolean hasCurrentEvent()
hasCurrentEvent in interface CTTransparentDirectorpublic boolean isThisStepAccurate()
isThisStepAccurate in interface CTTransparentDirectorpublic Receiver newReceiver()
newReceiver in class FSMDirector
public boolean postfire()
throws IllegalActionException
postfire in interface Executablepostfire in class FSMDirectorIllegalActionException - If thrown by any action, or
there is no controller.public double predictedStepSize()
predictedStepSize in interface CTTransparentDirector
public boolean prefire()
throws IllegalActionException
prefire in interface Executableprefire in class FSMDirectorIllegalActionException - If there is no controller.
FIXME: Changed by liuj, not yet reviewed.public double refinedStepSize()
refinedStepSize in interface CTTransparentDirector
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||