1 package org.andromda.metafacades.uml14;
2
3 import org.omg.uml.behavioralelements.activitygraphs.ObjectFlowState;
4 import org.omg.uml.behavioralelements.statemachines.CompositeState;
5 import org.omg.uml.behavioralelements.statemachines.StateMachine;
6 import org.omg.uml.foundation.core.Classifier;
7
8
9
10
11
12 public class ObjectFlowStateFacadeLogicImpl
13 extends ObjectFlowStateFacadeLogic
14 {
15 private static final long serialVersionUID = 744240821518303756L;
16
17
18
19
20
21 public ObjectFlowStateFacadeLogicImpl(
22 ObjectFlowState metaObject,
23 String context)
24 {
25 super(metaObject, context);
26 }
27
28
29
30
31 @Override
32 protected StateMachine handleGetStateMachine()
33 {
34 StateMachine stateMachine = null;
35 CompositeState compositeState = metaObject.getContainer();
36
37 if (compositeState != null)
38 {
39 while (compositeState != null)
40 {
41 stateMachine = compositeState.getStateMachine();
42 compositeState = compositeState.getContainer();
43 }
44 }
45
46 return stateMachine;
47 }
48
49
50
51
52 protected Classifier handleGetType()
53 {
54 return metaObject.getType();
55 }
56 }