org.apache.commons.scxml.model
Class TransitionTarget

java.lang.Object
  extended by org.apache.commons.scxml.model.TransitionTarget
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
History, Initial, Parallel, State

public abstract class TransitionTarget
extends java.lang.Object
implements java.io.Serializable

An abstract base class for elements in SCXML that can serve as a <target> for a <transition>, such as State or Parallel.

See Also:
Serialized Form

Constructor Summary
TransitionTarget()
          Constructor.
 
Method Summary
 void addHistory(History h)
          This method is used by XML digester.
 Datamodel getDatamodel()
          Get the data model for this transition target.
 java.util.List getHistory()
          Get the list of history pseudo states for this state.
 java.lang.String getId()
          Get the identifier for this transition target (may be null).
 OnEntry getOnEntry()
          Get the onentry property.
 OnExit getOnExit()
          Get the onexit property.
 TransitionTarget getParent()
          Get the parent TransitionTarget.
 State getParentState()
          Get the parent State.
 boolean hasHistory()
          Does this state have a history pseudo state.
 void setDatamodel(Datamodel datamodel)
          Set the data model for this transition target.
 void setId(java.lang.String id)
          Set the identifier for this transition target.
 void setOnEntry(OnEntry onEntry)
          Set the onentry property.
 void setOnExit(OnExit onExit)
          Set the onexit property.
 void setParent(TransitionTarget parent)
          Set the parent TransitionTarget.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TransitionTarget

public TransitionTarget()
Constructor.

Method Detail

getId

public final java.lang.String getId()
Get the identifier for this transition target (may be null).

Returns:
Returns the id.

setId

public final void setId(java.lang.String id)
Set the identifier for this transition target.

Parameters:
id - The id to set.

getOnEntry

public final OnEntry getOnEntry()
Get the onentry property.

Returns:
Returns the onEntry.

setOnEntry

public final void setOnEntry(OnEntry onEntry)
Set the onentry property.

Parameters:
onEntry - The onEntry to set.

getOnExit

public final OnExit getOnExit()
Get the onexit property.

Returns:
Returns the onExit.

setOnExit

public final void setOnExit(OnExit onExit)
Set the onexit property.

Parameters:
onExit - The onExit to set.

getDatamodel

public final Datamodel getDatamodel()
Get the data model for this transition target.

Returns:
Returns the data model.

setDatamodel

public final void setDatamodel(Datamodel datamodel)
Set the data model for this transition target.

Parameters:
datamodel - The Datamodel to set.

getParent

public final TransitionTarget getParent()
Get the parent TransitionTarget.

Returns:
Returns the parent state (null if parent is <scxml> element)

setParent

public final void setParent(TransitionTarget parent)
Set the parent TransitionTarget.

Parameters:
parent - The parent state to set

getParentState

public final State getParentState()
Get the parent State.

Returns:
The parent State

addHistory

public final void addHistory(History h)
This method is used by XML digester.

Parameters:
h - History pseudo state
Since:
0.7

hasHistory

public final boolean hasHistory()
Does this state have a history pseudo state.

Returns:
boolean true if a given state contains at least one history pseudo state
Since:
0.7

getHistory

public final java.util.List getHistory()
Get the list of history pseudo states for this state.

Returns:
a list of all history pseudo states contained by a given state (can be empty)
Since:
0.7
See Also:
hasHistory()


Copyright © 2005-2008 The Apache Software Foundation. All Rights Reserved.