【发布时间】:2012-10-21 20:18:36
【问题描述】:
由于某些原因,我无法通过构造函数设置状态机的参数 所以我想通过 后端。也就是说,我想要类似的东西
typedef msm::back::state_machine<player_> player;
player p;
p.get_front_end(); //get the address of the front end
p.get_front_end().set_param(34) //call the member function of front end
这可能吗?谢谢
另一种解决方案是通过事件将参数传递到状态机。
p.process_event(open_theme(34));
【问题讨论】: