1 / 23

Scenario-based Analysis of UML Design Class Models

Scenario-based Analysis of UML Design Class Models. Lijun Yu October 4th, 2010 Oslo, Norway. My background. Bachelor in Computer Science, Nanjing University, China, 1997 Master in Computer Science, Colorado State University, USA, 2006 After 2006: Ph.D. research in software engineering

montana
Download Presentation

Scenario-based Analysis of UML Design Class Models

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Scenario-based Analysis of UML Design Class Models Lijun Yu October 4th, 2010 Oslo, Norway

  2. My background • Bachelor in Computer Science, Nanjing University, China, 1997 • Master in Computer Science, Colorado State University, USA, 2006 • After 2006: • Ph.D. research in software engineering • Full-time software engineer 2

  3. Outline Problem Statement Solution Overview Evaluation Method Related Work Research Plan 3

  4. Background • The Unified Modeling Language is a de-facto standard OO modeling language • UML class models are often used to describe software designs • Software design is creative process and human beings introduce errors in the design model • Design errors should be uncovered and resolved as early as possible

  5. State-of-the-art in UML class model analysis UML design class model describes Structure in terms of classes and relationships Functionality in terms of operation specifications (OCL) UML static analysis tools USE/OCLE can check whether a snapshot is consistent with structural constraints in UML design class models A snapshot is a UML instance model describing a system state They do not provide good support for analyzing functionality 5

  6. Research questions How to analyze functional scenarios against UML design class models? How can we leverage USE/OCLE to support scenario-based analysis? What type of design errors can be uncovered in scenario-based analysis of UML design class models? How to systematically generate scenarios? 6

  7. Outline Problem Statement Solution Overview A scenario-based analysis approach Scenario generation techniques Evaluation Method Related Work Research Plan 7

  8. Scenario-based Analysis: A lightweight approach Step 1 Step 3 Step 2 8

  9. Step 1: generate snapshot model • Create a structured class Snapshot that contains a part structure representing snapshots of the system • Create a Transition class that links to before and after snapshots • For each operation in the UML design • Create a subclass of Transition • Add operation parameters as attributes • “And” OCL pre and post conditions and transform to invariants of the Transition subclass • Add frame constraints: make sure other objects and relationships remain unchanged 9

  10. Snapshot model: an example 10

  11. Step 2: generate snapshot transitions • 1. Use UMLAnT to generate snapshot transitions • Verifier describes operation definitions using JAL (Java-like Action Language) • Snapshot transitions are generated by executing JAL using UMLAnT • 2. Use Alloy to generate snapshot transitions • To be discussed in scenario generation part 11

  12. Step 3: consistency checking • Snapshot transitions are instance model of the Snapshot model • Consistency is checked using USE/OCLE • Inconsistencies imply errors in either the UML design or the operation definitions 12

  13. Scenario generation • Scenario generation technique automates the creation of scenarios • Option 1: Generate scenarios from formal UML requirements model • Option 2: Generate scenarios from UML design • Compare two options 13

  14. Scenario generation option 1 • Generate scenarios from formal UML requirements model • UML Requirements model • UML activity diagram describing use case sequences • Use case formally described as system operation with parameters and pre/post conditions • All allowed operation sequences are extracted from the UML activity diagram • Alloy is used to solve parameters of scenarios 14

  15. Scenario generation option 2 • Generates scenarios from UML designs using Alloy • Verifier describes operation definitions in terms of OCL constraints • Transform snapshot class model and operation definitions to Alloy • Generate interesting scenarios and their snapshot sequences using Alloy trace 15

  16. Outline Problem Statement Solution Overview Evaluation Method Related Work Research Plan 16

  17. Evaluate scenario-based analysis technique Questions Can the technique find inconsistencies between UML class model and scenarios? What types of inconsistencies can the technique uncover? Method Different types of inconsistencies are seeded into UML design class models and scenario models Two groups of students: one uses scenario-based analysis tool, another does manual inspection Record and compare number of errors and type of errors found 17

  18. Evaluate scenario generation method Question: Can the scenario generation method generate scenarios that uncover design errors? Method: Seed design errors in the UML design class model Generate scenarios using the scenario generation method and a random scenario generator Compare design errors uncovered by the scenario generation method and a random generator 18

  19. Outline Problem Statement Solution Overview Evaluation Method Related Work Research Plan 19

  20. Related Work Transforming UML to formal specification languages Developers need to be familiar with these notations and techniques Correctness of transformation can be difficult to prove Testing & Animating UML designs (UMLAnT) Testing one operation call vs Analyzing scenarios Executing the UML model vs Static analysis 20

  21. Outline Problem Statement Solution Overview Evaluation Method Related Work Research Plan 21

  22. Research Plan

  23. Questions and discussions • ? 23

More Related