Biblioteca Java - Blame information for rev 17
Subversion Repositories:
Rev | Author | Line No. | Line |
---|---|---|---|
17 | mihai | 1 | package rtuml.capsule; |
2 | |||
3 | import java.util.ArrayList; | ||
4 | |||
5 | public abstract class MState{ | ||
6 | |||
7 | private ArrayList<Transition> transitions = new ArrayList<Transition>(); | ||
8 | |||
9 | public abstract void exitAction(Event e); | ||
10 | public abstract void entryAction(Event e); | ||
11 | public abstract void doAction(Event e); | ||
12 | |||
13 | public void addTransition(Transition t){ | ||
14 | transitions.add(t); | ||
15 | } | ||
16 | |||
17 | public Transition checkExitConditions(Event e){ | ||
18 | for(Transition t: transitions){ | ||
19 | if(t.gaurdCondition(e)){ | ||
20 | return t; | ||
21 | } | ||
22 | } | ||
23 | return null; | ||
24 | } | ||
25 | |||
26 | } |