10.1145/1185448.1185519acmotherconferencesArticle/Chapter ViewAbstractPublication Pagesacm-seConference Proceedings
Article

Framework design using function generalization: a binary tree traversal case study

ABSTRACT

A software framework is a technology that enables software reuse, potentially yielding rich dividends but requiring significant long-term investment. However, a framework is not a panacea because it is more difficult to design than a single application. Systematic approaches seek to make framework design more convenient and less error-prone. This paper illustrates the function generalization approach to framework design by developing a framework for binary tree traversals. A binary tree traversal is a well known algorithm, which makes it an excellent example. The approach involves a systematic process for generalizing a fixed application expressed as Haskell functions to produce a set of functions that precisely describe the generalized application. This generalized application encompasses various common and variable aspects of a family of applications. By using design patterns as a guide, the resulting set of functions can be converted to a Java framework.

References

  1. H. C. Cunningham, Y. Liu, and C. Zhang. "Using Classic Problems to Teach Java Framework Design," Science of Computer Programming, Special Issue on Principles and Practice of Programming in Java (PPPJ 2004), Vol. 59, No. 1--2, pp. 147--169, January 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  2. H. C. Cunningham and P. Tadepalli. "Using Function Generalization to Design a Cosequential Processing Framework," In Proceedings of the 39th Hawaii International Conference on System Sciences, 10 pages, IEEE, January 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. M. Fontoura, W. Pree, B. Rumpe, The UML Profile for Framework Architectures, Addison-Wesley, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. E. Gamma, R. Helm, R. Johnson, J. Vlissides, Design Patterns: Elements of Reusable Object-Oriented Software, Addison-Wesley, 1995. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. J. Gibbons. "Patterns in Datatype-Generic Programming," In Declarative Programming in the Context of Object-oriented Languages, Uppsala, Sweden, August 2003.Google ScholarGoogle Scholar
  6. M. T. Goodrich and R. Tamassia, Data Structures and Algorithms in Java, 3rd Edition, Wiley, 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. D. R. Musser, G. J. Derge, and A. Saini. STL Tutorial and Reference Guide: C++ Programming with the Standard Template Library, Second edition, Addison-Wesley, 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. D. L. Parnas. "On the Design and Development of Program Families," IEEE Transactions on Software Engineering, Vol. SE-2, pp. 1--9, March 1976.Google ScholarGoogle ScholarDigital LibraryDigital Library
  9. D. L. Parnas. "Designing Software for Ease of Extension and Contraction," IEEE Transactions on Software Engineering, Vol. SE-5, pp. 128--138, March 1979.Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. S. Peyton Jones. Haskell 98 Language and Libraries: The Revised Report, Cambridge University Press, 2003.Google ScholarGoogle Scholar
  11. D. Roberts and R. Johnson, "Patterns for Evolving Frameworks," In R. Martin, D. Riehle, F. Buschmann (Eds.), Pattern Languages of Program Design 3, pp. 471--486, Addison-Wesley, 1998. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. H. A. Schmid. "Framework Design by Systematic Generalization," In Building Application Frameworks: Object-Oriented Foundations of Framework Design, M. E. Fayad, D. C. Schmidt, and R. E. Johnson, Eds. Wiley, 1999, pp. 353--378.Google ScholarGoogle Scholar
  13. J. Visser. "Visitor Combination and Traversal Control," In Proceedings of the Conference on Object-Oriented Programming Systems, Languages, and Applications (OOPSLA '01), pp. 270--282, October 2001. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Framework design using function generalization: a binary tree traversal case study

      Comments

      Login options

      Check if you have access through your login credentials or your institution to get full access on this article.

      Sign in

      PDF Format

      View or Download as a PDF file.

      PDF

      eReader

      View online with eReader.

      eReader
      About Cookies On This Site

      We use cookies to ensure that we give you the best experience on our website.

      Learn more

      Got it!