Advertisement

Formal Aspects of Computing

, Volume 18, Issue 4, pp 397–420 | Cite as

On modelling recursive calls and callbacks with two variants of Unified Modelling Language state diagrams

  • Jennifer Tenzer
  • Perdita Stevens
ORIGINAL ARTICLE

Abstract

An important use of the Unified Modelling Language (UML) is modelling synchronous object-oriented software systems. State diagrams are used to model interesting object behaviour, including method invocation. However, almost all previous work formalising state diagrams has assumed asynchronous communication. We show that UML’s “run to completion” semantics leads to anomalous behaviour in the synchronous case, and in particular that it is not possible to model recursive calls, in which an object receives a second synchronous message whilst still in the process of reacting to the first. We propose a solution using state diagrams in two complementary ways.

Keywords

UML Object-oriented modelling Protocol state machines State machines Recursion Callbacks 

Preview

Unable to display preview. Download preview PDF.

Unable to display preview. Download preview PDF.

References

  1. AEY01.
    Alur R, Etessami K, Yannakakis M (2001) Analysis of recursive state machines. In: Proceedings of computer aided verification, CAV’01. LNCS; vol 2102. Springer; Berlin Heidelberg New York, pp 207–220Google Scholar
  2. Arg.
    The Argo UML Project. Website at http://argouml.tigris.org/Google Scholar
  3. BCR02.
    Börger E, Cavarra A, Riccobene E (2002) A precise semantics of UML state machines: making semantic variation points and ambiguities explicit. In: Proceedings of semantic foundations of engineering design languages, SFEDL, Satellite workshop of ETAPS’02Google Scholar
  4. BGR01.
    Benedikt M, Godefroid P, Reps TW (2001) Model checking of unrestricted hierarchical state machines. In: Proceedings of automata, languages and programming, ICALP’01. LNCS; vol 2076; Springer; Berlin Heidelberg New York, pp 652–666Google Scholar
  5. BRJ98.
    Booch G, Rumbaugh J, Jacobson I (1998). The unified modeling language user guide. Addison Wesley Longman, EssexGoogle Scholar
  6. GHJV95.
    Gamma E, Helm R, Johnson R, Vlissides J (1995) Design patterns: elements of reusable object-oriented software. Addison Wesley, ReadingGoogle Scholar
  7. GLS01.
    Grosu R, Liu YA, Smolka SA, Stoller SD, Yan J (2001) Automated software engineering using concurrent class machines. In: Proceeding‘s of automated software engineering, ASE’01. IEEE, Los AlamitosGoogle Scholar
  8. GPP98.
    Gogolla M, Parisi-Presicce F (1998) State diagrams in UML: a formal semantics using graph transformations. In: Proceedings of the workshop on precise semantics for modeling techniques, PSMT’98. Technische Universität München, TUM-I9803Google Scholar
  9. Gra98.
    Grand M (1998) Patterns in Java, vol 1. Wiley, NewyorkGoogle Scholar
  10. Gru02.
    Gruntz D (2002) Java design: on the observer pattern. Java Report,February Harel D, Gery E (1997) Executable object modeling with statecharts. IEEE Comput 30:7:31–42Google Scholar
  11. HG97.
    Harel D, Gery E (1997) Executable object modeling with statecharts. IEEE Comput 30:7:31–42Google Scholar
  12. Kus01.
    Kuske S (2001) A formal semantics of UML state machines based on structured graph transformation. In: Proceedings of the 4th international conference on the unified modeling language, UML’01. LNCS, vol 2185. Springer, Berlin Heidelberg Newyork, pp 241–256Google Scholar
  13. LMM99.
    Latella D, Majzik I, Massink M (1999) Towards a formal operational semantics of UML statechart diagrams. In: Proceedings of formal methods for open object-based distributed systems, FMOODS’99, IFIP, vol 139 Kluwer, DordrechtGoogle Scholar
  14. MSL99.
    Mikhajlov L, Sekerinski E, Laibinis L (1999) Developing components in the presence of re-entrance. In: Proceedings of formal methods—FM’99. LNCS, vol 1709 . Springer, Berlin Heidelberg Newyork, pp 1301–1320Google Scholar
  15. OMG03.
    Object Management Group OMG (2003) Unified modeling language specification version 1.5, March 2003. Available from http://www.omg.org/uml/ as formal/03-03-01Google Scholar
  16. OMG04.
    Object Management~Group OMG (2004) UML2.0 superstructure specification, October 2004. Available from http://www.omg. org/uml/ as ptc/04-10-02Google Scholar
  17. Par03.
    Utwo Partners (2003) Unified modeling language 2.0 proposal, version 2.0, April 2003. Available from http://www.u2-partners.org/.Google Scholar
  18. RACH00.
    Reggio G, Astesiano E, Choppy C, Hussmann H (2000) Analysing UML active classes and associated state machines —a lightweight formal approach. In: Proceedings of fundamental approaches to software engineering, FASE’00. LNCS, vol 1783. Springer, Berlin Heidelberg Newyork, pp 127–146Google Scholar
  19. Szy98.
    Szyperski C (1998) Component software: beyond object-oriented programming. ACM Press, Addison Wesley, ReadingGoogle Scholar
  20. TS03.
    Tenzer J, Stevens P (2003) Modelling recursive calls with UML state diagrams. In: Proceedings of fundamental approaches to software engineering. LNCS, vol 2621. Springer, Berlin Heidelberg Newyork pp 135–149Google Scholar
  21. vdB01.
    von der Beeck, M (2001) Formalization of UML-statecharts. In: Proceedings of the 4th international conference on the unified modeling language, UML’01. LNCS, vol 2185. Springer, Berlin Heidelberg Newyork, pp 406–421Google Scholar
  22. WK99.
    Warmer J, Kleppe A (1999) The object constraint language: precise modeling with UML. Addison Wesley,Google Scholar
  23. wRPon.
    Stevens P,Pooley R (1999) Using UML: software engineering with objects and components (updated edition). Addison Wesley Longman,EssexGoogle Scholar

Copyright information

© British Computer Society 2006

Authors and Affiliations

  1. 1.Laboratory for Foundations of Computer Science, School of InformaticsUniversity of EdinburghEdinburghUK

Personalised recommendations