
7 Mar
2008
7 Mar
'08
1:43 p.m.
Hi. Can anyone tell me how to query a state on an asynchronous_state_machine? The obvious answer would be to say use the state_downcast method (which is inherited from state_machine. But in practise it seems harder than so. But opposed to state_machine, when using asynchronous_state_machine the instance is not created explicitely, it is created implicitely by the scheduler, like this: myMachine = myEventHandler.create_processor<AsyncMachine>(); , hence there is no handle to the state machine itself. All I have is a handle to the processor (sc::fifo_scheduler<>::processor_handle ). So is there a way to come from sc::fifo_scheduler<>::processor_handle to AsyncMachine (which inherits sc:asynchronous_state_machine)? Jarl