ABSTRACT
Aspect-oriented programming (AOP) is a popular technique for modularizing crosscutting concerns. However, constructs aimed at supporting crosscutting modularity may break class modularity. For example, to understand a method call may require a whole-program analysis to determine what advice applies and what that advice does. Moreover, in AspectJ, advice is coupled to the parts of the program advised, the base code, so the meaning of advice may change when the base code changes. Such coupling also hinders parallel development between base code and aspects. We propose some simple modifications to the design of crosscut programming interfaces (XPIs) to include expressive design rule specifications. We call our form of XPIs crosscutting programming interfaces with design rules (XPIDRs). The XPIDR-based approach, by design, supports modular runtime checking and parallel development by decoupling aspects from base code. We also show how XPIDRs allow specification of interesting control flow effects, such as when advice does (or does not) proceed. We have implemented XPIDRs as a simple contract extension to AspectJ. Since XPIDRs do not require any new AspectJ constructs, they can be adopted easily by the AspectJ community.
- S. Apel, C. Kästner, T. Leich, and G. Saake. Aspect refinement -- unifying aop and stepwise refinement. Journal of Object Technology, 6(9):13--33, 2007.Google ScholarCross Ref
- M. Bagherzadeh, H. Rajan, G. T. Leavens, and S. Mooney. Translucid contracts: Expressive specification and modular verification for aspect-oriented interfaces. In Proceedings of the tenth international conference on Aspect-oriented software development, AOSD '11, pages 141--152, New York, NY, USA, Mar. 2011. ACM. Google ScholarDigital Library
- P. Greenwood, T. Bartolomei, E. Figueiredo, M. Dosea, A. Garcia, N. Cacho, C. Sant'Anna, S. Soares, P. Borba, U. Kulesza, and A. Rashid. On the impact of aspectual decompositions on design stability: an empirical study. In Proceedings of the 21st European conference on Object-Oriented Programming, ECOOP'07, pages 176--200, Berlin, Heidelberg, 2007. Springer-Verlag. Google ScholarDigital Library
- S. Hanenberg and R. Unland. AspectJ idioms for aspect-oriented software construction. In EuroPlop'03, 2003.Google Scholar
- M. Inostroza, E. Tanter, and E. Bodden. Join point interfaces for modular reasoning in aspect-oriented programs. In ESEC/FSE '11, 2011. Google ScholarDigital Library
- G. Kiczales, J. Lamping, A. Mendhekar, C. Maeda, C. V. Lopes, J.-M. Loingtier, and J. Irwin. Aspect-oriented programming. In ECOOP'97, 1997.Google ScholarCross Ref
- G. Kiczales and M. Mezini. Aspect-oriented programming and modular reasoning. In Proc. of the 27th International Conference on Software Engineering, pages 49--58, 2005. Google ScholarDigital Library
- G. T. Leavens. JML's rich, inherited specifications for behavioral subtypes. In Z. Liu and H. Jifeng, editors, Formal Methods and Software Engineering: 8th International Conference on Formal Engineering Methods (ICFEM), volume 4260 of Lecture Notes in Computer Science, pages 2-34, New York, NY, Nov. 2006. Springer-Verlag. Google ScholarDigital Library
- G. T. Leavens, A. L. Baker, and C. Ruby. Preliminary design of JML: A behavioral interface specification language for Java. ACMSIGSOFT Software Engineering Notes, 2006. Google ScholarDigital Library
- A. C. Neto, A. Marques, R. Gheyi, P. Borba, and F. Castor. A design rule language for aspect-oriented programming. In SBLP '09: Proceedings of the 2009 Brazilian Symposium on Programming Languages, pages 131--144. Brazilian Computer Society, 2009.Google Scholar
- H. Rebelo, R. Coelho, R. Lima, G. T. Leavens, M. Huisman, A. Mota, and F. Castor. On the Interplay of Exception Handling and Design by Contract: An Aspect-Oriented Recovery Approach. In Proceedings of the 13th Workshop on Formal Techniues for Java-Like Programs, FTfJP '11, pages 7:1--7:6, New York, NY, USA, 2011. ACM. Google ScholarDigital Library
- H. Rebelo, S. Soares, R. Lima, L. Ferreira, and M. Cornelio. Implementing Java modeling language contracts with AspectJ. In Proceedings of the 2008 ACM symposium on Applied computing, SAC '08, pages 228--233, New York, NY, USA, 2008. ACM. Google ScholarDigital Library
- H. Reblo, R. M. F. Lima, A. Mota, C. A. L. Oliveira, and M. Ribeiro. Enforcing contracts for aspect-oriented programs with annotations, pointcuts and advice. In SEKE'12, 2012.Google Scholar
- S. Soares, E. Laureano, and P. Borba. Implementing distribution and persistence aspects with AspectJ. In OOPSLA '02, 2002. Google ScholarDigital Library
- F. Steimann. The paradoxical success of aspect-oriented programming. In OOPSLA 2006: Proceedings of the 21st International Conference on Object-oriented Programming Systems, Languages, and Applications, ACM SIGPLAN Notices, pages 481--497, New York, NY, Oct. 2006. ACM. Google ScholarDigital Library
- F. Steimann, T. Pawlitzki, S. Apel, and C. Kästner. Types and modularity for implicit invocation with implicit announcement. ACM Trans. Softw. Eng. Methodol., 20(1):1:1--1:43, July 2010. Google ScholarDigital Library
- M. Stoerzer and J. Graf. Using pointcut delta analysis to support evolution of aspect-oriented software. In ICSM '05, pages 653--656, 2005. Google ScholarDigital Library
- K. Sullivan, W. G. Griswold, H. Rajan, Y. Song, Y. Cai, M. Shonle, and N. Tewari. Modular aspect-oriented design with xpis. ACM Transactions on Software Engineering and Methodology, 20(2):5:1--5:42, Sept. 2010. Google ScholarDigital Library
- T. tourwe, J. Brichau, and K. Gybels. On the existence of the AOSDevolution paradox. In L. Bergmans, J. Brichau, P. Tarr, and E. Ernst, editors, SPLAT: Software engineering Properties of Languages for Aspect Technologies, Mar. 2003.Google Scholar
Index Terms
- Modular aspect-oriented design rule enforcement with XPIDRs
Recommendations
Modular aspect-oriented design with XPIs
The emergence of aspect-oriented programming (AOP) languages has provided software designers with new mechanisms and strategies for decomposing programs into modules and composing modules into systems. What we do not yet fully understand is how best to ...
A design rule language for aspect-oriented programming
HighlightsWe present a design rule specification language for aspect-oriented systems.We explore its benefits to supporting the modular development of classes and aspects.We discuss how our language improves crosscutting modularity without breaking ...
Cooperative aspect-oriented programming
Aspect-oriented programming (AOP) seeks to improve software modularity via the separation of cross-cutting concerns. AOP proponents often advocate a development strategy where programmers write the main application (base code), ignoring cross-cutting ...
Comments