UML and WSDL for JISC e-Learning Projects INTRODUCTION TO UML Richard Hopkins NeSC Training Team Member

Slides:



Advertisements
Similar presentations
UML and WSDL for JISC e-Learning Projects Major Practical Richard Hopkins NeSC Training Team Member
Advertisements

17 May Multiple Sites. 17 May Multiple Sites This presentation assumes you are already familiar with Doors and all its standard commands It.
© Pearson Education Limited, Chapter 8 Normalization Transparencies.
UML an overview.
CIS224 Software Projects: Software Engineering and Research Methods
A Brief Introduction. Acknowledgements  The material in this tutorial is based in part on: Concurrency: State Models & Java Programming, by Jeff Magee.
Use Case - Example University library system requirements
Object-Oriented Analysis and Design
Introduction To System Analysis and Design
1 Software Testing and Quality Assurance Lecture 12 - The Testing Perspective (Chapter 2, A Practical Guide to Testing Object-Oriented Software)
Systems Analysis and Design in a Changing World, Fourth Edition
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 8 Slide 1 System models.
1 SWE Introduction to Software Engineering Lecture 23 – Architectural Design (Chapter 13)
Kravansvarig för PUM-projekt
Creating Architectural Descriptions. Outline Standardizing architectural descriptions: The IEEE has published, “Recommended Practice for Architectural.
Software Engineering Lecture 9 Object-Oriented Design II.
Itntroduction to UML, page 1 Introduction to UML.
Introductory case study. 2 The problem The most difficult part of any design project is understanding the task you are attempting You have been contacted.
Software Engineering Case Study Slide 1 Introductory case study.
Use Case Diagram : Library System
Chapter 7: The Object-Oriented Approach to Requirements
Basic Concepts The Unified Modeling Language (UML) SYSC System Analysis and Design.
System Analysis Overview Document functional requirements by creating models Two concepts help identify functional requirements in the traditional approach.
Use Cases Why use ‘em? How do they work? UC diagrams Using them later in the software development cycle.
SOFTWARE ENGINEERING BIT-8 APRIL, 16,2008 Introduction to UML.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 System models l Abstract descriptions of systems whose requirements are being.
Chapter 4 System Models A description of the various models that can be used to specify software systems.
System models Abstract descriptions of systems whose requirements are being analysed Abstract descriptions of systems whose requirements are being analysed.
Systems Analysis and Design in a Changing World, 6th Edition
Introduction to UML By: Prof. Aiman Hanna Department of Computer Science, Concordia University, Montreal, Canada.
Presented by: CHAN LAI SAN ( ) REBAH DAW SARREB ( ) FIDA AL-OBAISI ( ) 08 April 2008 (Tuesday 6pm – 7:30pm)
Introduction To System Analysis and Design
Using UML, Patterns, and Java Object-Oriented Software Engineering Chapter 4, Requirements Elicitation.
1 CMPT 275 Software Engineering Requirements Gathering Activity Janice Regan,
Copyright 2002 Prentice-Hall, Inc. Chapter 2 Object-Oriented Analysis and Design Modern Systems Analysis and Design Third Edition Jeffrey A. Hoffer Joey.
Chapter 7 System models.
Sommerville 2004,Mejia-Alvarez 2009Software Engineering, 7th edition. Chapter 8 Slide 1 System models.
Unified Modeling Language* Keng Siau University of Nebraska-Lincoln *Adapted from “Software Architecture and the UML” by Grady Booch.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 14 Slide 1 Object-oriented Design.
UML Use Case Diagramming Guidelines. What is UML? The Unified Modeling Language (UML) is a standard language for specifying, visualizing, constructing,
Requirements Engineering Methods for Requirements Engineering Lecture-30.
7 Systems Analysis and Design in a Changing World, Fifth Edition.
 What is Modeling What is Modeling  Why do we Model Why do we Model  Models in OMT Models in OMT  Principles of Modeling Principles of Modeling 
