I'm designing a state machine with a state in which I should repeat a sequence of activities until a trigger is fired. I thought these two options:
- Put a while activity inside the entry of the state. How is it managed when the trigger is fired? Which is the priority and how could I "synchronize" a trigger and the content of the entry?
- Use a self trigger, transforming the state itself in a while. It seems ugly and less performant, and I should "synchronize" the "out" trigger with the self one.
Any suggestions? Has a trigger a higher priority over the activities inside the entry of the state? Are they cancelled or what?