|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.argouml.model.uml.StateMachinesHelperImpl
Helper class for UML BehavioralElements::StateMachines Package.
Field Summary | |
private NSUMLModelImplementation |
nsmodel
The model implementation. |
Constructor Summary | |
(package private) |
StateMachinesHelperImpl(NSUMLModelImplementation implementation)
Don't allow instantiation. |
Method Summary | |
void |
addSubvertex(Object handle,
Object subvertex)
Add a subvertex to a composite state. |
Object |
findOperationByName(Object trans,
String opname)
Finds the operation to which a CallEvent refers. |
Collection |
getAllPossibleStatemachines(Object model,
Object oSubmachineState)
Returns all statemachines that can be the statemachine the given submachinestate represents. |
Collection |
getAllPossibleSubvertices(Object oState)
Returns all states that can be recursively contained by the given State. |
Collection |
getAllSubStates(Object compState)
Returns all substates some composite state contains. |
Object |
getDestination(Object trans)
Returns the destination of the given transition. |
Collection |
getOutgoingStates(Object ostatevertex)
Gets all statevertices that are a target to transitions outgoing from the given statevertex. |
String |
getPath(Object o)
Returns the path of a state vertex. |
Object |
getSource(Object trans)
Returns the source of the given transition. |
Object |
getStatebyName(String path,
Object container)
Returns a state contained into container. |
Object |
getStateMachine(Object handle)
Gets the statemachine that contains the given Object Traverses the state hierarchy of the statemachine untill the statemachine is reached. |
Object |
getTop(Object sm)
Get the "top" composite state of a statemachine. |
boolean |
isAddingStatemachineAllowed(Object context)
Returns true if a statemachine may be added to the given context. |
boolean |
isTopState(Object o)
Returns true is the given state is the top state. |
void |
removeSubvertex(Object handle,
Object subvertex)
Remove a given subvertex from a given composite state. |
void |
setBound(Object handle,
int bound)
Sets the Bound of some SynchState. |
void |
setConcurrent(Object handle,
boolean concurrent)
Makes a Composite State concurrent. |
void |
setContainer(Object handle,
Object compositeState)
Set the container of a statevertex. |
void |
setDoActivity(Object handle,
Object value)
Sets the do activity of a state. |
void |
setEffect(Object handle,
Object value)
Sets the effect of some transition. |
void |
setEntry(Object handle,
Object value)
Sets the entry action of some state. |
void |
setEventAsTrigger(Object transition,
Object event)
Couples a given event to the given transition as being trigger event. |
void |
setExit(Object handle,
Object value)
Sets the exit action of some state. |
void |
setExpression(Object handle,
Object value)
Set the Expression of a Guard or ChangeEvent. |
void |
setGuard(Object handle,
Object guard)
Sets the guard of a transition. |
void |
setInternalTransitions(Object handle,
Collection intTrans)
|
void |
setReferenceState(Object o,
String referenced)
Sets the Referenced State of a StubState. |
void |
setSource(Object handle,
Object state)
Sets the source state of some message. |
void |
setState(Object handle,
Object element)
Sets the state of an internal transition. |
void |
setStateMachine(Object handle,
Object stm)
Sets a state machine of some state or transition. |
void |
setStatemachineAsSubmachine(Object oSubmachineState,
Object oStatemachine)
Connects a given statemachine to a submachinestate as being the statemachine the submachinestate represents. |
void |
setSubvertices(Object handle,
Collection subvertices)
Set the collection of substates for a CompositeState. |
void |
setTrigger(Object handle,
Object event)
Sets the trigger event of a transition. |
void |
setWhen(Object handle,
Object value)
Sets the time-expression for a TimeEvent. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private NSUMLModelImplementation nsmodel
Constructor Detail |
StateMachinesHelperImpl(NSUMLModelImplementation implementation)
implementation
- To get other helpers and factories.Method Detail |
public Object getSource(Object trans)
getSource
in interface org.argouml.model.StateMachinesHelper
trans
- the given transition
public Object getDestination(Object trans)
getDestination
in interface org.argouml.model.StateMachinesHelper
trans
- the given transition
public Object getStateMachine(Object handle)
getStateMachine
in interface org.argouml.model.StateMachinesHelper
handle
- The state for which we want to know the
statemachine
public void setEventAsTrigger(Object transition, Object event)
setEventAsTrigger
in interface org.argouml.model.StateMachinesHelper
transition
- the given transitionevent
- the given eventpublic boolean isAddingStatemachineAllowed(Object context)
isAddingStatemachineAllowed
in interface org.argouml.model.StateMachinesHelper
context
- the given context
public boolean isTopState(Object o)
isTopState
in interface org.argouml.model.StateMachinesHelper
o
- CompositeState
public Collection getAllPossibleStatemachines(Object model, Object oSubmachineState)
getAllPossibleStatemachines
in interface org.argouml.model.StateMachinesHelper
model
- The model where we search for state machines.oSubmachineState
- The submachinestate we are searching the
statemachines for.
public Collection getAllPossibleSubvertices(Object oState)
getAllPossibleSubvertices
in interface org.argouml.model.StateMachinesHelper
oState
- the Composite state we are searching the states for
public void setStatemachineAsSubmachine(Object oSubmachineState, Object oStatemachine)
setStatemachineAsSubmachine
in interface org.argouml.model.StateMachinesHelper
oSubmachineState
- The submachinestate for which we want to set the
property submachineoStatemachine
- The statemachinepublic Object getTop(Object sm)
getTop
in interface org.argouml.model.StateMachinesHelper
sm
- the given statemachine
public Collection getOutgoingStates(Object ostatevertex)
getOutgoingStates
in interface org.argouml.model.StateMachinesHelper
ostatevertex
- the given statevertex
public Object findOperationByName(Object trans, String opname)
findOperationByName
in interface org.argouml.model.StateMachinesHelper
trans
- Object of type MTransitionopname
- the name of the operation sought
public Collection getAllSubStates(Object compState)
getAllSubStates
in interface org.argouml.model.StateMachinesHelper
compState
- the given compositestate
public void removeSubvertex(Object handle, Object subvertex)
removeSubvertex
in interface org.argouml.model.StateMachinesHelper
handle
- the composite statesubvertex
- the StateVertexpublic void addSubvertex(Object handle, Object subvertex)
addSubvertex
in interface org.argouml.model.StateMachinesHelper
handle
- the CompositeStatesubvertex
- the StateVertexpublic void setBound(Object handle, int bound)
setBound
in interface org.argouml.model.StateMachinesHelper
handle
- Synch Statebound
- A positive integer or the value “unlimited” specifying
the maximal count of the SynchState. The count is the
difference between the number of times the incoming
and outgoing transitions of the synch state are fired.public void setConcurrent(Object handle, boolean concurrent)
setConcurrent
in interface org.argouml.model.StateMachinesHelper
handle
- the CompositStateconcurrent
- booleanpublic void setContainer(Object handle, Object compositeState)
setContainer
in interface org.argouml.model.StateMachinesHelper
handle
- is the stateVertexcompositeState
- is the container. Can be null
.public void setDoActivity(Object handle, Object value)
setDoActivity
in interface org.argouml.model.StateMachinesHelper
handle
- is the statevalue
- the activity. Can be null
.public void setEffect(Object handle, Object value)
setEffect
in interface org.argouml.model.StateMachinesHelper
handle
- is the transitionvalue
- is the effect. Can be null
.public void setEntry(Object handle, Object value)
setEntry
in interface org.argouml.model.StateMachinesHelper
handle
- is the statevalue
- is the action. Can be null
.public void setExit(Object handle, Object value)
setExit
in interface org.argouml.model.StateMachinesHelper
handle
- is the statevalue
- is the action. Can be null
.public void setExpression(Object handle, Object value)
setExpression
in interface org.argouml.model.StateMachinesHelper
handle
- Guard or ChangeEventvalue
- BooleanExpression or nullpublic void setGuard(Object handle, Object guard)
setGuard
in interface org.argouml.model.StateMachinesHelper
handle
- to the transitionguard
- to be set. Can be null.public void setInternalTransitions(Object handle, Collection intTrans)
setInternalTransitions
in interface org.argouml.model.StateMachinesHelper
handle
- is the target.intTrans
- is a collection of transitions.public void setSource(Object handle, Object state)
setSource
in interface org.argouml.model.StateMachinesHelper
handle
- the messagestate
- the source statepublic void setState(Object handle, Object element)
setState
in interface org.argouml.model.StateMachinesHelper
handle
- the internal transitionelement
- the state that contains this transitionpublic void setStateMachine(Object handle, Object stm)
setStateMachine
in interface org.argouml.model.StateMachinesHelper
handle
- is the state or transitionstm
- is the state machinepublic void setSubvertices(Object handle, Collection subvertices)
setSubvertices
in interface org.argouml.model.StateMachinesHelper
handle
- CompositeStatesubvertices
- collection of sub-StateVertexespublic void setTrigger(Object handle, Object event)
setTrigger
in interface org.argouml.model.StateMachinesHelper
handle
- is the transitionevent
- is the trigger eventpublic void setWhen(Object handle, Object value)
setWhen
in interface org.argouml.model.StateMachinesHelper
handle
- Object (MTimeEvent)value
- Object (MTimeExpression)public String getPath(Object o)
getPath
in interface org.argouml.model.StateMachinesHelper
o
- the StateVertex
public Object getStatebyName(String path, Object container)
getStatebyName
in interface org.argouml.model.StateMachinesHelper
path
- the path the statecontainer
- of the state
public void setReferenceState(Object o, String referenced)
setReferenceState
in interface org.argouml.model.StateMachinesHelper
o
- Stub Statereferenced
- state
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ArgoUML © 1996-2004 (20050222) | ArgoUML Homepage | ArgoUML Developers' page | ArgoUML Cookbook |