Combined modelling and programming support for composite states and extensible state machines

Most modelling languages support full state machine modelling, including especially composite states. Existing approaches to programming with states (state design patterns) either represent composite states by means of inheritance between state classes, or do not support composite states, and instead use inheritance for specialization of extensible state machines. In this paper, we present 1) a state design pattern using delegation to support composite states and inheritance together with virtual classes to support extensible state machines, and 2) a framework, implemented in Java, which also supports history and entry/exit actions. Together, these form the basis for developing support for state machines in a combined modelling and programming language.

[1]  Henry Lieberman,et al.  Using prototypical objects to implement shared behavior in object-oriented systems , 1986, OOPLSA '86.

[2]  David Harel,et al.  Statecharts: A Visual Formalism for Complex Systems , 1987, Sci. Comput. Program..

[3]  Ole Lehrmann Madsen Towards integration of state machines and object-oriented languages , 1999, Proceedings Technology of Object-Oriented Languages and Systems. TOOLS 29 (Cat. No.PR00275).

[4]  Ralph Johnson,et al.  design patterns elements of reusable object oriented software , 2019 .

[5]  Aletta Nylén UML - Unified Modelling Language , 2012 .

[6]  Ole Lehrmann Madsen,et al.  A unified approach to modeling and programming , 2010, MODELS'10.

[7]  Jonathan Aldrich,et al.  Typestate-oriented programming , 2009, OOPSLA Companion.

[8]  Todd D. Millstein,et al.  An Extensible State Machine Pattern for Interactive Applications , 2008, ECOOP.

[9]  Hideki Nomoto State oriented programming , 2004, Eighth IEEE International Symposium on High Assurance Systems Engineering, 2004. Proceedings..

[10]  Éric Tanter,et al.  First-class state change in plaid , 2011, OOPSLA '11.

[11]  Carl Hewitt,et al.  A Universal Modular ACTOR Formalism for Artificial Intelligence , 1973, IJCAI.

[12]  Ole Lehrmann Madsen,et al.  Virtual classes: a powerful mechanism in object-oriented programming , 1989, OOPSLA '89.