BOM2UML: Integrating BOM Specifications into UML-based Development Environments

980 views

Published on

Presentation at the 2nd International Workshop on Model-driven Approaches for Simulation Engineering

(held within the SCS/IEEE Symposium on Theory of Modeling and Simulation part of SpringSim 2012)

Please see: http://www.sel.uniroma2.it/mod4sim12/ for further details

Published in: Technology, Education
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
980
On SlideShare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
5
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

BOM2UML: Integrating BOM Specifications into UML-based Development Environments

  1. 1. BOM2UML Integrating BOM Specifications intoUML-based Development Environments Andrea D’Ambrogio1, Daniele Gianni2 and Marco Grasso1 1dambro@uniroma2.it Dept. of Enterprise Engineering University of Roma “Tor Vergata” Roma (Italy) 2daniele.gianni@esa.int European Space Agency Noordwijk, The Netherlands 2nd Workshop on Model-driven Approaches for Simulation Engineering (Mod4Sim), in Symposium on Theory of Modeling and Simulation (TMS), SpringSim 2012
  2. 2. Presentation Overview Background • IEEE High Level Architecture (HLA) and Basic Object Model (BOM) • Atlas Transformation Language (ATL) BOM2UML: • High Level Mapping • Model Transformations Example application
  3. 3. IEEE High Level Architecture Prominent standard for distributed simulation Originally designed to increase simulator reusability and interoperability The standard consists of four documents: • Set of compliance rules • Interfaces for distributed simulation services • An Object Model Template (OMT) for data interchange • A development process The standard addresses software reusability at the coarse level of individual simulators This is obtained through specification of OMT data
  4. 4. Basic Object Model (BOM) BOMs document individual (fine grain) simulation components using an abstract notation • http://www.boms.info BOMs can be coded in tabular and XML (DIF) forms BOMs can be mapped onto HLA OMT for full compliance with the standard BOMs can be grouped in: • Model Identification • Conceptual Model Definition • Model Mapping • Object Model Definition • Notes and Lexicons
  5. 5. Atlas Transformation Language (ATL) A model transformation language and toolkit • http://www.eclipse.org/atl Used in the MDE (model-driven engineering) field to produce a set of target models from a set of source models An ATL model-to-model transformation is composed of rules that define how source model elements are matched and navigated to create and initialize the elements of the target models
  6. 6. Operational context of ATL MOFMMa is the MMB is thesource targetmetamodel MMa ATL MMb metamodel MMa2MMb.atl Ma Mb Ma is the source model Mb is the target model
  7. 7. ATL overview Source models and target models are distinct: • Source models are read-only (they can only be navigated, not modified) • Target models are write-only (they cannot be navigated) The language is a declarative-imperative hybrid: • Declarative part:  Matched rules with automatic traceability support  Side-effect free navigation (and query) language: OCL 2.0 • Imperative part:  Called rules  Action blocks. Recommended programming style: declarative
  8. 8. BOM2UML: What is it? BOM2UML is a first attempt to automatically derive UML representations for BOM specs BOM2UML consists of: • a high-level model mapping between BOM concepts and UML concepts • a set of ATL transformations to convert BOM specifications (coded in XML-based DIF) into UML diagrams (coded in XMI)
  9. 9. BOM2UML: Why is it needed? BOM specs cannot be immediately integrated in UML-based model-driven environments UML representations contribute to solve interoperability issues when integrating simulation components UML is part of the OMG MDA standard UML eliminates the investment to retrofit existing tools for BOM-based development
  10. 10. High Level Mapping BOM Template Concept UML Domain Model Meta-data Class Diagram Identification Interaction Overview DynamicPattern of Interplay Diagram and associated Behavior Sequence Diagrams State Machine FSM State Diagram Entity Type Data Class Event Type Data Class
  11. 11. High Level Mapping BOM Template Concept UML Domain Platform Independent Model to Platform Model Mapping Transformation Specification Transformation Object Definition Object Model UML-HLA Profile* XML Query on UML Lexicon** List Model** Note** Meta-attribute Note***Available in literature**Work-in-progress
  12. 12. Model Transformations State machine  UML State Diagram • BOM State  UML State • BOM Transition  UML State transition  BOM Trigger != UML Trigger Pattern of Interplay  Interaction Overview Diagram • BOM Action  UML Activity • BOM Variation  UML Decision node plus UML Activity • Each UML Activity is expanded into a Sequence Diagram to represent the interaction triggering the BOM Event
  13. 13. Example Application scenario consisting of: • Cannon firing cannon shots • Soldier throwing hand bombs • Set of targets to be destroyed All the BOMs were developed, but we illustrate only the Event Types, Cannon State Machine, and Firing Pattern of Interplay
  14. 14. Part of the defined Event Types Source Target Event Trigger Charact- Charact Content Notes Type Condition Name NameCannon- FiringCom- Cannon Target ShotId NA shot mand==true Bullet Target Cannon NA NA NAExplosion
  15. 15. ‘Firing’ State Machine for the Cannon State State Concep- State Name Exit Condition NotMachine tual Entity Action Next es Name State FireCom- Ready Fire Na mand Bullet Fire Cannon Fires Travel- Na Firing Cannon ling Bullet Na Bullet Explodes Ready Travelling Bullet Faulty Na
  16. 16. State Diagram for the ‘Firing’ State Machine The BOM State Firing Machine becomes theThe triggering conditions UML State Diagramassociated to each BOM Event become the transitions triggers Each BOM state becomes a UML State Ready BulletTravelling Fire Guards and Entry Action remain undefined
  17. 17. ‘Firing’ Pattern of Interplay (PoI) (part 1) Recei- CondiPoI Seq Name Sender Event ver -tion Pattern Fire 1 Cannon Target Fire Na Action Cannon Throw Variation Handbo Soldier Target Launch NaFiring mb Pattern Explode 2 Cannon Target Explosion Na Action Bullet Explode Variation Hand- Soldier Target Explosion Na bomb
  18. 18. ‘Firing’ Pattern of Interplay (PoI) (part 2) Recei- Condi-PoI Seq Name Sender Event ver tion Bullet- Dischar- Faulty Exception Cannon NA Exploded ge Bullet Bullet ==falseFiring Dischar- Hand- Faulty ge Bomb Exception Soldier NA Hand- Handbo Exploded bomb mb ==false
  19. 19. Interaction Overview Diagram ref Discharge Bullet [Faulty Bullet] ref ref Fire Cannon Explode Bullet ref ref Throw Explode Handbomb Handbomb [Faulty Handbomb] ref Discharge Handbomb
  20. 20. Interaction Overview Diagram ref Discharge Bullet [Faulty Bullet] ref ref Fire Cannon Explode Bullet ref ref Throw Explode Handbomb Handbomb [Faulty Handbomb] The BOM Pattern of ref DischargeInterplay becomes an Handbomb Interaction Overview Diagram
  21. 21. Interaction Overview Diagram ref Discharge Bullet [Faulty Bullet] ref ref Fire Cannon Explode Bullet ref ref Throw Explode Handbomb Handbomb [Faulty Handbomb] ref Discharge Each Variation Handbomb becomes an “alternative” Action
  22. 22. Interaction Overview Diagram ref Discharge Bullet [Faulty Bullet] ref ref Fire Cannon Explode Bullet Each Action becomes and Activity ref ref Throw Explode Handbomb Handbomb [Faulty Handbomb] ref Discharge Handbomb
  23. 23. Interaction Overview Diagram Each Action is exploded and ref represented as a Discharge Bullet Sequence Diagram [Faulty Bullet] ref ref Fire Cannon Explode Bullet ref ref Throw Explode Handbomb Handbomb [Faulty Handbomb] ref Discharge Handbomb
  24. 24. Interaction Overview Diagram UML Class representing the BOM Event [Faul Cannon Target ref[firingCommand==true] cannonshot Fire Cannon ref Throw Handbomb [Faulty
  25. 25. Conclusions BOM specs document HLA simulation components using XML-based formats and thus cannot be exploited within model-driven approaches for HLA We have introduced BOM2UML to integrate BOMs into existing model-driven simulation engineering approaches BOM2UML consists in: • a high level mapping between BOM and UML concepts • a set of ATL transformations to derive UML diagrams Work is in progress to define both a UML profile for BOM to further enhance model verification
  26. 26. Backup slides
  27. 27. ATL rules A declarative rule specifies: • the source pattern to be matched in the source models • the target pattern to be created in the target models for each match during rule application An imperative rule is basically a procedure: • It is called by its name • It may take arguments • It can contain:  A declarative target pattern  An action block (i.e. a sequence of statements)  Both.
  28. 28. Declarative rules: source pattern The source pattern is composed of: • A labeled set of types coming from the source metamodels • A guard (Boolean expression) used to filter matches A match corresponds to a set of elements coming from the source models that: • Are of the types specified in the source pattern (one element for each type) • Satisfy the guard
  29. 29. Declarative rules: target pattern The target pattern is composed of: • A labeled set of types coming from the target metamodels • For each element of this set, a set of bindings • A binding specifies the initialization of a property of a target element using an expression For each match, the target pattern is applied: • Elements are created in the target models (one for each type of the target pattern) • Target elements are initialized by executing the bindings:  First evaluating their value  Then assigning this value to the corresponding property
  30. 30. Example ATL rulerule UMLInteractionOverview{from patternOfInterplay:BOMs!PatternOfInterplayto initialNode:UML!InitialNode(name<‐patternOf- Interplay.Name+InitialNode), finalNode:UML!ActivityFinalNode( name<‐patternOfInterplay.Name+FinalNode)do {‐‐defining a Decision Node for each Pattern Action for(pattern in atternOfInterplay.Pattern2PatternAct){‐‐setting the decision index with the action index thisModule.indexDecision<‐patternOfInterplay.Pattern- 2PatternAct.indexOf(pattern);‐‐instantiating a Decision Node per each Pattern Action thisModule.UMLDecisionNode(); thisModule.entityNameType<‐PatternAction; … }

×