Systems Analysis and Design in a Changing World, 6th Edition
UML as a Specification Language for Embedded Systems. By, Mir Ahmed Ali, Asst. Professor, ECM department, SNIST. By, Prof. Narsiah sir, Director of School.
Michael Schloh von Bennewitz 1. Oktober 2002 The Unified Modeling Language Overview of theory and practice of the OMG Unified Modeling.
Unified Modeling Language. Object Oriented Methods ► What are object-oriented (OO) methods?  OO methods provide a set of techniques for analyzing, decomposing,
Systems Analysis and Design in a Changing World, Fourth Edition
Week 04 Object Oriented Analysis and Designing. What is a model? A model is quicker and easier to build A model can be used in simulations, to learn more.
Lecture 14 22/10/15. The Object-Oriented Analysis and Design  Process of progressively developing representation of a system component (or object) through.
 To explain why the context of a system should be modelled as part of the RE process  To describe behavioural modelling, data modelling and object modelling.
Kyung Hee University Class Diagramming Notation OOSD 담당조교 석사과정 이정환.
Basic Characteristics of Object-Oriented Systems
Distributed Java Programming Distributed Java Programming Class #1 August 20, 2002.
UML. Model An abstract representation of a system. Types of model 1.Use case model 2.Domain model 3.Analysis object model 4.Implementation model 5.Test.
SWE 214 (071) Introduction to UML Slide 1 Introduction to UML.
Modified from Sommerville’s originalsSoftware Engineering, 7th edition. Chapter 14 Slide 1 Object-Oriented Design.
1 An Overview of UML. 2 The Unified Modeling Language UML is a graphical language used by software engineers to model software systems during development.
UML (Unified Modeling Language)
1 M206 Chapter 31: An Overview of Software Development 1.Defining the problem 2.Analyzing the requirement – constructing initial structural model 3.Analyzing.
Engineering, 7th edition. Chapter 8 Slide 1 System models.
Modeling with UML – Class Diagrams
Evolution of UML.
Unified Modeling Language
Introduction to Unified Modeling Language (UML)
Start at 17th March 2012 end at 31th March 2012
Abstract descriptions of systems whose requirements are being analysed
Introduction to UML.
Lecture 8 Object Concepts
Presentation transcript:

UML and WSDL for JISC e-Learning Projects INTRODUCTION TO UML Richard Hopkins NeSC Training Team Member

JISC UML/WSDL – Introduction to UML, 9 th Nov Goals and Overview Goals – To enable you to understand the UML part of the first example To explain the context and overall approach for UML Overview UML History and concepts Simple use of most essential diagrams Requirements Structure Behaviour

JISC UML/WSDL – Introduction to UML, 9 th Nov History of UML Use of diagrams In any discipline for the construction of complex artefacts Need to use diagrams, as tools for Thinking Communicating As discipline matures, diagrams become - Standardised – For effective communication between all practitioners Stylized – Specialised technical language for compact representation UML – M is for Models A diagram is a model of the (proposed) system A partial representation of some aspect of the system

JISC UML/WSDL – Introduction to UML, 9 th Nov History of UML Historically A variety of stylised diagram languages Each associated with a design methodology A formalised Process for arriving at a design E.g., for Object-oriented design (early 90s) Grady Boochs OOD – Object-Oriented Design James Rumbaughs OMT – Object-oriented Modelling and Design Ivar Jacobsons OOSE – Object-Oriented Software Engineering Competing Methodologies Rather improbably – Rumbaugh joined Booch, with intention of merging their methods They bought out Jacobsonns company – Objectory These three aimed for a single Unified Method

JISC UML/WSDL – Introduction to UML, 9 th Nov Methodolgy vs Notation Generally need different methodologies for different contexts Small application in four weeks by single programmer Large system in four years by 200-strong development organisation Often use of X methodology was actually use of Xsnotation with methodology appropriate to context Strong reasons for using the same notation Concept of Unified Method, changed to Unified Modelling Language

JISC UML/WSDL – Introduction to UML, 9 th Nov Methodology vs Notation UML is NOT a methodology UML is a notation for recording the results of A requirements gathering / design process Carried out using some methodology – maybe! Any kind of diagram can be used for any purpose that is useful Sufficiently general that could be used with any imaginable O-O methodology However, for concreteness we will assume a particular general methodology -

