Presentation is loading. Please wait.

Presentation is loading. Please wait.

Executable UML The Models are the Code - Executable UML CS387 Paul Krause.

Similar presentations


Presentation on theme: "Executable UML The Models are the Code - Executable UML CS387 Paul Krause."— Presentation transcript:

1 Executable UML The Models are the Code - Executable UML CS387 Paul Krause

2 Executable UML Lecture 1 - Introduction and Motivation v New Terminology v Motivation v What is a model? v Introduction to xUML

3 Executable UML New Terminology for Today v Executable UML (xUML) v Platform Independent Model (PIM) v Platform Specific Model (PSM)

4 Executable UML Motivation - Raising the Level of Abstraction Assembly Code Assembler None Machine Code 1960s High-Level Language Source Code Compiler Hardware Platform Assembly Code 1980s Executable Models Model Compiler Software Platform Source Code 2000s

5 Executable UML Domain Models 2000s Components and Frameworks 1990s Objects 1980s Motivation - Raising the Level of Reuse Functions 1970s

6 Executable UML Motivation - Architectural Mismatch Operating System Data Server CORBA Application Reuse at the Code-Level is Multiplicative e.g. 3 x 3 x 3 = 27 code versions

7 Executable UML The Vision of Model Driven Architecture v To create an application on a new platform: 1. Take a model of the application domain off the shelf 2. Subset the model as necessary 3. Take models of the implementation technologies off the shelf 4. Describe how the models are to be linked 5. Generate the system (After Mellor et al, 2004)

8 Executable UML Lecture 1 - Introduction and Motivation v New Terminology v Motivation v What is a model? v Introduction to xUML

9 Executable UML Abstraction, Classification and Generalisation Classify Real WorldModels Fido (20kg, Awful): Dog Munchkin (8kg, FeedingOnly): Cat LapKitty (4kg, LapLover): Cat Classify Abstract Pet + name + weight Dog +slobberFactor Cat +standoffIndex Abstract Real Entities Entity Classifications Instance Model Class Model

10 Executable UML Subject Matter and Language Abstraction Transaction amount ID type Customer name city isPrimary Account number balance SavingsAccount interestRate ChackingAccount maxChecksperMonth is owned by owns 1* is affected by operates on * 1..2

11 Executable UML How do we know if a Customer is authentic? v The banking model abstracts away irrelevant information  e.g. customer’s salary, number of children, personal hobbies, etc v But the process of authenticating a customer is relevant v So, how come it is not present in the model? v This is because Security is a different (and general purpose) subject domain

12 Executable UML Security Domain Model PrincipalProtectedResourceRoleProtectedActionPermission 0..* affected by system actions action subject to authorisation entity on whose behalf actions are performed defines a relationship between a Principal and the System reflects the actions that a Principal, acting in a particular Role, can take with regard to a ProtectedResource

13 Executable UML Separation of concerns v We could have a number of different ways of handling security in a banking domain v Any given model of security could be applied to a number of different application domains v So, we model the bank without worrying about security v And, model security without worrying about its potential applications v But we do need to hook the two models together

14 Executable UML Lecture 1 - Introduction and Motivation v New Terminology v Motivation v What is a model? v Introduction xUML

15 Executable UML Terminology in xUML v The Model v The Platform v The Platform-Independent Model (PIM) v The Platform-Specific Model (PSM)

16 Executable UML The Model v a “formal representation of the function, behaviour and structure of the system we are building” - [Raistrick et al, 2004] v We will use xUML to specify complete and rigorous models v Two kinds of models:  Platform-independent Model (PIM)  Platfrom-specific model (PSM) v So, what do we mean by a “platform”

17 Executable UML The Platform v the “technological and engineering details that are irrelevant to the fundamental functionality of the software” - [Raistrick et al, 2004] v Examples:  CORBA  J2EE CC .NET  a Real-Time Operating System (RTOS) v Note, we may need to say which Platforms are PIMs are independent of!

18 Executable UML The Platform-Independent Model (PIM) v Captures all the business requirements of the system under construction, free from implementation detail v They must nevertheless be precise and complete  still include all the hard bits! v Several PIMs will be used to specify a system  each PIM captures a distinct aspect of the system  we term these domains  we use xUML so the PIMs can be combined and executed

19 Executable UML The Platform-Specific Models v The PSM is a realisation of a PIM for a specific platform  The PIM is “elaborated” with all the implementation details needed to execute it on a specific platform v The PSM is obtained by mapping the PIM to a specific platform  That is, we apply a set of transformation rules to the PIM to obtain a PSM v MDA has most benefit if the PSM is always generated from the PIM  the PSM is not a maintained deliverable - changes are made to the PIM only, and the PSM regenerated

20 Executable UML Mappings are reusable Command & Control PIMAir Traffic Control PIMAir Traffic Control PSMCommand & Control PSM Shared Common Mapping from PIM to PSM

21 Executable UML Executable UML (xUML) v a clearly defined simple model structure v a precise semantics for actions v a compliant Action Specification Language (ASL) v a process that supports executable modelling, large-scale reuse and pattern-based design xUMLUML Semantically Weak Elements Precisely Defined Action Semantics =-+


Download ppt "Executable UML The Models are the Code - Executable UML CS387 Paul Krause."

Similar presentations


Ads by Google