statechart-designer icon indicating copy to clipboard operation
statechart-designer copied to clipboard

Refactorings

Open mogsie opened this issue 6 years ago • 1 comments

I'd love a tool like this to support various types of refactorings. An obvious one is "specialize" to introduce a substate; you might not even consider that a refactoring. But there are other types of refactorings that you could have like:

  • Move transition to parent state — On a transition source, "move to parent state": The transition is moved to the parent state
  • Move transition to substates — On a transition source, "move to substates": The transition is moved to all substates
  • Introduce superstate: Select one or more states, and "Introduce superstate" — common transitions to and from the selected states are automatically placed on the new superstate
  • Wrap in parallel state: Select one or more states, "Wrap in parallel state" — The states are wrapped in a region in a new parallel state, with another empty region alongside it.
  • Introduce region: Select a state (with or without substates) — The state is converted to a parallel state with two regions, all existing substates are placed in one of the regions.

Opening this issue mainly to spark the discussion and get the ideas out there.

mogsie avatar Oct 06 '18 12:10 mogsie

Thanks @mogsie. This is a great roadmap.

ShMcK avatar Oct 08 '18 20:10 ShMcK