RAFCON
RAFCON copied to clipboard
handle automatic creation of transtions in barrier state
Barrier states can be created in several way:
- empty
- with a states list passed to the constructor
- with a states and transition list passed to the constructor
Cases 1. and 2. are straight forward.
In case 3. the transitions have to be handled carefully:
- transitions are normally automatically created, this must not be done in this case as some transitions could be duplicated
- only using the passed transition list can also be wrong as it could not be complete
Now there are two possible solutions:
- we let all transitions create automatically while "add_state" function is called + add only those transitions of the passed transition list which originate from the decider state; optional consistency check of other transitions in the passed transition list => warning prints intended for developer
- we let all transitions create automatically while "add_state" function is called + add only those transitions of the passed transition list which do not target the decider state; optional consistency check is not necessary as invalid transitions lead to exceptions anyway
- add states without transitions + add all transitions of passed transition list + fill up missing transitions
@Rbelder and @sebastian-brunner vote for option 2.
Discussion is welcome.
Originally created by @sebastian-brunner ([email protected]) at 2018-02-19 15:11:13+00:00 (moved from RMC internal repository)