skip to main content
research-article

Object-oriented programming with gradual abstraction

Published:22 October 2012Publication History
Skip Abstract Section

Abstract

We describe an experimental object-oriented programming language, ASL2, that supports program development by means of a series of abstraction steps. The language allows immediate object construction, and it is possible to use the constructed objects for concrete problem solving tasks. Classes and class hierarchies can be derived from the objects - via gradual abstraction steps. We introduce two levels of object classification, called weak and strong object classification. Strong object classification relies on conventional classes, whereas weak object classification is looser, and less restrictive. As a central mechanism, weakly classified objects are allowed to borrow methods from each other. ASL2 supports class generalization, as a counterpart to class specialization and inheritance in mainstream object-oriented programming languages. The final abstraction step discussed in this paper is a syntactical abstraction step that derives a source file with a syntactical class form.

References

  1. Actionscript home page, 2012. http://www.actionscript.org/.Google ScholarGoogle Scholar
  2. Ecmascript language specification, 2012. http://www.ecma-international.org/publications/standards/Ecma-262.htm.Google ScholarGoogle Scholar
  3. What is Impromptu?, 2012. http://impromptu.moso.com.au/.Google ScholarGoogle Scholar
  4. Javascript home page, 2012. https://developer.mozilla.org/en/About_JavaScript.Google ScholarGoogle Scholar
  5. Metaocaml home page, 2012. http://www.metaocaml.org/.Google ScholarGoogle Scholar
  6. Visual studio developer center, visual F#, 2012. http://msdn.microsoft.com/en-us/vstudio/hh388569.aspx.Google ScholarGoogle Scholar
  7. H. Abelson, G. J. Sussman, and J. Sussman. Structure and Interpretation of Computer Programs. The MIT Press, 1985. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. E. Allen, D. Chase, C. Flood, V. Luchangco, J.-W. Maessen, S. Ryu, and G. L. Steele. Project Fortress. Linux Magazine, September 2007.Google ScholarGoogle Scholar
  9. ing(2002)}BlueJbookD. J. Barnes and M. Kölling. Objects First with Java: A Practical Introduction Using BlueJ. Prentice Hall, October 2002.Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. J. Bennedsen and C. Schulte. What does 'objects-first' mean? an international study of teachers' perceptions of objects-first. In R. Lister and Simon, editors, phSeventh Baltic Sea Conference on Computing Education Research (Koli Calling 2007), volume 88 of CRPIT, pages 21--29, Koli National Park, Finland, 2007. ACS. Google ScholarGoogle ScholarDigital LibraryDigital Library
  11. G. Bierman, E. Meijer, and M. Torgersen. Adding dynamic types to c. In Proceedings of the 24th European conference on Object-oriented programming, ECOOP'10, pages 76--100, Berlin, Heidelberg, 2010. Springer-Verlag. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. A. P. Black, K. B. Bruce, and J. Noble. Panel: designing the next educational programming language. In SPLASH/OOPSLA Companion, pages 201--204, 2010. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. G. Bracha. Pluggable type systems. In OOPSLA'04 Workshop on Revival of Dynamic Languages, 2004.Google ScholarGoogle Scholar
  14. G. Bracha and D. Ungar. Mirrors: design principles for meta-level facilities of object-oriented programming languages. In Proceedings of OOPSLA 2004, pages 331--344. ACM Press, October 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  15. S. Cooper, W. Dann, and R. Pausch. Teaching objects-first in introductory computer science. SIGCSE Bulletin, 35 (1): 191--195, Jan. 2003. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. E. Gamma, R. Helm, R. Johnson, and J. Vlissides. Design Patterns: Elements of Reusable Object-oriented Software. Addison Wesley, Reading, 1996. ISBN 0--201--63361--2. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. A. Goldberg and D. Robson. Smalltalk-80 The Language and its Implementation. Addison-Wesley Publishing Company, 1983. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. I. Hadar and U. Leron. How intuitive is object-oriented design? Commun. ACM, 51 (5): 41--46, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  19. S. Hanenberg. An experiment about static and dynamic type systems: doubts about the positive impact of static type systems on development time. In Proceedings of the ACM international conference on Object oriented programming systems languages and applications, OOPSLA '10, pages 22--35, New York, NY, USA, 2010. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  20. K. Knowles, A. Tomb, J. Gronski, S. N. Freund, and C. Flanagan. Sage: Unified hybrid checking for first-class types, general refinement types, and dynamic (extended report.), 2007. http://sage.soe.ucsc.edu/sage-tr.pdf.Google ScholarGoogle Scholar
  21. W. R. LaLonde, D. A. Thomas, and J. R. Pugh. An exemplar based Smalltalk. In Conference proceedings on Object-oriented programming systems, languages and applications, OOPLSA '86, pages 322--330, New York, NY, USA, 1986. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  22. H. Lieberman. Using prototypical objects to implement shared behavior in object oriented systems. In The proceedings of OOPSLA'86, pages 214--223, 1986. Google ScholarGoogle ScholarDigital LibraryDigital Library
  23. Microsoft Corporation. The C# language specification version 4.0, 2010. http://www.microsoft.com/downloads/.Google ScholarGoogle Scholar
  24. K. Nørmark, L. Leth-Thomsen, and K. Torp. Reflections on the teaching of programming, chapter Mini Project Programming Exams, pages 229--243. Springer Verlag, LNCS 4821, 2008.Google ScholarGoogle Scholar
  25. K. Nørmark, B. Thomsen, and L. Leth-Thomsen. Mapping and visiting in functional and object-oriented programming. Journal of Object Technology, 7 (7), September-October 2008.Google ScholarGoogle ScholarCross RefCross Ref
  26. K. Nørmark, B. Thomsen, and L. L. Thomsen. The ASL2 home page, 2012.knurlasl2/.Google ScholarGoogle Scholar
  27. M. Odersky, L. Spoon, and B. Venners. Programming in Scala, Second Edition. Artima Incorporation, USA, 2010.Google ScholarGoogle Scholar
  28. J. G. Siek and W. Taha. Gradual typing for functional languages. In Scheme and Functional Programming Workshop, September 2006.Google ScholarGoogle Scholar
  29. J. G. Siek and W. Taha. Gradual typing for objects. In ECOOP'07: 21st European Conference on Object-Oriented Programming, 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  30. S. Slade. The T programming language - A dialect of Lisp. Prentice-Hall, 1987. Google ScholarGoogle ScholarDigital LibraryDigital Library
  31. G. L. Steele. Common Lisp, the language, 2nd Edition. Digital Press, 1990. Google ScholarGoogle ScholarDigital LibraryDigital Library
  32. A. Stuchlik and S. Hanenberg. Static vs. dynamic type systems: an empirical study about the relationship between type casts and development time. In Proceedings of the 7th symposium on Dynamic languages, DLS '11, pages 97--106, New York, NY, USA, 2011. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  33. W. Taha. A gentle introduction to multi-stage programming. In C. Lengauer, D. Batory, C. Consel, and M. Odersky, editors, Domain-Specific Program Generation, volume 3016 of phLecture Notes in Computer Science, pages 30--50. Springer Berlin / Heidelberg, 2004.Google ScholarGoogle Scholar
  34. B. Thomsen. phReflections on the teaching of programming, chapter Using On-Line Tutorials in Introductory IT Courses, pages 68--74. Springer Verlag, LNCS 4821, 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  35. ark}Thomsen09aL. L. Thomsen, B. Thomsen, and K. Nørmark. Computational abstraction steps. phJournal of Object Technology, 9 (6): 1--23, November 2010.Google ScholarGoogle ScholarCross RefCross Ref
  36. S. Tobin-Hochstadt and M. Felleisen. Interlanguage migration: from scripts to programs. In phCompanion to the 21st ACM SIGPLAN symposium on Object-oriented programming systems, languages, and applications, OOPSLA '06, pages 964--974, New York, NY, USA, 2006. ACM. Google ScholarGoogle ScholarDigital LibraryDigital Library
  37. D. Ungar and R. B. Smith. SELF: The power of simplicity. Lisp and Symbolic Computation: An International Journal, 4 (3): 187 -- 205, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  38. D. Ungar, C. Chambers, B. wei Chang, and U. Hölzle. Organizing programs without classes. In Lisp and Symbolic Computation, pages 223--242. Kluwer Academic Publishers, 1991. Google ScholarGoogle ScholarDigital LibraryDigital Library
  39. T. Wrigstad. StOP - internal workshop series on scripts to programs. http://wrigstad.com/stop/. http://wrigstad.com/stop/.Google ScholarGoogle Scholar

Index Terms

  1. Object-oriented programming with gradual abstraction

    Recommendations

    Reviews

    Alexandre Bergel

    Object-oriented programming (OOP) is a highly preferred approach for implementing software artifacts. Despite the modeling expressiveness of OOP and the popularity of many programming languages supporting it, the notions and concepts involved in class-based object orientation are hard to learn and prone to design errors by nonexperts. The traditional way to program with objects and classes requires the programmer to first define classes and then orchestrate the interaction of class instances. The authors of this paper propose reversing this process: define classless objects, also known as prototypes, first; then, generalize and abstract a web of interacting objects, and only then extract classes from the generalized objects. The paper proposes innovative elementary operators that enable a bottom-up process for designing class-based, object-based applications. Although significant research efforts have been expended on related topics, such as mixing functional and OOP approaches, gradual typing, and prototype-based programming, this is apparently the first paper to tackle the issues of class construction from groups of objects. Although only small examples are included, mainly for pedagogical purposes, it is easy to see the potential of the proposed ideas for promoting better design and teaching object orientation. Online Computing Reviews Service

    Access critical reviews of Computing literature here

    Become a reviewer for Computing Reviews.

    Comments

    Login options

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

    Sign in

    Full Access

    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!