140 likes | 272 Views
Weaving Crosscutting Concerns into Live Sequence Charts Using the Play Engine. Mark Mahoney Tzilla Elrad. Scenario Based Behavior. People think in terms of scenarios, not states.
E N D
Weaving Crosscutting Concerns into Live Sequence Charts Using the Play Engine Mark Mahoney Tzilla Elrad
Scenario Based Behavior • People think in terms of scenarios, not states. • Ivar Jacobson’s recent work on AOSD and use cases lead us to believe that use cases (scenarios) can drive the development of a system with crosscutting concerns. • Live Sequence Charts are used to model scenarios of behavior. • They are inter-object models. • They can be used to synthesize intra-object models.
UML Sequence diagrams • Allow weak partial ordering of events. • Very little can be said about what the system actually does: • Which behaviors are mandatory, which behaviors are optional? • How does the system behave when false conditions are encountered? • How does one specify scenarios that must never occur?
Live Sequence Charts (LSC) • LSC’s specify ‘liveness’ or things that must occur. • LSC’s have constructs for • Mandatory behavior (hot elements) • Optional behavior (cold elements) • Anti-scenarios (scenarios that should never happen) • Sub-charts • Iteration • Selection
Live Sequence Charts (LSC) • LSC’s are ‘played in’ using a look alike GUI front end and a tool called the Play-Engine. • LSC’s are ‘played out’ using the GUI and the Play-Engine. • The Play-Engine monitors system events looking for satisfied pre-charts. • The Play-Engine will identify inconsistencies in system requirements.
LSC’s and Aspect-Orientation • This early work addresses key Aspect-Oriented tenets as they relate to LSC’s: • Pointcut (Pre-chart)- collects the join points where advice should be applied. • Advice (Main Chart)- some action to occur at the join points in a pointcut. • Obliviousness- A single LSC is naturally oblivious to all other LSC’s. • Quantification- Specifying more than one point in a point cut (Pre-chart). There are limitations in the current language.
LSC Extensions to Handle Quantification • Proposed Extension to LSC’s • Regular Expressions in the names of objects/classes. • Regular Expressions in the names of methods. • Some similarity between parameterized templates with the exception that LSC’s force action/reaction behavior. Once a join point is encountered the advice must be applied or it is considered a violation of the requirements. • There is not a similar mandatory behavior requirement with templated UML sequence diagrams.
Future Work • Things to be worked out: • Before, after, around semantics. • Core LSC’s vs. Aspect LSC’s. • State machine model synthesis with before, after, and around. • Executing environments.
References • Damm, W., Harel, D. LSCs: Breathing Life into Message Sequence Charts, Formal Methods in System Design 19:1 (2001), 45-80. • Harel, D., Marelly, R. Specifying and Executing Behavioral Requirements: The Play In/Play-Out Approach Software and System Modeling (SoSyM) 2 (2003), pp. 82-107. • Harel, D. Marelly, R. Come, Let’s Play. Scenario-Based Programming Using LSCs and the Play-Engine. Springer. (2003). • Jacobson, I. Ng, P. Aspect-Oriented Software Development with Use Cases. Addison-Wesley. (2005).