public class CAViewer extends AbstractPlaceableActor
The CAViewer is a display actor to be used in conjunction with the CADirector. The CAViewer can be placed on the canvas and will render the grid as defined by the Director's parameters and possibly the output of the CA2DConvolution actor. This actor is the currently the only way to visualize cellular automata or other 2D grid based phenomena employing the CADirectory.
Entity.ContainedObjectsIterator| Modifier and Type | Field and Description |
|---|---|
protected boolean |
_initialized
True if the actor has been initialized.
|
protected double[][] |
matrix
The matrix to be rendered as a grid.
|
_frame, _paneSize, _windowClosingAdapter, _windowProperties_typesValid_actorFiringListeners, _initializables, _notifyingActorFiring, _stopRequested_changeListeners, _changeLock, _changeRequests, _debugging, _debugListeners, _deferChangeRequests, _elementName, _isPersistent, _verbose, _workspace, ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKSCOMPLETED, NOT_READY, STOP_ITERATING| Constructor and Description |
|---|
CAViewer(CompositeEntity entity,
java.lang.String name)
Construct a new CAViewer.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
_openWindow()
Open the window, first initializing it if necessary.
|
void |
initialize()
Initialize the viewer.
|
void |
place(java.awt.Container container)
Specify the container in which the data should be displayed.
|
boolean |
postfire()
Show the tableau containing the visualization of the matrix.
|
void |
setMatrix(double[][] matrix)
Set the matrix to be rendered as a grid.
|
_exportMoMLContents, cleanUp, clone, setFrame_containedTypeConstraints, _customTypeConstraints, _defaultTypeConstraints, _fireAt, _fireAt, attributeTypeChanged, clone, isBackwardTypeInferenceEnabled, newPort, typeConstraintList, typeConstraints_actorFiring, _actorFiring, _declareDelayDependency, addActorFiringListener, addInitializable, connectionsChanged, createReceivers, declareDelayDependency, fire, getCausalityInterface, getDirector, getExecutiveDirector, getManager, inputPortList, isFireFunctional, isStrict, iterate, newReceiver, outputPortList, prefire, preinitialize, pruneDependencies, recordFiring, removeActorFiringListener, removeDependency, removeInitializable, setContainer, stop, stopFire, terminate, wrapup_adjustDeferrals, _checkContainer, _getContainedObject, _propagateExistence, getContainer, instantiate, isAtomic, isOpaque, moveDown, moveToFirst, moveToIndex, moveToLast, moveUp, propagateExistence, setName_addPort, _description, _removePort, _validateSettables, connectedPortList, connectedPorts, containedObjectsIterator, getAttribute, getPort, getPorts, linkedRelationList, linkedRelations, portList, removeAllPorts, setClassDefinition, uniqueName_setParent, exportMoML, getChildren, getElementName, getParent, getPrototypeList, isClassDefinition, isWithinClassDefinition_addAttribute, _adjustOverride, _attachText, _cloneFixAttributeFields, _containedDecorators, _copyChangeRequestList, _debug, _debug, _debug, _debug, _debug, _executeChangeRequests, _getIndentPrefix, _isMoMLSuppressed, _markContentsDerived, _notifyHierarchyListenersAfterChange, _notifyHierarchyListenersBeforeChange, _propagateValue, _removeAttribute, _splitName, _stripNumericSuffix, addChangeListener, addDebugListener, addHierarchyListener, attributeChanged, attributeDeleted, attributeList, attributeList, decorators, 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, notifyOfNameChange, propagateValue, propagateValues, removeAttribute, removeChangeListener, removeDebugListener, removeHierarchyListener, requestChange, setClassName, setDeferringChangeRequests, setDerivedLevel, setDisplayName, setModelErrorHandler, setPersistent, setSource, sortContainedObjects, toplevel, toString, validateSettables, workspaceequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitcreateReceivers, getCausalityInterface, getDirector, getExecutiveDirector, getManager, inputPortList, newReceiver, outputPortListfire, isFireFunctional, isStrict, iterate, prefire, stop, stopFire, terminateaddInitializable, preinitialize, removeInitializable, wrapupdescription, getContainer, getDisplayName, getFullName, getName, getName, setNamegetDerivedLevel, getDerivedList, propagateValueprotected boolean _initialized
protected double[][] matrix
public CAViewer(CompositeEntity entity, java.lang.String name) throws IllegalActionException, NameDuplicationException
entity - The containername - The name of the CAViewer.IllegalActionException - If the name has a period in it.NameDuplicationException - If the container already
contains an entity with the specified name.public void initialize()
throws IllegalActionException
initialize in interface Initializableinitialize in class AtomicActor<TypedIOPort>IllegalActionException - If the superclass throws
the exception.public void place(java.awt.Container container)
place in interface Placeableplace in class AbstractPlaceableActorcontainer - The container in which to place the pane that
will contain the CATableau or null to specify no container.public boolean postfire()
throws IllegalActionException
postfire in interface Executablepostfire in class AtomicActor<TypedIOPort>IllegalActionException - If the base class throws an
exception.public void setMatrix(double[][] matrix)
matrix - The matrix to be rendered.protected void _openWindow()
throws IllegalActionException
IllegalActionException - If the top level effigy
cannot be found or the token effigy cannot be created.