Formal Methods in System Design

, Volume 43, Issue 1, pp 1–28 | Cite as

Modeling and visualizing object-oriented programs with Codecharts

Article

Abstract

Software design, development and evolution commonly require programmers to model design decisions, visualize implemented programs, and detect conflicts between design and implementation. However, common design notations rarely reconcile theoretical concerns for rigor and minimality with the practical concerns for abstraction, scalability and automated verifiability. The language of Codecharts was designed to overcome these challenges by narrowing its scope to visual specifications that articulate automatically-verifiable statements about the structure and organization of object-oriented programs. The tokens in its visual vocabulary stand for the building-blocks of object-oriented design, such as inheritance class hierarchies, sets of dynamically-bound methods, and their correlations. The formalism was tailored for those pragmatic concerns which arise from modeling class libraries and design patterns, and for visualizing programs of any size at any level of abstraction. We describe design verification, a process of proving or refuting that a Java program (i.e. its native code) conforms to the Codechart specifying it. We also describe a toolkit which supports modeling and visualization with Codecharts, as well as a fully-automated design verification tool. We conclude with empirical results which suggest gains in both speed and accuracy when using Codecharts in software design, development and evolution.

Keywords

Design notations and documentation Object-oriented programming Patterns Design concepts 

References

  1. 1.
    Brooks FP (1987) No silver bullet: essence and accidents of software engineering. IEEE Comput Mag 20(4):10–19 MathSciNetCrossRefGoogle Scholar
  2. 2.
    Lehman MM (1996) Laws of software evolution revisited. In: Proc 5th European workshop software process technology—EWSPT’96, Nancy, France Google Scholar
  3. 3.
    Grant M, Goguen JA (1996) An executable course in the algebraic semantics of imperative programs. In: Dean NC, Hinchey MG (eds) Teaching and learning formal methods. Morgan Kaufmann, San Mateo, pp 161–179 Google Scholar
  4. 4.
    Eden AH, Gasparis E, Nicholson J (2007) LePUS3 and Class-Z reference manual. Department of Computer Science, University of Essex, CSM-474, ISSN 1744-8050, Dec Google Scholar
  5. 5.
    Eden AH, Gasparis E, Nicholson J (2007) The ‘Gang of Four’ companion: formal specification of design patterns in LePUS3 and class-Z. Department of Computer Science, University of Essex, CSM-472, Dec Google Scholar
  6. 6.
    Eden AH, Gasparis E (2009) Three controlled experiments in software engineering with the two-tier programming toolkit: final report. University of Essex, CES-496, ISSN 1744-8050 Google Scholar
  7. 7.
    Nicholson J, Gasparis E, Eden AH LePUS3 and class-Z home page [Online]. Available: http://www.lepus.org.uk/. Accessed: 27 Aug 2010
  8. 8.
    Nicholson J, Gasparis E, Eden AH The two-tier programming project website [Online]. Available: http://ttp.essex.ac.uk/. Accessed: 14 Apr 2008
  9. 9.
    Gasparis E, Eden AH, Nicholson J, Kazman R (2008) The design navigator: charting Java programs. In: Tool demonstrations, proc of 30th IEEE int’l conf on software engineering—ICSE 2008, Leipzig, Germany Google Scholar
  10. 10.
    Gasparis E, Nicholson J, Eden AH (2008) LePUS3: an object-oriented design description language. In: Proc 5th int’l conf diagrammatic representation & inference, Herrsching, Germany, vol 5223 Google Scholar
  11. 11.
    Gasparis E, Nicholson J, Eden AH, Kazman R (2008) Navigating through the design of object-oriented programs. In: Proc of the 15th working conf on reverse engineering—WCRE, Antwerp, Belgium Google Scholar
  12. 12.
    Eden AH, Nicholson J (2011) Codecharts: roadmaps and blueprints for object-oriented programs. Wiley-Blackwell, New York MATHCrossRefGoogle Scholar
  13. 13.
    Medvidovic N, Taylor RN (2000) A classification and comparison framework for software architecture description languages. IEEE Trans Softw Eng 26(1):70–93 CrossRefGoogle Scholar
  14. 14.
    Taibi T (ed) (2007) Design patterns formalization techniques. IGI Global, Hershey Google Scholar
  15. 15.
    Demeyer S, Ducasse S, Tichelaar S, Tichelaar E (1999) Why unified is not universal: UML shortcomings for coping with round-trip engineering. In: Proc 2nd int’l conf on the unified modeling language, vol 1723, pp 630–645 CrossRefGoogle Scholar
  16. 16.
    Fowler M (2004) UML distilled: a brief guide to the standard object modeling language, 3rd edn. Addison-Wesley, Boston Google Scholar
  17. 17.
    Harel D (1987) Statecharts: a visual formalism for complex systems. Sci Comput Program 8(3):231–274 MathSciNetMATHCrossRefGoogle Scholar
  18. 18.
    Guttag JV, Horning JJ, Wing J (1982) Some notes on putting formal specifications to productive use. Sci Comput Program 2(1):53–68 MATHCrossRefGoogle Scholar
  19. 19.
    Guttag JV, Horning JJ (1993) Larch: languages and tools for formal specification. Springer, New York MATHCrossRefGoogle Scholar
  20. 20.
    Pnueli A (1986) Applications of temporal logic to the specification and verification of reactive systems: a survey of current trends. In: Bakker JW (ed) Current trends in concurrency. Overviews and tutorials. Springer, New York, pp 510–584 CrossRefGoogle Scholar
  21. 21.
    Jones CB (1990) Systematic software development using VDM, 2nd edn. Prentice Hall International, New York MATHGoogle Scholar
  22. 22.
    Peterson J (1981) Petri net theory and the modeling of systems. Prentice-Hall, Englewood Cliffs Google Scholar
  23. 23.
    Hoare CAR (1978) Communicating sequential processes. Commun ACM 21(8):666–677 MathSciNetMATHCrossRefGoogle Scholar
  24. 24.
    Jackson D (2002) Alloy: a lightweight object modeling notation. ACM Trans Softw Eng Methodol 11(2):256–290 CrossRefGoogle Scholar
  25. 25.
    Abrial J-R (1996) The B-book: assigning programs to meanings. Cambridge University Press, Cambridge MATHCrossRefGoogle Scholar
  26. 26.
    Derrick J, Boiten E (2001) Refinement in Z and object-Z: foundations and advanced applications. Springer, Berlin MATHGoogle Scholar
  27. 27.
    France RB, Kim D-K, Ghosh S, Song E (2004) A UML-based pattern specification technique. IEEE Trans Softw Eng 30(3):193–206 CrossRefGoogle Scholar
  28. 28.
    Kim D-K (2004) A meta-modeling approach to specifying patterns. PhD Dissertation, Colorado State University, Fort Collins, CO, USA Google Scholar
  29. 29.
    Kent S (1997) Constraint diagrams: visualizing invariants in object-oriented models. In: ACM SIGPLAN notices, New York, NY, USA, pp 327–341 Google Scholar
  30. 30.
    Howse J, Molina F, Taylor J, Kent S, Gil J (2001) Spider diagrams: a diagrammatic reasoning system. J Vis Lang Comput 12(3):299–324 CrossRefGoogle Scholar
  31. 31.
    Object Management Group (2005) UML 2.0 superstructure specification, Aug 2005 Google Scholar
  32. 32.
    Tufte E (1997) Visual explanations: images and quantities, evidence and narrative. Graphics Press, Cheshire MATHGoogle Scholar
  33. 33.
    Maplesden D, Hosking J, Grundy J (2007) A visual language for design pattern modeling and instantiation. In: Taibi T (ed) Design patterns formalization techniques. IGI Global, Hershey Google Scholar
  34. 34.
    Guéhéneuc Y-G, Antoniol G (2008) DeMIMA: a multilayered approach for design pattern identification. IEEE Trans Softw Eng 34(5):667–684 CrossRefGoogle Scholar
  35. 35.
    Blewitt A, Bundy A, Stark I (2001) Automatic verification of Java design patterns. In: Proceedings of the 16th IEEE international conference on automated software engineering, pp 324–333 Google Scholar
  36. 36.
    Gosling J, Joy B, Steele G, Bracha G (2005) The Java language specification, 3rd edn. Addison-Wesley Professional, Reading Google Scholar
  37. 37.
    Smith B (2004) Ontology. In: Floridi L (ed) The Blackwell guide to the philosophy of computing and information. Blackwell Publishers, Malden Google Scholar
  38. 38.
    Nicholson J (2011) On the theoretical foundations of LePUS3 and its application to object-oriented design verification. PhD Dissertation, School of Computer Science and Electronic Engineering, University of Essex Google Scholar
  39. 39.
    Lieberman BA (2006) The art of software modeling, annotated edn. Auerbach Publications, Boca Raton CrossRefGoogle Scholar
  40. 40.
    Hoare CAR (1975) Software design: a parable. Softw World 5(9–10):53–56 Google Scholar
  41. 41.
    Walsh AE, Gehringer D (2002) Java 3D: API jump-start. Prentice Hall, Upper Saddle River Google Scholar
  42. 42.
    Selman D (2002) Java 3D programming. Manning Publications, Greenwich Google Scholar
  43. 43.
    Cai Y, Ianuzzi D, Wong S (2011) Leveraging design structure matrices in software design education. Presented at the conf on software engineering education and training—CSEET 2011, Honolulu, HI Google Scholar
  44. 44.
    Nicholson J, Eden AH, Gasparis E (2007) Verification of LePUS3/class-Z specifications: sample models and abstract semantics for Java 1.4. Department of Computer Science, University of Essex, Technical Report CSM-471, Dec 2007 Google Scholar
  45. 45.
    Gamma E, Helm R, Johnson R, Vlissides J (1995) Design patterns: elements of reusable object-oriented software. Addison Wesley Longman, Reading Google Scholar
  46. 46.
    Chikofsky EJ, Cross JH (1990) Reverse engineering and design recovery: a taxonomy. IEEE Softw 7(1):13–17 CrossRefGoogle Scholar
  47. 47.
    Gasparis E (2010) Design navigation: recovering design charts from object-oriented programs. PhD Dissertation, School of Computer Science and Electronic Engineering, University of Essex Google Scholar
  48. 48.
    Shermer M (2005) The Feynman-Tufte principle. Sci Am 292(4):38 CrossRefGoogle Scholar
  49. 49.
    Nicholson J, Gasparis E, Eden AH, Kazman R (2009) Automated verification of design patterns with LePUS3. In: Proc 1st NASA formal methods symp—NFM 2009, Moffett Field, CA Google Scholar
  50. 50.
    Eckel B (2003) Thinking in Java. Prentice Hall Professional, Upper Saddle River Google Scholar
  51. 51.
    Wing JM (1990) A specifier’s introduction to formal methods. Computer 23(9):8–23 CrossRefGoogle Scholar
  52. 52.
    Hoare CAR (1969) An axiomatic basis for computer programming. Commun ACM 12(10):576–580 MATHCrossRefGoogle Scholar
  53. 53.
    Mahoney MS (2002) Software as science: science as software. In: Proc int’l conf history of computing: software issues, Paderborn, Germany, pp 25–48 CrossRefGoogle Scholar
  54. 54.
    Clarke EM, Wing JM (1996) Formal methods: state of the art and future directions. ACM Comput Surv 28(4):626–643 CrossRefGoogle Scholar
  55. 55.
    Parnas DL (1994) Software aging. In: Proc 16th int’l conf software engineering, pp 279–287 CrossRefGoogle Scholar
  56. 56.
    Mens T, Demeyer S (2008) Software evolution. Springer, Berlin MATHGoogle Scholar
  57. 57.
    Perry DE, Wolf AL (1992) Foundations for the study of software architecture. SIGSOFT Softw Eng Notes 17(4):40–52 CrossRefGoogle Scholar
  58. 58.
    Salazar Saltijeral J (2012) Design pattern detection in Java. MSc dissertation, School of Computer Science and Electronic Engineering, University of Essex Google Scholar
  59. 59.
    D’Hondt T, De Volder K, Mens K, De K, Kim V, Wuyts R (2000) Co-evolution of object-oriented software design and implementation. In: Proc int’l symposium on software architectures and component technology— SACT, Amsterdam, The Netherlands Google Scholar
  60. 60.
    Commons C (2001) Creative commons—attribution-NoDerivs 2.0 UK: England & Wales [Online]. Available: http://creativecommons.org/licenses/by-nd/2.0/uk/. Accessed: 20 Apr 2011

Copyright information

© Springer Science+Business Media New York 2013

Authors and Affiliations

  • A. H. Eden
    • 1
  • E. Gasparis
    • 1
  • J. Nicholson
    • 2
  • R. Kazman
    • 3
    • 4
  1. 1.School of Computer Science & Electronic EngineeringUniversity of EssexColchesterUK
  2. 2.School of Computing, Engineering and MathematicsUniversity of BrightonBrightonUK
  3. 3.University of HawaiiHonoluluUSA
  4. 4.Software Engineering InstituteCarnegie-Mellon UniversityPittsburghUSA

Personalised recommendations