Flexible Pointcut Implementation: An Interpreted Approach

Ali Assaf 1, 2 Jacques Noyé 1, 2, *
* Auteur correspondant
2 ASCOLA - Aspect and composition languages
LINA - Laboratoire d'Informatique de Nantes Atlantique, Département informatique - EMN, Inria Rennes – Bretagne Atlantique
Abstract : One of the main elements of an Aspect-Oriented Programming (AOP) language or framework is its pointcut language. A pointcut is a predicate which selects program execution points and determines at which points the execution should be affected by an aspect. Experimenting with AspectJ shows that two basic primitive pointcuts, call and execution, dealing with method invoca- tion from the caller and callee standpoints, respectively, lead to confusion. This is due to a subtle interplay between the use of static and dynamic types to select execution points, dynamic lookup, and the expectation to easily select the caller and callee execution points related to the same invocation. As a result, alternative semantics have been proposed but have remained paper design. In this article, we reconsider these various semantics in a practical way by implementing them using CALI, our Common Aspect Language Interpreter. This framework reuses both Java as a base language and AspectJ as a way to select the program execution points of interest. An additional interpretation layer can then be used to prototype interesting AOP variants in a full-blown environment. The paper illustrates the benefits of applying such a setting to the case of the call and execution pointcuts. We show that alternative semantics can be implemented very easily and exercised in the context of AspectJ without resorting to complex compiler technology.
Type de document :
Communication dans un congrès
Bernard Carré. Langages et Modèles à Objets (LMO 2009), Mar 2009, Nancy, France. Cépaduès-Editions, pp.45-60, 2009
Liste complète des métadonnées

https://hal.inria.fr/inria-00460796
Contributeur : Noyé Jacques <>
Soumis le : mardi 2 mars 2010 - 14:52:01
Dernière modification le : vendredi 22 juin 2018 - 09:29:18

Identifiants

  • HAL Id : inria-00460796, version 1

Citation

Ali Assaf, Jacques Noyé. Flexible Pointcut Implementation: An Interpreted Approach. Bernard Carré. Langages et Modèles à Objets (LMO 2009), Mar 2009, Nancy, France. Cépaduès-Editions, pp.45-60, 2009. 〈inria-00460796〉

Partager

Métriques

Consultations de la notice

636