| Constructor and Description |
|---|
StateMachine(S initState) |
| Modifier and Type | Method and Description |
|---|---|
void |
addTransition(StateTransition<S,E,T> transition)
添加状态转换规则
|
boolean |
execute(E event)
执行
|
boolean |
execute(E event,
T payload)
执行
|
S |
getCurrentState()
获取当前状态
|
void |
restore(S state)
重置状态
|
public StateMachine(S initState)
Copyright © 2025. All rights reserved.