ptolemy.domains.ptinyos.lib
Class NCComponentBase
java.lang.Object
ptolemy.kernel.util.NamedObj
ptolemy.kernel.InstantiableNamedObj
ptolemy.kernel.Entity
ptolemy.kernel.ComponentEntity
ptolemy.actor.AtomicActor
ptolemy.domains.ptinyos.lib.NCComponentBase
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable, Actor, Executable, FiringsRecordable, Initializable, Changeable, Debuggable, DebugListener, Derivable, Instantiable, ModelErrorHandler, MoMLExportable, Moveable, Nameable
public class NCComponentBase
- extends AtomicActor
Actor that serves as a placeholder for PtinyOS nesC modules and
configurations. This class is a base class for nesC component
classes. These are classes with source code defined in a .nc file
intended for use with TinyOS to program the Berkeley Motes. This
class provides a parameter source that is used to identify
the nesC source file. It works in conjunction with the NCComponent
MoML class, which attaches a tableau factory so that selecting the
"Open Actor" menu choice will open the nesC source file.
- Since:
- Ptolemy II 5.1
- Version:
- $Id: NCComponentBase.java 57040 2010-01-27 20:52:32Z cxh $
- Author:
- Elaine Cheong, Edward A. Lee, Yang Zhao
- See Also:
- Serialized Form
- Accepted Rating:
- Proposed Rating:
Fields inherited from class ptolemy.kernel.util.NamedObj |
_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS |
Method Summary |
private void |
_init()
Initialize the actor. |
Methods inherited from class ptolemy.actor.AtomicActor |
_actorFiring, _actorFiring, _addPort, addActorFiringListener, addInitializable, clone, connectionsChanged, createReceivers, declareDelayDependency, fire, getCausalityInterface, getDirector, getExecutiveDirector, getManager, initialize, inputPortList, isFireFunctional, isStrict, iterate, newPort, newReceiver, outputPortList, postfire, prefire, preinitialize, pruneDependencies, recordFiring, removeActorFiringListener, removeDependency, removeInitializable, setContainer, stop, stopFire, terminate, wrapup |
Methods inherited from class ptolemy.kernel.ComponentEntity |
_adjustDeferrals, _checkContainer, _getContainedObject, _propagateExistence, getContainer, instantiate, isAtomic, isOpaque, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, propagateExistence, setName |
Methods inherited from class ptolemy.kernel.Entity |
_description, _exportMoMLContents, _removePort, _validateSettables, connectedPortList, connectedPorts, containedObjectsIterator, getAttribute, getPort, getPorts, linkedRelationList, linkedRelations, portList, removeAllPorts, setClassDefinition, uniqueName |
Methods inherited from class ptolemy.kernel.util.NamedObj |
_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _debug, _debug, _debug, _debug, _debug, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _propagateValue, _recordDecoratedAttributes, _removeAttribute, _splitName, _stripNumericSuffix, addChangeListener, addDebugListener, attributeChanged, attributeList, attributeList, attributeTypeChanged, clone, deepContains, depthInHierarchy, description, description, event, executeChangeRequests, exportMoML, exportMoML, exportMoML, exportMoML, exportMoMLPlain, getAttribute, getAttributes, getChangeListeners, getClassName, getDecoratorAttribute, getDecoratorAttributes, getDerivedLevel, getDerivedList, getDisplayName, getFullName, getModelErrorHandler, getName, getName, getSource, handleModelError, isDeferringChangeRequests, isOverridden, isPersistent, lazyContainedObjectsIterator, message, propagateValue, propagateValues, removeChangeListener, removeDebugListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, validateSettables, workspace |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
source
public FileParameter source
- The source code file or URL. The default value is
"$PTII/ptolemy/domains/ptinyos/lib/NCComponent.nc"
rotatePorts
public Parameter rotatePorts
- Relative orientation of ports on the icon of this actor. The
default value is an IntegerToken of value 90.
icon
public NameIcon icon
- Icon for this component. The default value is a NameIcon with
name "_icon", which will display the value of the
displayedName
attribute on the icon.
displayedName
public StringAttribute displayedName
- Displayed name on icon. The value is set to the name of the
nesC component being represented. Otherwise, the name of this
class is displayed.
NCComponentBase
public NCComponentBase(Workspace workspace)
- Construct an actor in the specified workspace with an empty
string as a name. You can then change the name with setName().
If the workspace argument is null, then use the default workspace.
The object is added to the workspace directory.
Increment the version number of the workspace.
- Parameters:
workspace
- The workspace that will list the entity.
NCComponentBase
public NCComponentBase(CompositeEntity container,
java.lang.String name)
throws NameDuplicationException,
IllegalActionException
- Construct an actor with the given container and name.
- Parameters:
container
- The container.name
- The name of this actor.
- Throws:
IllegalActionException
- If the actor cannot be contained
by the proposed container.
NameDuplicationException
- If the container already has an
actor with this name.
_init
private void _init()
throws IllegalActionException,
NameDuplicationException
- Initialize the actor.
- Throws:
IllegalActionException
NameDuplicationException