## org.opencyc.uml.statemachine
Class State

    java.lang.Object
      |
      +--org.opencyc.uml.core.Element
            |
            +--org.opencyc.uml.core.ModelElement
                  |
                  +--org.opencyc.uml.statemachine.StateVertex
                        |
                        +--org.opencyc.uml.statemachine.State

Direct Known Subclasses:
  CompositeState, FinalState, SimpleState, StubState

public abstract class State
extends StateVertex

State from the UML State_Machines package.

Author:
  Stephen L. Reed

  Copyright 2001 Cycorp, Inc., license is open source GNU LGPL.

  the license

  www.opencyc.org

  OpenCyc at SourceForge

  THIS SOFTWARE AND KNOWLEDGE BASE CONTENT ARE PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE OPENCYC ORGANIZATION OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE AND KNOWLEDGE BASE CONTENT, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Field Summary
`protected java.util.ArrayList` `deferrableEvent` the deferrable events for this state
`protected org.opencyc.uml.core.Procedure` `doActivity` the do activity for this state
`protected DoActivity` `doActivityThread` the do activity thread for this state
`protected org.opencyc.uml.core.Procedure` `entry` the entry procedure for this state
`protected org.opencyc.uml.core.Procedure` `exit` the exit procedure for this state
`protected java.util.ArrayList` `internalTransition` the internal transitions for this state
`protected boolean` `isActive` Indicates whether this state is currently active during execution of the state machine.
`protected StateInterpreter` `stateInterpreter` the state interpreter for this state
`protected StateMachine` `stateMachine` the state machine for this state (if top)

Fields inherited from class org.opencyc.uml.statemachine.StateVertex
`container, incoming, outgoing`

Fields inherited from class org.opencyc.uml.core.ModelElement
`comment, name, namespace`

Constructor Summary
`State()` Constructs a new State object.

Method Summary
`java.util.ArrayList` `getDeferrableEvent()` Gets the deferrable events for this state.
`org.opencyc.uml.core.Procedure` `getDoActivity()` Gets the do activity for this state.
`DoActivity` `getDoActivityThread()` Gets the do activity thread for this state.
`org.opencyc.uml.core.Procedure` `getEntry()` Gets the entry procedure for this state.
`org.opencyc.uml.core.Procedure` `getExit()` Gets the exit procedure for this state.
`java.util.ArrayList` `getInternalTransition()` Gets the internal transitions for this state.
`StateInterpreter` `getStateInterpreter()` Gets the state interpreter for this state.
`StateMachine` `getStateMachine()` Gets the state machine for this state (if top).
`boolean` `isActive()` Gets whether this state is currently active during execution of the state machine.
`void` `setDeferrableEvent(java.util.ArrayList deferrableEvent)` Sets the deferrable events for this state.
`void` `setDoActivity(org.opencyc.uml.core.Procedure doActivity)` Sets the do activity for this state.
`void` `setDoActivityThread(DoActivity doActivityThread)` Sets the do activity thread for this state.
`void` `setEntry(org.opencyc.uml.core.Procedure entry)` Sets the entry procedure for this state.
`void` `setExit(org.opencyc.uml.core.Procedure exit)` Sets the exit procedure for this state.
`void` `setInternalTransition(java.util.ArrayList internalTransition)` Sets the internal transitions for this state.
`void` `setIsActive(boolean isActive)` Sets whether this state is currently active during execution of the state machine.
`void` `setStateInterpreter(StateInterpreter stateInterpreter)` Sets the state interpreter for this state.
`void` `setStateMachine(StateMachine stateMachine)` Sets the state machine for this state (if top).

Methods inherited from class org.opencyc.uml.statemachine.StateVertex
`getContainer, getIncoming, getOutgoing, setContainer, setIncoming, setOutgoing`

Methods inherited from class org.opencyc.uml.core.ModelElement
`equals, getComment, getName, getNamespace, setComment, setName, setNamespace, toString`