JISC UML/WSDL – Introduction to UML, 9 th Nov An Overall Development Process Partially articulated requirements Capture Requirements Use Case Diag. Requirements Construct Model of Overall system Class Diag. Structure Sequence Diag. Behaviour These diagram types, and the process can be used both for Designing a new system Understanding an existing system

JISC UML/WSDL – Introduction to UML, 9 th Nov Requirements Overview UML History and concepts Simple use of most essential diagrams Requirements Structure Behaviour

JISC UML/WSDL – Introduction to UML, 9 th Nov Introducing the Library Example A computer system for a university library; some facts The library has members – Staff Students The library contains items - Books possibly several copies of each book Some books are for short-term loan only – only students can do short-term loans Journals Only staff may borrow journals The functionalities include Keeping track of when items are borrowed/returned Allow users to search for a book and check availability

JISC UML/WSDL – Introduction to UML, 9 th Nov Some Queries The library has members – Staff Students The library contains Books; possibly several copies of each book Some books are for short-term loan only – only students can do short- term loans Journal Only staff may borrow journals The functionalities include Keeping track of when items are borrowed/returned Allow users to search for a book and check availability Can someone be both? Do we mean copies? Is user something different from member? Henceforth use user

JISC UML/WSDL – Introduction to UML, 9 th Nov Requirements Engineering Natural language statement of requirements is typically riddled with ambiguities and inconsistencies Requirements Engineering is the discipline of dealing with this Developing UML models helps with identifying and clarifying requirements But still depends on natural language documentation It helps, but does not guarantee complete consistent set of requirements

JISC UML/WSDL – Introduction to UML, 9 th Nov Requirements - Simple Use Cases An Actor – a user of the system, in a particular role BookBorrower is a role played by library members Usually a person, but could be another system An entity outside the system being modelled In web services – usually another web service BookBorrower Borrow Copy of book Update Catalogue Librarian A Use Case – A task that an actor needs to perform with the help of the system Borrow Copy of Book describes the successful outcome – there will be variants for the exception cases - This Actor participates in this Use Case

JISC UML/WSDL – Introduction to UML, 9 th Nov Simple Use Cases Not a very rich diagram – later on we will see richer diagrams Needs more explanation – associated documentation Limitations of natural language! BookBorrower Borrow Copy of book Use Case Documentation Use Case: Borrow copy of book. A bookBorrower presents a book. The system checks that the potential borrower is a member of the library, and that s/he does not already have the maximum permitted number of books on loan. The maximum is 6 unless the member is is a staff member, in which case it is 12. If both ckecks succeed, the system records that this library member has this copy of the book on loan. Otherwise it refuses the loan. Update Catalogue Librarian

JISC UML/WSDL – Introduction to UML, 9 th Nov STRUCTURE Overview UML History and concepts Simple use of most essential diagrams Requirements Structure Behaviour

JISC UML/WSDL – Introduction to UML, 9 th Nov Structure - Class Design UML is for Object-Oriented Design The state of the system is a collection of Objects Each Object is an instance of a Class The structure of the system is characterised by the class and their inter-relationships Key is identifying the classes kinds of things manipulated within the system Standard Technique - Noun identification Take a concise description of the system Identify the words/phrases that denote things

JISC UML/WSDL – Introduction to UML, 9 th Nov Noun Identification Some Facts – The library contains books and journals. It may have several copies of a given book. The system must keep track of when items are borrowed and returned The system must allow users to borrow items subject to rules – A student can borrow up to six items …

JISC UML/WSDL – Introduction to UML, 9 th Nov Class Design – Which Nouns? Library Book Journal Item System Rule User Student NO – Not within the system Yes if rules are updatable No if rules are built in Yes – All these are things which the system needs to track Although they are not independent – Journal is a special case of item Student is a special case of user Here a book, student etc. within the system – Represents an actual entity in the external world Partially Tracks what is happening to the real world entity

