Abstract
Adaptive Programming (AP) provides advanced modularization mechanisms for traversal related concerns over data structures in object-oriented programs. Computation along a traversal is defined through specialized visitors while the traversal itself is separately defined against a graph-based model of the underlying data structure with the ability to abstract over graph node names and edges. Modifying, under certain restrictions, the program’s data structure does not alter the program’s overall behavior. Even though AP is geared towards more easily evolvable systems, certain limitations of current AP tools hamper code reuse and system evolvability. Reasoning about adaptive code becomes difficult since there is no guarantee that a modification to a data structure will not alter the meaning of the program. Furthermore, adaptive programs are defined directly against a program’s complete underlying data structure exposing unrelated information and introducing hardcoded dependencies decreasing reusability, modularity and hampering evolution. In this paper we present Demeter Interfaces through which a more thorough design method of adaptive programs allows for more resilient software. Traversal specifications and Visitors are defined against an interface class graph augmented with additional constraints that capture structural properties that must hold in order for the adaptive code to function correctly. A program implements a Demeter interface by providing a mapping between the program’s concrete data structure and the interface class graph. We show how Demeter interfaces allow for higher levels of reusability and modularity of adaptive code while the static verification of constraints guards against behavior altering modifications. We also discuss the applicability of Demeter Interfaces to XML technologies.
Keywords
These keywords were added by machine and not by the authors. This process is experimental and the keywords may be updated as the learning algorithm improves.
This is a preview of subscription content, log in via an institution.
Buying options
Tax calculation will be finalised at checkout
Purchases are for personal use only
Learn about institutional subscriptionsPreview
Unable to display preview. Download preview PDF.
References
The Demeter Group: The DAJ website (2005), http://www.ccs.neu.edu/research/demeter/DAJ
Lieberherr, K.J., Orleans, D.: Preventive program maintenance in Demeter/Java (research demonstration). In: International Conference on Software Engineering, pp. 604–605. ACM Press, Boston (1997)
Lieberherr, K.J., Riel, A.J.: Demeter: A CASE study of software growth through parameterized classes. Journal of Object-Oriented Programming 1(3), 254–264 (1988), A shorter version of this paper was presented at the 10th International Conference on Software Engineering, Singapore, pp. 254–264, IEEE Press (1998)
Mezini, M., Lieberherr, K.J.: Adaptive plug-and-play components for evolutionary software development. In: Chambers, C. (ed.) Object-Oriented Programming Systems, Languages and Applications Conference. Special Issue of SIGPLAN Notices, pp. 97–116. ACM, Vancouver (1998)
Lieberherr, K.J., Lorenz, D., Mezini, M.: Programming with Aspectual Components. Technical Report NU-CCS-99-01, College of Computer Science, Northeastern University, Boston, MA (1999)
Ovlinger, J., Wand, M.: A language for specifying recursive traversals of object structures. In: OOPSLA 1999: Proceedings of the 14th ACM SIGPLAN conference on Object-oriented programming, systems, languages, and applications, pp. 70–81. ACM Press, New York (1999)
Sung, J.: Aspectual Concepts. Technical Report NU-CCS-02-06, Northeastern University, Master’s Thesis (2002), http://www.ccs.neu.edu/home/lieber/theses-index.html
Lieberherr, K.J.: Adaptive Object-Oriented Software: The Demeter Method with Propagation Patterns, p. 616. PWS Publishing Company, Boston (1996)
Lieberherr, K., Patt-Shamir, B., Orleans, D.: Traversals of object structures: Specification and efficient implementation. ACM Trans. Program. Lang. Syst. 26(2), 370–412 (2004)
Lieberherr, K.J., Patt-Shamir, B.: The Refinement Relation of Graph-Based Generic Programs. In: Jazayeri, M., Musser, D.R., Loos, R.G.K. (eds.) Dagstuhl Seminar 1998. LNCS, vol. 1766, pp. 40–52. Springer, Heidelberg (2000)
Orleans, D., Lieberherr, K.J.: AP Library: The Core Algorithms of AP: Home page (1999), http://www.ccs.neu.edu/research/demeter/AP-Library/
Skotiniotis, T., Lorenz, D.: Conaj: Generating contracts as aspects. Technical Report NU-CCIS-04-03, College of Computer and Information Science, Northeastern University (2004)
Skotiniotis, T., Lorenz, D.H.: Cona: aspects for contracts and contracts for aspects. In: OOPSLA 2004: Companion to the 19th annual ACM SIGPLAN conference on Object-oriented programming systems, languages, and applications, pp. 196–197. ACM Press, New York (2004)
Kiczales, G., Mezini, M.: Aspect-oriented programming and modular reasoning. In: ICSE 2005: Proceedings of the 27th International Conference on Software Engineering, pp. 49–58. ACM Press, New York (2005)
Lieberherr, K.J., Palm, J., Sundaram, R.: Expressiveness and complexity of crosscut languages. In: Proceedings of the 4th workshop on Foundations of Aspect-Oriented Languages (FOAL 2005) (2005)
Gamma, E., Helm, R., Johnson, R., Vlissides, J.: Design Patterns: Elements of Reusable Object-Oriented Software. Addison-Wesley, Reading (1995)
Aldrich, J.: Open Modules:modular reasoning about advice. In: European Conference on Object-Oriented Programming (2005)
Sulivan, K., Griswold, W.G., Song, Y., Cai, Y., Shonle, M., Tewan, N., Rajan, H.: On the criteria to be used in decomposing systems into aspects. In: European Software Engineering Conference and International Symposium on the Foundations of Software Engineering (2005)
Sullivan, K., Griswold, W.G., Song, Y., Shonle, M., Tewari, N., Cai, Y., Rajan, H.: Modular software design and crosscutting interfaces. IEEE Software, Special Issue on Aspect Oriented Programming (2006)
Kiczales, G., Mezini, M.: Separation of concerns with procedures, annotations, advice and pointcuts. In: European Conference on Object-Oriented Programming (2005)
Kellens, A., Mens, K., Brichau, J., Gybels, K.: Managing the evolutions of aspect-oriented software with model-based pointcuts. In: European Conference on Object Oriented Programming (2006)
Koppen, C., Störzer, M.: PCDiff: Attacking the fragile pointcut problem. In: European Interactive Workshop on Aspects in Software (EIWAS) (2004)
Störzer, M., Graf, J.: Using pointcut delta analysis to support evolution of aspect-oriented software. In: 21st IEEE International Conference on Software Maintenance (2005)
Mens, K., Kellens, A., Pluquet, F., Wuyts, R.: co-evolving code and design with intensional views - a case study. Computer Languages, Systems and Structures (2006)
The Demeter Group: The DAJ beta website (2005), http://www.ccs.neu.edu/home/skotthe/daj
Author information
Authors and Affiliations
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2006 Springer-Verlag Berlin Heidelberg
About this paper
Cite this paper
Skotiniotis, T., Palm, J., Lieberherr, K. (2006). Demeter Interfaces: Adaptive Programming Without Surprises. In: Thomas, D. (eds) ECOOP 2006 – Object-Oriented Programming. ECOOP 2006. Lecture Notes in Computer Science, vol 4067. Springer, Berlin, Heidelberg. https://doi.org/10.1007/11785477_27
Download citation
DOI: https://doi.org/10.1007/11785477_27
Publisher Name: Springer, Berlin, Heidelberg
Print ISBN: 978-3-540-35726-1
Online ISBN: 978-3-540-35727-8
eBook Packages: Computer ScienceComputer Science (R0)