VisualSim.simulators.gr.kernel
Class GRActor

java.lang.Object
  extended byVisualSim.kernel.util.NamedObj
      extended byVisualSim.kernel.Entity
          extended byVisualSim.kernel.ComponentEntity
              extended byVisualSim.actor.AtomicActor
                  extended byVisualSim.actor.TypedAtomicActor
                      extended byVisualSim.simulators.gr.kernel.GRActor
All Implemented Interfaces:
Actor, java.lang.Cloneable, VisualSim.kernel.util.Debuggable, VisualSim.kernel.util.DebugListener, VisualSim.actor.Executable, VisualSim.kernel.util.ModelErrorHandler, VisualSim.kernel.util.Nameable, java.io.Serializable, TypedActor
Direct Known Subclasses:
GRShadedShape, GRTransform, KeyInput3D, MouseInput3D, ViewScreen

public abstract class GRActor
extends TypedAtomicActor

A base class for all GR actors. This is an abstract class that is never used as a standalone actor in a VisualSim model. Subclasses of this actor include Geometry actors, Transform actors, Interaction actors, and the ViewScreen display actor.

Since:
VisualSim 1.0
See Also:
VisualSim.simulators.gr.lib, Serialized Form

Nested Class Summary
 
Nested classes inherited from class VisualSim.kernel.util.NamedObj
VisualSim.kernel.util.NamedObj.MoMLInfo
 
Field Summary
 
Fields inherited from class VisualSim.actor.AtomicActor
Block_Documentation
 
Fields inherited from class VisualSim.kernel.util.NamedObj
ATTRIBUTES, CLASSNAME, COMPLETE, CONTENTS, DEEP, FULLNAME, LINKS
 
Fields inherited from interface VisualSim.actor.Executable
COMPLETED, NOT_READY, STOP_ITERATING
 
Constructor Summary
GRActor(CompositeEntity container, java.lang.String name)
          Create a new GRActor in the specified container with the specified name.
 
Method Summary
 void fire()
          Initialize the scene graph if it is not yet initialized.
 void initialize()
          Check whether the current director is a GRDirector.
 void wrapup()
          Reset this actor back to uninitialized state to prepare for the next execution.
 
Methods inherited from class VisualSim.actor.TypedAtomicActor
attributeTypeChanged, newPort, typeConstraintList
 
Methods inherited from class VisualSim.actor.AtomicActor
clone, connectionsChanged, getDirector, getExecutiveDirector, getManager, inputPortList, iterate, newReceiver, outputPortList, postfire, prefire, preinitialize, setContainer, stop, stopFire, terminate
 
Methods inherited from class VisualSim.kernel.ComponentEntity
getContainer, isAtomic, isOpaque, setName
 
Methods inherited from class VisualSim.kernel.Entity
connectedPortList, getAttribute, getPort, linkedRelationList, portList, removeAllPorts, uniqueName, validateSettables
 
Methods inherited from class VisualSim.kernel.util.NamedObj
addChangeListener, addDebugListener, attributeChanged, attributeList, attributeList, clone, deepContains, depthInHierarchy, description, description, event, exportMoML, exportMoML, exportMoML, exportMoML, exportMoML, getAttribute, getFullName, getModelErrorHandler, getMoMLInfo, getName, getName, handleModelError, message, removeChangeListener, removeDebugListener, requestChange, setDeferMoMLDefinitionTo, setModelErrorHandler, toplevel, toString, workspace
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface VisualSim.actor.Actor
getDirector, getExecutiveDirector, getManager, inputPortList, newReceiver, outputPortList
 
Methods inherited from interface VisualSim.actor.Executable
iterate, postfire, prefire, preinitialize, stop, stopFire, terminate
 

Constructor Detail

GRActor

public GRActor(CompositeEntity container,
               java.lang.String name)
        throws VisualSim.kernel.util.IllegalActionException,
               VisualSim.kernel.util.NameDuplicationException
Create a new GRActor in the specified container with the specified name. The name must be unique within the container or an exception is thrown. The container argument must not be null, or a NullPointerException will be thrown.

Parameters:
container - The container.
name - The name of this actor within the container.
Throws:
VisualSim.kernel.util.IllegalActionException - If this actor cannot be contained by the proposed container (see the setContainer() method).
VisualSim.kernel.util.NameDuplicationException - If the name coincides with an entity already in the container.
Method Detail

fire

public void fire()
          throws VisualSim.kernel.util.IllegalActionException
Initialize the scene graph if it is not yet initialized.

Specified by:
fire in interface VisualSim.actor.Executable
Overrides:
fire in class AtomicActor
Throws:
VisualSim.kernel.util.IllegalActionException - If an error occurs during the scene graph initialization.

initialize

public void initialize()
                throws VisualSim.kernel.util.IllegalActionException
Check whether the current director is a GRDirector. If not, throw an illegal action exception.

Specified by:
initialize in interface VisualSim.actor.Executable
Overrides:
initialize in class AtomicActor
Throws:
VisualSim.kernel.util.IllegalActionException - If the current director is not a GRDirector.

wrapup

public void wrapup()
            throws VisualSim.kernel.util.IllegalActionException
Reset this actor back to uninitialized state to prepare for the next execution.

Specified by:
wrapup in interface VisualSim.actor.Executable
Overrides:
wrapup in class AtomicActor
Throws:
VisualSim.kernel.util.IllegalActionException - If the base class throws it.