JISC UML/WSDL – Introduction to UML, 9 th Nov Class Diagram A box for each Class There are relationships between classes Otherwise dont need a diagram!!! UserStudentStaffItemJournalBook Specialisation/Generalisation User is a generalisation of both Student Staff Any instance of Student is also an instance of User Student Later we will see other class relationships

JISC UML/WSDL – Introduction to UML, 9 th Nov Class Attributes and Operations Book Title : String ItemJournal Attribute – Information associated with each instance of the class – whats important for understanding; not all that exists in a programming language class implementing it Each attribute will have a type

JISC UML/WSDL – Introduction to UML, 9 th Nov Class Attributes and Operations Book Title : String copiesOnShelf() : Integer ItemJournal An operation – something that instances of this class can do, which can be externally invoked A unit of functionality which is externally exposed Equivalent to a Java Method copiesOnShelf() : Integer To provide the invoker with a number which is the number of copies of the book which are available for borrowing. copies(in onShelf:Bool, out copyNos[0..*] Integer) : Status UML terminology is message-passing - An objects operation is invoked by another object sending it a message

JISC UML/WSDL – Introduction to UML, 9 th Nov Web Services as Objects A WSDL definition corresponds to a class a service type An actual web service conforming to that definition is an instance of that class But service types are often not found by noun identification Often more by Identifying Functions, rather than things Legacy Overall domain understanding (guesswork / intuition) Notion of layered architecture Viewing a function-provider as a service object

JISC UML/WSDL – Introduction to UML, 9 th Nov Example some Web Services A Web services Framework for E-learning (surprise!) User Agents (layer) PortalTimetablingLibraryAuthoring Tool... Application Service (layer) Group ManagementResource DiscoveryResource Management... Common Services (layer)... AuthenticationAuthorisationSearch Messaging Naturally a domain noun? – Yes No (As perceived by domain non-expert!)

JISC UML/WSDL – Introduction to UML, 9 th Nov BEHAVIOUR Overview UML History and concepts Simple use of most essential diagrams Requirements Structure Behaviour

JISC UML/WSDL – Introduction to UML, 9 th Nov Behaviour - Sequence Diagrams To Document how objects work together to achieve an overall function of the system – An Interaction Diagram Each sequence diagram shows an example walk-through Typically for a use case Not for all of them For Complex situations Where clarification seems needed

JISC UML/WSDL – Introduction to UML, 9 th Nov Sequence Diagram - participants For Use Case : Borrow copy of book BookBorrower theUser: UsertheCopy: CopytheBook: Book Identify the participants External Actor from the use case Objects within the system This is an instance diagram – Name each object, and identify its class theUser – object which is the internal representation of the user playing the BookBorrower role theUser : User seems redundant, but could have several User participants

JISC UML/WSDL – Introduction to UML, 9 th Nov Sequence Diagram – Lifelines Book Borrower theUser: User theCopy: Copy theBook: Book timetime Object existence lifeline Period of activation 1: 3: 2: 4: 1. BookBorrower invokes the use case – activating the corresponding User object, theUser 2. theUser tells theCopy object that it is now borrowed – it changes its state 3. theCopy tells theBook that it has been borrowed – its reduces its count of available copies 4. TheUser confirms success to BookBorrower The replies to 2 and 3 not shown because not particularly important, whereas the confirmation to external user is. Sending a message The reply

JISC UML/WSDL – Introduction to UML, 9 th Nov Sequence Diagram – Operations Book Borrower theUser: UsertheCopy: Copy theBook: Book timetime Object existence lifelinePeriod of activation 1: borrow(theCopy) 3: borrowed() 2: borrow() 4: borrowStatus Associate with the message line – The information communicated Usually the operation invoked and possibly its parameters Sending a message The reply

JISC UML/WSDL – Introduction to UML, 9 th Nov Final Points UML is a language to enable expression Its up to you what you express and what you dont Which cases you give sequence diagrams Which attributes you include for a class... Based on maximising usefulness to the reader Rather than rigid rules But it maybe you organisations standards, rather than your personal judgement