Abstract
In addition to traditional object-oriented (OO) concepts such as inheritance and polymorphism, several modularization and composition mechanisms like e.g. traits, mixins and virtual classes have emerged. The Package Template mechanism is another attempt at providing a flexible mechanism for modularization, composition and adaption.
Dynamic languages have traditionally employed strong support for meta-programming, with hooks to control OO concepts such as method invocation and object construction, by utilizing meta-classes and meta-object protocols.
In this work, we attempt to bring a corresponding degree of meta-level control to composition primitives, with a concrete starting point in the package template mechanism as developed for the dynamic language Groovy. We wish to support a wide range of possible composition semantics, and to make such choices available to the developer through a meta-level API. This API should be extensible, and the semantic variations should be applied within well-defined scopes.
- }}I. Aracic, V. Gasiunas, M. Mezini, and K. Ostermann. An overview of CaesarJ. In Trans. AOSD I, volume 3880 of LNCS, pages 135--173. Springer Berlin / Heidelberg, 2006. Google Scholar
Digital Library
- }}E. Axelsen and S. Krogdahl. Groovy package templates - supporting reuse and runtime adaption of class hierarchies. In Proc. Dynamic Languages Symposium '09, 2009. Google Scholar
Digital Library
- }}E. Axelsen and S. Krogdahl. Towards pluggable design patterns utilizing package templates. In Proc. Norsk Informatikkonferanse '09, 2009.Google Scholar
- }}G. Bracha, P. V. D. Ahé, V. Bykov, Y. Kashai, and E. Mir. Modules as objects in newspeak. In ECOOP 2010: Proc. 24th European Conference on Object Oriented Programming, 2010. Google Scholar
Digital Library
- }}G. Bracha and W. Cook. Mixin-based inheritance. In N. Meyrowitz, editor, Proc. Conf. O-O. Prog.: Syst., Lang., and Appl. / Proc. ECOOP, pages 303--311, Ottawa, Canada, 1990. ACM Press. Google Scholar
Digital Library
- }}T. Dinkelaker, M. Mezini, and C. Bockisch. The art of the meta-aspect protocol. In AOSD '09: Proceedings of the 8th ACM international conference on Aspect-oriented software development, pages 51--62, New York, NY, USA, 2009. ACM. Google Scholar
Digital Library
- }}R. Eckstein. Mixins in JavaFX 1.2 technology. Sun Microsystems, URL: http://java.sun.com/developer/ technicalArticles/javafx/mixin/, 2009.Google Scholar
- }}Éric Tanter.Expressive scoping of dynamically-deployed aspects. In AOSD '08: Proceedings of the 7th international conference on Aspect-oriented software development, pages 168--179, New York, 2008. ACM. Google Scholar
Digital Library
- }}E. Ernst. gbeta - a language with virtual attributes, block structure, and propagating, dynamic inheritance, 1999.Google Scholar
- }}R. Field. JavaFX language reference. Sun Microsystems, URL: https://openjfx.dev.java.net/langref/.Google Scholar
- }}E. Gamma, R. Helm, R. Johnson, and J. Vlissides. Design Patterns-Elements of Reusable Object-Oriented Software. Addison-Wesley, 1994. Google Scholar
Digital Library
- }}J. Gosling, B. Joy, G. Steele, and G. Bracha. Java Language Specification, Second Edition: The Java Series. Addison-Wesley Longman Publishing Co., Inc., Boston, MA, USA, 2000. Google Scholar
Digital Library
- }}The Groovy homepage. URL: http://groovy.codehaus.org.Google Scholar
- }}Groovy: Runtime vs compile time, static vs dynamic. URL: http://groovy.codehaus.org/Runtime+vs+Compile+time,+Static+vs+Dynamic.Google Scholar
- }}W. Harrison and H. Ossher. Subject-oriented programming: a critique of pure objects. In OOPSLA '93: Proceedings of the eighth annual conference on Object-oriented programming systems, languages, and applications, pages 411--428, New York, NY, USA, 1993. ACM. Google Scholar
Digital Library
- }}G. Kiczales. Beyond the black box: Open implementation. IEEE Softw., 13:8--11, January 1996. Google Scholar
Digital Library
- }}G. Kiczales, J. des Rivieres, and D. G. Bobrow. The art of the metaobject protocol. MIT Press, Cambridge, MA, USA, 1991. Google Scholar
Digital Library
- }}G. Kiczales, J. Lamping, A. Menhdhekar, C. Maeda, C. Lopes, J.-M. Loingtier, and J. Irwin. Aspect-oriented programming. In M. Aks 'it and S. Matsuoka, editors, Proceedings European Conference on Object-Oriented Programming, volume 1241, pages 220--242. Springer-Verlag, Berlin, Heidelberg, and New York, 1997.Google Scholar
- }}S. Krogdahl, B. Møller-Pedersen, and F. Sørensen. Exploring the use of package templates for flexible re-use of collections of related classes. Journal of Object Technology, 8(7):59--85, 2009.Google Scholar
Cross Ref
- }}G. R. Lavender and D. C. Schmidt. Active object: an object behavioral pattern for concurrent programming. Proc.Pattern Languages of Programs,, 1995. Google Scholar
Digital Library
- }}B. Liskov and L. Shrira. Promises: linguistic support for efficient asynchronous procedure calls in distributed systems. In PLDI '88: Proceedings of the ACM SIGPLAN 1988 conference on Programming Language design and Implementation, pages 260--267, New York, NY, USA, 1988. ACM. Google Scholar
Digital Library
- }}O. L. Madsen and B. Møller-Pedersen. Virtual classes: a powerful mechanism in object-oriented programming. In OOPSLA '89: Conference proceedings on Object-oriented programming systems, languages and applications, pages 397--406, New York, NY, USA, 1989. ACM. Google Scholar
Digital Library
- }}O. L. Madsen, B. Møller-Pedersen, and K. Nygaard. Object-Oriented Programming in the BETA Programming Language. Addison-Wesley, 1993. Google Scholar
Digital Library
- }}The NetBeans homepage. URL: http://netbeans.org/.Google Scholar
- }}N. Nystrom, X. Qi, and A. C. Myers. J&: nested intersection for scalable software composition. In OOPSLA '06, pages 21--36, New York, 2006. ACM. Google Scholar
Digital Library
- }}H. Ossher, M. Kaplan, W. Harrison, A. Katz, and V. Kruskal. Subject-oriented composition rules. SIG-PLAN Not., 30(10):235--250, 1995. Google Scholar
Digital Library
- }}H. Ossher and P. Tarr. Hyper/j: multi-dimensional separation of concerns for java. In ICSE '00: Proceedings of the 22nd international conference on Software engineering, pages 734--737, New York, NY, USA, 2000. ACM. Google Scholar
Digital Library
- }}N. Scharli, S. Ducasse, O. Nierstrasz, and A. Black. Traits: Composable units of behavior. In ECOOP 2003, volume 2743 of LNCS, pages 327--339. Springer Berlin / Heidelberg, 2003.Google Scholar
Cross Ref
- }}F. Sørensen, E. W. Axelsen, and S. Krogdahl. Dynamic composition with package templates. In P. Lahire, editor, Proceedings of the First International Workshop on Composition: Objects, Aspects, Components, Services and Product Lines. CEUR-WS.org, 2010.Google Scholar
Index Terms
Controlling dynamic module composition through an extensible meta-level API
Recommendations
Controlling dynamic module composition through an extensible meta-level API
DLS '10: Proceedings of the 6th symposium on Dynamic languagesIn addition to traditional object-oriented (OO) concepts such as inheritance and polymorphism, several modularization and composition mechanisms like e.g. traits, mixins and virtual classes have emerged. The Package Template mechanism is another attempt ...
Groovy package templates: supporting reuse and runtime adaption of class hierarchies
DLS '09: Proceedings of the 5th symposium on Dynamic languagesWe show how package templates, a modularization mechanism originally developed for statically typed languages like Java and C#, can be applied to and implemented in a dynamic language like Groovy, by using the language's capabilities for meta-...
Groovy package templates: supporting reuse and runtime adaption of class hierarchies
DLS '09We show how package templates, a modularization mechanism originally developed for statically typed languages like Java and C#, can be applied to and implemented in a dynamic language like Groovy, by using the language's capabilities for meta-...







Comments