Methods inherited from class java.lang.Object
`clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Field Detail

### entry

    protected org.opencyc.uml.core.Procedure entry

  the entry procedure for this state

### exit

    protected org.opencyc.uml.core.Procedure exit

  the exit procedure for this state

### deferrableEvent

    protected java.util.ArrayList deferrableEvent

  the deferrable events for this state

### doActivity

    protected org.opencyc.uml.core.Procedure doActivity

  the do activity for this state

### internalTransition

    protected java.util.ArrayList internalTransition

  the internal transitions for this state

### stateMachine

    protected StateMachine stateMachine

  the state machine for this state (if top)

### stateInterpreter

    protected StateInterpreter stateInterpreter

  the state interpreter for this state

### isActive

    protected boolean isActive

  Indicates whether this state is currently active during execution of the state machine. A state becomes active when it is entered as a result of some transition, and becomes inactive if it is exited as a result of a transition.

### doActivityThread

    protected DoActivity doActivityThread

  the do activity thread for this state

Constructor Detail

### State

    public State()

  Constructs a new State object.

Method Detail

### getEntry

    public org.opencyc.uml.core.Procedure getEntry()

  Gets the entry procedure for this state.
  Returns:
    the entry procedure for this state

### setEntry

    public void setEntry(org.opencyc.uml.core.Procedure entry)

  Sets the entry procedure for this state.
  Parameters:
    `entry` - the entry procedure for this state

### getExit

    public org.opencyc.uml.core.Procedure getExit()

  Gets the exit procedure for this state.
  Returns:
    the exit procedure for this state

### setExit

    public void setExit(org.opencyc.uml.core.Procedure exit)

  Sets the exit procedure for this state.
  Parameters:
    `exit` - the exit procedure for this state

### getDeferrableEvent

    public java.util.ArrayList getDeferrableEvent()

  Gets the deferrable events for this state.
  Returns:
    the deferrable events for this state

### setDeferrableEvent

    public void setDeferrableEvent(java.util.ArrayList deferrableEvent)

  Sets the deferrable events for this state.
  Parameters:
    `deferrableEvent` - the deferrable events for this state

### getDoActivity

    public org.opencyc.uml.core.Procedure getDoActivity()

  Gets the do activity for this state.
  Returns:
    the do activity for this state

### setDoActivity

    public void setDoActivity(org.opencyc.uml.core.Procedure doActivity)

  Sets the do activity for this state.
  Parameters:
    `doActivity` - the do activity for this state

### getStateMachine

    public StateMachine getStateMachine()

  Gets the state machine for this state (if top).
  Returns:
    the state machine for this state

### setStateMachine

    public void setStateMachine(StateMachine stateMachine)

  Sets the state machine for this state (if top).
  Parameters:
    `stateMachine` - the state machine for this state

### isActive

    public boolean isActive()

  Gets whether this state is currently active during execution of the state machine.
  Returns:
    whether this state is currently active during execution of the state machine

### setIsActive

    public void setIsActive(boolean isActive)

  Sets whether this state is currently active during execution of the state machine.
  Parameters:
    `isActive` - whether this state is currently active during execution of the state machine

### getDoActivityThread

    public DoActivity getDoActivityThread()

  Gets the do activity thread for this state.
  Returns:
    the do activity thread for this state

### setDoActivityThread

    public void setDoActivityThread(DoActivity doActivityThread)

  Sets the do activity thread for this state.
  Parameters:
    `doActivityThread` - the do activity thread for this state

### getInternalTransition

    public java.util.ArrayList getInternalTransition()

  Gets the internal transitions for this state.
  Returns:
    the internal transitions for this state

### setInternalTransition

    public void setInternalTransition(java.util.ArrayList internalTransition)

  Sets the internal transitions for this state.
  Parameters:
    `internalTransition` - the internal transitions for this state

### getStateInterpreter

    public StateInterpreter getStateInterpreter()

  Gets the state interpreter for this state.
  Returns:
    the state interpreter for this state

### setStateInterpreter

    public void setStateInterpreter(StateInterpreter stateInterpreter)

  Sets the state interpreter for this state.
  Parameters:
    `stateInterpreter` - the state interpreter for this state