A Meta-Level Specification and Profile for AspectJ in UML Joerg Evermann School of Information Management Victoria University of Wellington.

Slides:



Advertisements
Similar presentations
Profiles Construction Eclipse ECESIS Project Construction of Complex UML Profiles UPM ETSI Telecomunicación Ciudad Universitaria s/n Madrid 28040,
Advertisements

Modeling Services Model Interoperability Xavier Blanc – University Paris VI.
OO Programming in Java Objectives for today: Overriding the toString() method Polymorphism & Dynamic Binding Interfaces Packages and Class Path.
1 CIS224 Software Projects: Software Engineering and Research Methods Lecture 11 Brief introduction to the UML Specification (Based on UML Superstructure.
Aspect Oriented Programming. AOP Contents 1 Overview 2 Terminology 3 The Problem 4 The Solution 4 Join point models 5 Implementation 6 Terminology Review.
ASTA Aspect Software Testing Assistant Juha Gustafsson, Juha Taina, Jukka Viljamaa University of Helsinki.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 32 Slide 1 Aspect-oriented Software Development.
Secure Systems Research Group - FAU Aspect Oriented Programming Carlos Oviedo Secure Systems Research Group.
University of British Columbia Software Practices Lab Fluid AOP Join Point Models Terry Hon Gregor Kiczales.
Institute For Software Integrated Systems Vanderbilt University Applications of Model Integrated Computing to The Synchronous Language Signal Ethan Jackson.
UML CASE Tool. ABSTRACT Domain analysis enables identifying families of applications and capturing their terminology in order to assist and guide system.
More on AspectJ. aspect MoveTracking { private static boolean _flag = false; public static boolean testAndClear() { boolean result = _flag; _flag = false;
Whole Platform Tesi di Dottorato di: RICCARDO SOLMI Università degli Studi di Bologna Facoltà di scienze matematiche, fisiche e naturali Corso di Dottorato.
Deriving AO Software Architectures using the AO-ADL Tool Suite Luis Fernández, Lidia Fuentes, Mónica Pinto, Juan A. Valenzuela Universidad de Málaga
A Survey of Software Refactoring Tom Mens, Tom Tourwé
Outline Introduction Problem Statement Object-Oriented Design Aspect-Oriented Design Conclusion Demo.
Faculty of Informatics and Information Technologies Slovak University of Technology Peter Kajsa and Ľubomír Majtás Design.
Towards Executable Aspect-Oriented UML Models 10th Int. Workshop on Aspect-Oriented Modeling (AOM), 6th Int. Conf. on Aspect-Oriented Software Development.
Mathematical Modeling and Formal Specification Languages CIS 376 Bruce R. Maxim UM-Dearborn.
MDE Model Driven Engineering Xavier Blanc Université Pierre et Marie Curie
Introduction to MDA (Model Driven Architecture) CYT.
Assessing the Suitability of UML for Modeling Software Architectures Nenad Medvidovic Computer Science Department University of Southern California Los.
Aspect Oriented Programming Scott Nykl CSSE 411 Senior Seminar.
What is “model transformation”? Distinction between source and target Source may be same as target May be multiple sources, or targets Reaching a fixed.
1 Metamodel Access Protocols for Extensible Aspect-Oriented Modeling Naoyasu Ubayashi(Kyushu Institute of Technology, Japan) Shinji Sano(Kyushu Institute.
What is MOF? The Meta Object Facility (MOF) specification provides a set of CORBA interfaces that can be used to define and manipulate a set of interoperable.
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 32 Slide 1 Aspect-oriented Software Development 1.
Aspect Oriented Programming Sumathie Sundaresan CS590 :: Summer 2007 June 30, 2007.
SaveUML System design. System overview Possible...
Design Rules for Increasing Modularity with CaesarJ Carlos Eduardo Pontual Advisor: Paulo Borba 17/06/2010.
AOSD1 Aspect-Oriented Software Design Karl Lieberherr Theo Skotiniotis.
AOP-1 Aspect Oriented Programming. AOP-2 Aspects of AOP and Related Tools Limitation of OO Separation of Concerns Aspect Oriented programming AspectJ.
AspectWrapper CHALFOUN Pierre et BUIST Éric. Overview Introduction – what and why In a nutshell – main components Our approach – how we did it Demo –
High Integrity Ada in a UML and C world Peter Amey, Neil White Presented by Liping Cai.
1 An Aspect-Oriented Implementation Method Sérgio Soares CIn – UFPE Orientador: Paulo Borba.
XAFIT provides a runtime environment for AF-RDL scripts Instantiation process inputs AF-RDL scripts Framework model in AF-UML Application developer inputs.
Sheet 1 DocEng’03, Grenoble, November 2003 Model Driven Architecture based XML Processing Ivan Kurtev, Klaas van den Berg University of Twente, the Netherlands.
Features of AOP languages AOP languages have the following main elements: –a join point model (JPM) wrt base PL –a specification language for expressing.
IDENTIFYING SEMANTIC DIFFERENCES IN ASPECTJ PROGRAMS Martin Görg and Jianjun Zhao Computer Science Department, Shanghai Jiao Tong University.
Adaptive Software Kevin Cella Graduate Seminar 02/04/2005.
© Siemens AG, CT SE 2 C O R P O R A T E T E C H N O L O G Y 1 Model-Driven Development for Pluggable Collaborations Iris Groher, Stephan Bleicher, Christa.
Laboratory of Model Driven Engineering for Embedded Systems An Execution Framework for MARTE-based Models UML&AADL’2008 workshop Belfast, Northern Ireland.
Inter-Type Declarations in AspectJ Awais Rashid Steffen Zschaler © Awais Rashid, Steffen Zschaler 2009.
AspectJ – AOP for Java Tom Janofsky. Instructor at Penn State Abington Consultant with Chariot Solutions JUG Member.
CS212: Object Oriented Analysis and Design
1 Contract-based Verification for Aspect-oriented Refactoring Naoyasu Ubayashi(Kyushu Institute of Technology) Jinji Piao(Kyushu Institute of Technology)
Demeter Aspects We study techniques for the emerging area of Aspect-Oriented Software Development and focus on the following areas:  Aspectual Collaborations.
Chapter 8: Aspect Oriented Programming Omar Meqdadi SE 3860 Lecture 8 Department of Computer Science and Software Engineering University of Wisconsin-Platteville.
CIM LAB MEETING Presentation on UML Rakesh Mopidevi Kwangyeol Ryu.
® A Proposed UML Profile For EXPRESS David Price Seattle ISO STEP Meeting October 2004.
Separation Of Concerns: Mixins + Variability Models + Aspects in Umple CSER – June 2013 – Montreal Timothy C. Lethbridge, University of Ottawa
问题 Code scattering Blocks of duplicated code Blocks of complementary code, and different modules implementing complementary parts of the concern Code.
Comparison of Different AOP Approaches Presented by: Xiaojing Wang.
XASTRO-2 Presentation CCSDS SAWG th November 2004.
Introduction to Yan Cui Aspect Oriented Programming by
Rigorous Testing by Merging Structural and Behavioral UML Representations Presented by Chin-Yi Tsai.
Class Diagrams. Terms and Concepts A class diagram is a diagram that shows a set of classes, interfaces, and collaborations and their relationships.
Ontologies Reasoning Components Agents Simulations An Overview of Model-Driven Engineering and Architecture Jacques Robin.
Implementing Distribution and Persistence Aspects with AspectJ WAS CLASS.
A UML-Based Pattern Specification Technique Presented by Chin-Yi Tsai IEEE TRANSACTION ON SOFTWARE ENGINEERING, VOL. 30, NO. 3, MARCH 2004 Robert B. France,
 Is a programming paradigm  Extends OOP  Enables modularization of cross cutting concerns.
Aspect-oriented Code Generation Approaches Abid Mehmood & Dayang N. A. Jawawi Department of Software Engineering Faculty of Computer Science and Information.
Features of AOP languages AOP languages have the following main elements: –a join point model (JPM) wrt base PL –a specification language for expressing.
Software Engineering Lecture 7
Aspect-Oriented Programming with the Eclipse AspectJ plug-in
Towards Effective Adaptive User Interfaces Design
Discussion with Gregor Kiczales at UBC
Demeter Aspects Who We Are Aspectual Collaborations
Java Programming Language
Presentation transcript:

A Meta-Level Specification and Profile for AspectJ in UML Joerg Evermann School of Information Management Victoria University of Wellington

Yet Another AspectJ Profile? Previous work based on UML 1.x –UML 2.x extensions very different –Integrated meta-level extensions –Meta-models are profiles Full coverage of AspectJ Full code generation capabilities No textual specification or special code words –Rigorous meta-level based modeling –Supported by all MOF compliant tools

Meta-Level Specification CrossCuttingConcern –Not in AspectJ –But important for modularization –Extend Package meta- class –Related to Aspect through the meta-model level Aspect –Static features Pointcuts –Dynamic features Advice –Generalizable –Similar to meta-model element Class Extension Relationships

Aspects isPrivileged declareParents –Specifies meta-level Generalizations declareImplements –Specifies meta-level InterfaceRealizations Precedence –Total ordering Instantiation –PointCut

Advice Advices are dynamic –BehavioralFeature –Expressible as state charts, collaborations, or opaque behaviour, i.e. methods Related to Aspect via meta-model Signatures by virtue of Operation –Subclass of BehaviouralFeature –Requires behavior specification by method –Determines when advice is applied (after throwing or after returning value)

Static Crosscutting Features Owned by / modelled with the aspect –For better separation of concerns and encapsulation –Requires specification of type for introduced features Alternative possible –“Cleaner” meta-model –But less rigorous separation

PointCuts Explicit composition –UML has no built-in regular expressions Refer explicitly to specific model elements they cut

OCL Constraints Advice stereotype only on behavioral features of classes that are stereotyped Aspect context Advice inv: allInstances.featuredClassifier.oclIsKindOf(Asp ect) StaticCrossCuttingFeature stereotype only for features of classes that are stereotyped Aspect context StaticCrossCuttingFeature inv: allInstances.featuredClassifier.oclIsKindOf(Asp ect) PointCut stereotype only for behavioural features of classes that are stereotyped Aspect context PointCut inv: allInstances.featuredClassifier.oclIsKindOf(Asp ect)

OCL Constraints (2) Aspects are either instantiated perPointCut or perType context Aspect inv: perType->size() > 0 or perPointCut->size() > 0 Aspect stereotype only on classes packaged in packages that are stereotyped as CrossCuttingConcern context Aspect inv: package.oclIsKindOf(CrossCuttingConcern)

Code Generation AspectJ from XMI XSLT –approx 600 lines of code, 9 templates Proof of concept –Lacking sufficient error handling No support for templated and stereotyped classes (i.e. Java Generics and Annotiations) yet. Modeller must ensure advice signature matches context exposed in PointCuts –Not all boolean combinations allowed in AspectJ

Code Generation (2) Advice signature (return parameter or raised exception) determines after … returning or after … throwing advice context Advice inv: if (adviceExecution = AfterAdvice) then ownedParameter(p | p.direction=return)->size() > 0 or raisedException->size() > 0 Different interpretation of return parameter in advice signature –Ignored for before-Advice –Type of returned value for around-Advice –PointCut context for after-Advice

Discussion Rigorous Meta-model specification Lightweight extensions –Cross-tool support (in theory) Lack of pattern based textual specification –Requires awareness of base model –Safer –Easier model verification –No tool support required

Where to from here? Two main directions –Breadth: Other AOP languages –Depth: Generic Aspect Profile –Model Transformations for MDA Other improvements –Code generation for templated and stereotyped elements (i.e. Java 5 generics and annotations) –Validity constraints with OCL –Usability and practical application studies

Thank You