public class DEReceiver extends Receiver
Red (wlc) |
Red (wlc) |
ProgramCodeGeneratorAdapter.Channel
NamedObj.ContainedObjectsIterator
_component, _defaultBlocks, _eol, _templateParser
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
Constructor and Description |
---|
DEReceiver(DEReceiver receiver)
Construct an adapter for an DE receiver.
|
Modifier and Type | Method and Description |
---|---|
protected java.lang.String |
_generateTypeConvertStatement(ProgramCodeGeneratorAdapter.Channel source)
Generate the type conversion statement for the particular offset of
the two given channels.
|
protected DEDirector |
_getDirectorForReceiver()
Each receiver is associated with a director, return that director.
|
protected DEDirector |
_getExecutiveDirectorForReceiver()
Each receiver is associated with a component of some executive director.
|
java.lang.String |
generateGetCode(java.lang.String offset)
Generates code for getting tokens from the receiver.
|
java.lang.String |
generateHasTokenCode(java.lang.String offset)
Generates code to check the receiver has a token.
|
java.lang.String |
generatePutCode(IOPort sourcePort,
java.lang.String offset,
java.lang.String token)
Generate code for putting tokens from the receiver.
|
_removeSink, generateInitializeCode, getComponent, getName
_generateBlockByName, getAdapter, getCodeGenerator, getTemplateParser, processCode, setCodeGenerator, setTemplateParser, toString
createDecoratorAttributes, generateName
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _description, _executeChangeRequests, _exportMoMLContents, _getContainedObject, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateExistence, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, _validateSettables, addChangeListener, addDebugListener, addHierarchyListener, attributeChanged, attributeDeleted, attributeList, attributeList, attributeTypeChanged, clone, clone, containedObjectsIterator, decorators, deepContains, depthInHierarchy, description, description, event, executeChangeRequests, exportMoML, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttribute, getAttributes, getChangeListeners, getClassName, getContainer, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getElementName, getFullName, getModelErrorHandler, getName, getPrototypeList, getSource, handleModelError, isDeferringChangeRequests, isOverridden, isPersistent, lazyContainedObjectsIterator, message, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, notifyOfNameChange, propagateExistence, propagateValue, propagateValues, removeAttribute, removeChangeListener, removeDebugListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setName, setPersistent, setSource, sortContainedObjects, toplevel, uniqueName, validateSettables, workspace
public DEReceiver(DEReceiver receiver) throws IllegalActionException
receiver
- The DEReceiver for which an adapter is constructed.IllegalActionException
- If thrown by the superclass.public java.lang.String generateGetCode(java.lang.String offset) throws IllegalActionException
generateGetCode
in class Receiver
offset
- The offset of the port.IllegalActionException
- If thrown while getting the component,
getting the adapter, getting the director or getting the port reference.public java.lang.String generateHasTokenCode(java.lang.String offset) throws IllegalActionException
generateHasTokenCode
in class Receiver
offset
- The offset of the receiver, ignored in this base
class.IllegalActionException
- Not thrown in this base class.public java.lang.String generatePutCode(IOPort sourcePort, java.lang.String offset, java.lang.String token) throws IllegalActionException
generatePutCode
in class Receiver
sourcePort
- The source port.offset
- The offset of the port.token
- The token.IllegalActionException
- If thrown while getting the component,
getting the adapter, getting the director or getting the port reference.protected java.lang.String _generateTypeConvertStatement(ProgramCodeGeneratorAdapter.Channel source) throws IllegalActionException
Receiver
_generateTypeConvertStatement
in class Receiver
source
- The given source channel.IllegalActionException
- If there is a problem getting the
adapters for the ports or if the conversion cannot be handled.protected DEDirector _getDirectorForReceiver() throws IllegalActionException
_getDirectorForReceiver
in class Receiver
IllegalActionException
- FIXME: this is not exactly correct.
This is probably because the information of the receiver is in the director of
the container?protected DEDirector _getExecutiveDirectorForReceiver() throws IllegalActionException
IllegalActionException
- If thrown while getting the adapter.