6 from smclib
import statemap
36 msg =
"\n\tState: %s\n\tTransition: %s" % (
37 fsm.getState().
getName(), fsm.getTransition())
49 fsm.getState().
Exit(fsm)
55 fsm.getState().
Entry(fsm)
59 fsm.getState().
Exit(fsm)
65 fsm.getState().
Entry(fsm)
69 fsm.getState().
Exit(fsm)
74 fsm.setState(SM.Alive)
75 fsm.getState().
Entry(fsm)
82 fsm.getState().
Exit(fsm)
87 fsm.setState(SM.AwaitSisterDeath)
88 fsm.getState().
Entry(fsm)
92 fsm.getState().
Exit(fsm)
98 fsm.getState().
Entry(fsm)
101 ctxt = fsm.getOwner()
102 fsm.getState().
Exit(fsm)
107 fsm.setState(SM.Alive)
108 fsm.getState().
Entry(fsm)
111 ctxt = fsm.getOwner()
112 fsm.getState().
Exit(fsm)
118 fsm.setState(SM.Dead)
119 fsm.getState().
Entry(fsm)
125 ctxt = fsm.getOwner()
126 fsm.getState().
Exit(fsm)
131 fsm.setState(SM.Dead)
132 fsm.getState().
Entry(fsm)
135 fsm.getState().
Exit(fsm)
136 fsm.setState(SM.AwaitSisterDeath)
137 fsm.getState().
Entry(fsm)
140 fsm.getState().
Exit(fsm)
141 fsm.setState(SM.AwaitSisterDeath)
142 fsm.getState().
Entry(fsm)
145 ctxt = fsm.getOwner()
146 fsm.getState().
Exit(fsm)
151 fsm.setState(SM.Dead)
152 fsm.getState().
Entry(fsm)
158 fsm.getState().
Exit(fsm)
159 fsm.setState(SM.Dead)
160 fsm.getState().
Entry(fsm)
163 fsm.getState().
Exit(fsm)
164 fsm.setState(SM.Dead)
165 fsm.getState().
Entry(fsm)
168 fsm.getState().
Exit(fsm)
169 fsm.setState(SM.Dead)
170 fsm.getState().
Entry(fsm)
173 fsm.getState().
Exit(fsm)
174 fsm.setState(SM.Dead)
175 fsm.getState().
Entry(fsm)
178 fsm.getState().
Exit(fsm)
179 fsm.setState(SM.Dead)
180 fsm.getState().
Entry(fsm)
195 statemap.FSMContext.__init__(self, SM.WaitingForSister)
199 def trans_sm(*arglist):
201 getattr(self.getState(), attrib)(self, *arglist)
206 self._state.Entry(self)
def SisterAlive(self, fsm)
virtual void enterStartState()=0
def HeartbeatTimeout(self, fsm)
def __init__(self, owner)
def __getattr__(self, attrib)
def ConnectTimeout(self, fsm)
def ConnectTimeout(self, fsm)
const char * getName() const
def ConnectTimeout(self, fsm)
def HeartbeatTimeout(self, fsm)
def SisterDead(self, fsm)
def DisconnectTimeout(self, fsm)
def DisconnectTimeout(self, fsm)
def SisterDead(self, fsm)
def SisterAlive(self, fsm)
def HeartbeatTimeout(self, fsm)
def SisterAlive(self, fsm)
def HeartbeatTimeout(self, fsm)
def DisconnectTimeout(self, fsm)
def SisterAlive(self, fsm)
def SisterDead(self, fsm)
def SisterDead(self, fsm)