offers language constructs to handle contexts. A con-
text is defined by the programmer as a plain standard
object. The pointcut language is extended with primi-
tives such as inContext(c) and createdInContext(c) that
restrict a pointcut expression to a particular context c
and to objects that were created in a context c, respec-
tively.
Whereas context-aware aspects trigger the acti-
vation of aspects based on some arbitrary context
activation function, aspectboxes promote the con-
current applications of aspects by restricting them to
different scope.
Context-oriented programming. Con-
textL (Costanza and Hirschfeld, 2005), a CLOS-
based implementation for Context-Oriented Program-
ming, provides dedicated programming language
constructs to associate partial class and method
definitions with layers. Layers activation and deac-
tivation is driven by the control flow of a running
program. When a layer is activated, the partial
definitions become part of the program until this
layer is deactivated.
Whereas scoping software system refinement is the
common problem for context-oriented programming
and aspectboxes, the approaches are different. A
layer in ContextL encapsulate structural definitions,
whereas aspectboxes encapsulate behavioral defini-
tions.
AWED. Aspects with Explicit Distribution
(AWED) (Navarro et al., 2006) is an approach
for defining crosscutting behaviour on remote loca-
tions (i.e., distributed applications). AWED is an
aspect language supporting remote pointcuts, dis-
tributed advices and distributed aspects. A distributed
aspect allows for state sharing and aspect instance to
be distributed across multiple hosts.
7 CONCLUSION
Aspectboxes provide a new aspect modularity con-
struct limiting the scope of aspect composition with a
base software system. Modifications to the base sys-
tem are visible only in the aspectbox the aspect is de-
fined in. This allows one to deploy multiple concur-
rent modifications in the same base system, avoiding
conflicting situations across aspectboxes.
In the work presented in this paper, an aspect can-
not be imported from an aspectbox. The reason for
this is that aspects are not generic (i.e., cannot be ap-
plied to other base systems). As future work, we plan
to refine the notion of import to enable reuse of as-
pects within multiple aspectboxes.
Our prototypical implementation is based on As-
pectS. It integrates the composition mechanisms of
AspectS and Classboxes to achieve the desired com-
position and scoping behavior.
ACKNOWLEDGEMENTS
We gratefully acknowledge the financial support of
the Science Foundation Ireland and Lero — the Irish
Software Engineering Research Centre. We also like
to thank Parinaz Davari and Daniel Rostrup for their
valuable comments.
REFERENCES
Aracic, I., Gasiunas, V., Mezini, M., and Ostermann, K.
(2006). An overview of caesarj. Transactions on
Aspect-Oriented Software Development, 3880:135 –
173.
Baille, G., Garnier, P., Mathieu, H., and Pissard-Gibollet,
R. (1999). Le cycab de l’inria rh
ˆ
one-alpes. Technical
Report RT-0229, INRIA.
Bergel, A., Ducasse, S., and Nierstrasz, O. (2005). Class-
box/J: Controlling the scope of change in Java. In Pro-
ceedings of Object-Oriented Programming, Systems,
Languages, and Applications (OOPSLA’05), pages
177–189, New York, NY, USA. ACM Press.
Brant, J., Foote, B., Johnson, R., and Roberts, D. (1998).
Wrappers to the Rescue. In Proceedings ECOOP
’98, volume 1445 of LNCS, pages 396–417. Springer-
Verlag. method wrappers.
Brichau, J., Mens, K., and Volder, K. D. (2002). Build-
ing composable aspect-specific languages with logic
metaprogramming. In Proceedings of the 1st
ACM SIGPLAN/SIGSOFT Conference on Generative
Programming and Component Engineering (GPCE
2002), volume 2487 of LNCS. Springer-Verlag.
Costanza, P. and Hirschfeld, R. (2005). Language con-
structs for context-oriented programming. In Proceed-
ings of the Dynamic Languages Symposium 2005.
Douence, R., Fradet, P., and S
¨
udholt, M. (2004). Composi-
tion, reuse and interaction analysis of stateful aspects.
In AOSD ’04: Proceedings of the 3rd international
conference on Aspect-oriented software development,
pages 141–150, New York, NY, USA. ACM Press.
Hirschfeld, R. (2003). AspectS – Aspect-Oriented Pro-
gramming with Squeak. In Aksit, M., Mezini, M.,
and Unland, R., editors, Objects, Components, Ar-
chitectures, Services, and Applications for a Net-
worked World, number 2591 in LNCS, pages 216–
232. Springer.
Ingalls, D., Kaehler, T., Maloney, J., Wallace, S., and Kay,
A. (1997). Back to the future: The story of Squeak, A
practical Smalltalk written in itself. In Proceedings
OOPSLA ’97, ACM SIGPLAN Notices, pages 318–
326. ACM Press.
ICSOFT 2006 - INTERNATIONAL CONFERENCE ON SOFTWARE AND DATA TECHNOLOGIES
34