Is there any way to partition a state machine using boost::statechart
such that the main state machine is in one dll, and its substates (and
possibly their substates) are in separate dll's?
It would seem that
this would create a cyclic dependency. Suppose you have e.g. a simple
statechart called MyStatechart containing an initial state State1 which
transitions to State2 in response to some event. Is it possible to implement
MyStatechart and State1 in MyStatechart.dll, and State2 in
State2.dll?
Since the code for State1 will need to reference State2 (in
order to transition to it), MyStatechart.dll will have a dependency on
State2.dll. But since State2 is contained in MyStatechart, its type will have
to look something like
struct State2: sc::state<State2,
MyStatechart>
{
//...
};
which means that
State2.dll will have a dependency on MyStatechart.dll.
Is it possible
to avoid this cycle?
Thanks for any help,
Bill