public class GiottoScheduler extends Scheduler
A schedule is represented by a list. Consider the following CompositeActor:
+-----------------------+ | A | +-----------------------+ +-----------------------+ | B | +-----------------------+ +---------+ +---------+ | C | | C | +---------+ +---------+There are three actors A, B, and C, where C runs twice as often as A and B. The list representing the schedule for this CompositeActor looks as follows:
+-------+ +-------+ | | | --------------------------->| | |nil| +-|-----+ +-|-----+ | | V V +-------+ +-------+ +-------+ +-------+ | | | ---->| | | ---->| | |nil| | | |nil| +-|-----+ +-|-----+ +-|-----+ +-|-----+ | | | | V V V V +---+ +---+ +---+ +---+ | A | | B | | c | | c | +---+ +---+ +---+ +---+
Red (eal) |
Yellow (cm) |
NamedObj.ContainedObjectsIterator
Modifier and Type | Field and Description |
---|---|
protected static int |
_DEFAULT_GIOTTO_FREQUENCY
The default Giotto frequency.
|
_DEFAULT_SCHEDULER_NAME
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
Constructor and Description |
---|
GiottoScheduler()
Construct a Giotto scheduler with no container (director)
in the default workspace.
|
GiottoScheduler(Workspace workspace)
Construct a Giotto scheduler in the given workspace.
|
Modifier and Type | Method and Description |
---|---|
protected double |
_getMinTimeStep(double period)
Return the unit of time increment for director.
|
protected Schedule |
_getSchedule()
Return the scheduling sequence.
|
int |
getLCM()
Returns the LCM value.
|
clone, getSchedule, isValid, setContainer, setValid
_checkContainer, _getContainedObject, _propagateExistence, getContainer, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, setName, updateContent
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _description, _executeChangeRequests, _exportMoMLContents, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, _validateSettables, addChangeListener, addDebugListener, addHierarchyListener, attributeChanged, 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, removeDebugListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, uniqueName, validateSettables, workspace
protected static final int _DEFAULT_GIOTTO_FREQUENCY
public GiottoScheduler()
public GiottoScheduler(Workspace workspace)
workspace
- Object for synchronization and version tracking.public int getLCM()
protected double _getMinTimeStep(double period)
period
- Giotto model period given in 'period' parameter of directorprotected Schedule _getSchedule() throws NotSchedulableException
_getSchedule
in class Scheduler
NotSchedulableException
- If the model is not
schedulable.CompositeEntity.deepEntityList()