3. uml fundamentals

Upload: thanh-nguyen-dinh

Post on 05-Apr-2018

222 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/2/2019 3. UML Fundamentals

    1/49

    Dumitru Radoiu

    Spring2009

    PETRU MAIOR UNIVERSITY

  • 8/2/2019 3. UML Fundamentals

    2/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    UMLTools

  • 8/2/2019 3. UML Fundamentals

    3/49

    Project management activities vs. Software development activities

    time

    Project management activities

    Initiation Planning Execution Closing

    Monitoring

    Requirementsro uct

    Service orResult

    Analysis Design Implementation

    Software development activities

  • 8/2/2019 3. UML Fundamentals

    4/49

    Software development activities

    time

    Analysis Design Implementation

    Deliverables

    Exclusions

    Specifications

  • 8/2/2019 3. UML Fundamentals

    5/49

    Analysis Design ImplementationIdeal

    a.

    b.

    c

    d

    e

    ,numberofbugs

    a. You dont know what the client expects, the design emphasizes the wrongexpectations, the product is riddled with bugs

    . ,needs and the product is riddled with bugs

    c. You know what the client needs, but your design does not implement it isoversized trying to fix it

    . ,

    e. You have no idea what the client wants, design complicated, implementation

    not solid

  • 8/2/2019 3. UML Fundamentals

    6/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    UMLTools

  • 8/2/2019 3. UML Fundamentals

    7/49

    Waterfall Model

    Analysis

    Implementation

  • 8/2/2019 3. UML Fundamentals

    8/49

    The Spiral Model

    Analysis Analysis

    Design

    Analysis

    Design

    Implementation

    Implementation Implementation

    Must have functionalityNever used functionalit

  • 8/2/2019 3. UML Fundamentals

    9/49

    Iterative Model

    Analysis Design Implementation

    Component A Component B Component C

    Analysis Analysis Analysis

    Design

    Implementation

    Design

    Implementation

    Design

    Implementation

  • 8/2/2019 3. UML Fundamentals

    10/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    UMLTools

  • 8/2/2019 3. UML Fundamentals

    11/49

    RUP Model (Unified Modeling Process)

    a ora orMilestonesMilestones

    Inception Elaboration Construction Transition

    A A A A A

    D

    I

    D

    I

    D

    I

    D

    I

    D

    I

    Identify the Design in detail Write the Deliver to theusers

    going to

    develop

    on your system

  • 8/2/2019 3. UML Fundamentals

    12/49

    RUP Model Phases

    MajorMajorMilestonesMilestones

    Inception Elaboration Construction Transition

    InceptionInception Definethescopeofproject(20%model)Definethescopeofproject(20%model)

    , ,, ,model)model)

    ConstructionConstruction Buildtheproduct(100%development)Buildtheproduct(100%development)

  • 8/2/2019 3. UML Fundamentals

    13/49

    RUP Model Iterations

    MajorMajorMilestonesMilestones

    Inception Elaboration Construction Transition

    Releases

    activitieswithanestablishedplanand

    evaluationcriteria,resultinginan

    executablerelease

    (internal

    or

    external)

    InceptionInception ElaborationElaboration ConstructionConstruction TransitionTransition

    PreliminaryPreliminary

    IterationIteration

    Architect.Architect.

    IterationIteration

    Architect.Architect.

    IterationIteration

    Devel.Devel.

    IterationIteration

    Devel.Devel.

    IterationIteration

    Devel.Devel.

    IterationIteration

    TransitionTransition

    IterationIteration

    TransitionTransition

    IterationIteration

  • 8/2/2019 3. UML Fundamentals

    14/49

    - Reduce risk

    RUP Model: Iterative and Incremental

    Content

    - Better control

    - Client feedback

    -

    Developing the productp3

    p2

    p1

  • 8/2/2019 3. UML Fundamentals

    15/49

    SW development lifetime

    SW lifetime in

    SW lifetimeRUP Model

    SW Development PhasesProcess Workflows

    time 20% 80%

    Business Modeling

    Business Req.

    Elaboration TransitionInception Construction Production

    Operation &

    Implementation

    Designuppor

    Ensures highquality and

    Su ortin Workflows

    DeploymentOperationSupport

    high

    availability of

    SW

    Project Management

    Project Environment

    Change Management Opportunityfor reuse, mng

    several

    PreliminaryIteration(s)

    Iter.#1

    Iter.#2

    Iter.#n

    Iter.#n+1

    Iter.#n+2

    Iter.#m

    Iter.#m+1A workflow shows all the activitiesyou might go through to produce a

    particular set of artifacts

    ONE Iteration ONLY

    Portofolio Mngm.

    simultaneously

  • 8/2/2019 3. UML Fundamentals

    16/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    Actors,relationships,usecases,usecasediagrams,subsystems

    Relationshi s:

    eneralization,,

    UMLTools

  • 8/2/2019 3. UML Fundamentals

    17/49

    Analysis Design Implementation

    Requirements System

    ystem = somet ng t atperforms a function

    Whos using the system? What the system does?

  • 8/2/2019 3. UML Fundamentals

    18/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    Actors,relationships,usecases

    Usecase

    dia rams

    Subsystems

    Relationships:generalization,,

  • 8/2/2019 3. UML Fundamentals

    19/49

    Actors-Use cases - Relationships

  • 8/2/2019 3. UML Fundamentals

    20/49

    Actors-Use cases - Relationships

    System

  • 8/2/2019 3. UML Fundamentals

    21/49

    Actors-Use cases - Relationships

    Actor

  • 8/2/2019 3. UML Fundamentals

    22/49

    Actors-Use cases - Relationships

    Relationship

  • 8/2/2019 3. UML Fundamentals

    23/49

    Use cases

    use case name

    develop software

    . .

    developer

  • 8/2/2019 3. UML Fundamentals

    24/49

    Use cases

    create software record grades scare somebody

    Describe theperformed functionality

  • 8/2/2019 3. UML Fundamentals

    25/49

    Use cases

    development::

    create software

    grading::record

    grades

    scaring::scare

    somebody

    You can identify whichpackage a use case is from

  • 8/2/2019 3. UML Fundamentals

    26/49

    Describing use cases

    record grades

    Teacher

    Teacher System

    Ensure the student is in the database

    be grading for

    Indicates which assignments Begins a transaction

    e w e en er ng gra es orEnters the grade for thestudents assignment

    s e ass gnmen o e a a aseValidates the grade (it is within range)Records the grade for the assignmentEnds the transactionNotifies the teacher that the grade hasbeen recorded

  • 8/2/2019 3. UML Fundamentals

    27/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    Actors,relationships,usecases

    Usecase

    dia rams

    Subsystems

    Relationships:generalization,,

  • 8/2/2019 3. UML Fundamentals

    28/49

    Use case diagrams

    diagnose car

    Mechanicfix car

    drive carCar owner

  • 8/2/2019 3. UML Fundamentals

    29/49

    Use case diagrams

    diagnose car

    Mechanicfix car

    drive carCar owner

    Use case

  • 8/2/2019 3. UML Fundamentals

    30/49

    Use case diagrams

    diagnose car

    Mechanicfix car

    drive carCar owner

    Use case diagram

    (use case model)

  • 8/2/2019 3. UML Fundamentals

    31/49

    diagnose car

    Mechanicfix car

    drive carCar owner

    ys em

  • 8/2/2019 3. UML Fundamentals

    32/49

    How to model a use case diagram?

    1. Findtheactorsandthesystemrequiredfunctionalities(usecases)

    2. Prioritizetheusecases

    3. Detaileachusecase

    4. Putthemtogetherintoausecasemodel

    5. Prototypeuser

    interface

  • 8/2/2019 3. UML Fundamentals

    33/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    Actors,relationships,usecases

    Usecase

    dia rams

    Subsystems

    Relationships:generalization,,

  • 8/2/2019 3. UML Fundamentals

    34/49

    Subsystemseditor

    Subs stem

    compiler

    compile application

    debugger

    developer load source code

    save source code

  • 8/2/2019 3. UML Fundamentals

    35/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    Actors,relationships,usecases

    Usecase

    dia rams

    Subsystems

    Relationships:generalization,,

  • 8/2/2019 3. UML Fundamentals

    36/49

    Include relationship

    Relationshi

  • 8/2/2019 3. UML Fundamentals

    37/49

    Include relationship

    save gradesrecord grades

    This use case willinclude functionality

    from another usecase to its function

  • 8/2/2019 3. UML Fundamentals

    38/49

    Include relationship

    Record grades

    Save grades

    pgra e gra esTeacher

  • 8/2/2019 3. UML Fundamentals

    39/49

    Include relationship

    Save grades

    Record grades

    Notify parents

    >

    Upgrade gradesTeacher

    very me we save

    grades we notifyparents

  • 8/2/2019 3. UML Fundamentals

    40/49

    Extends relationship

    Relationshi

    e a a new

    functionality to thisone

  • 8/2/2019 3. UML Fundamentals

    41/49

    Extends relationship

    Save grades

    Record grades

    Notify parents

    >

    Upgrade gradesTeacher

    e no y paren s

    ONLY if a certaincondition occurs!!!

    E d l i hi

  • 8/2/2019 3. UML Fundamentals

    42/49

    Extends relationship

    Notify parentsSave grades

    Record grades

    >

    Upgrade gradesTeacher

    Failing grade is saved

    G li ti

  • 8/2/2019 3. UML Fundamentals

    43/49

    Generalization

    Generalized actor Generic actor

    She Cook Cook

    G li ti

  • 8/2/2019 3. UML Fundamentals

    44/49

    Generalization

    Cook DinnerCook Pasta

    case

    Generalization

  • 8/2/2019 3. UML Fundamentals

    45/49

    Cook PastaGeneralization

    Generalized useCook Dinner

    Generic use case Generic use case

    Father Cook

    o er oo

    Cook

  • 8/2/2019 3. UML Fundamentals

    46/49

    Agenda

    , ,

    SoftwareLifecycle

    Models

    UnderstandingRUP(orUnifiedModelingProcess)

    WhatisUML

    Actors,relationships,usecases

    Usecase

    dia rams

    Subsystems

    Relationships:generalization,,

    UML tools

  • 8/2/2019 3. UML Fundamentals

    47/49

    UML tools

    http://en.wikipedia.org/wiki/List_of_UML_tools

    http://www.sparxsystems.com.au/

    http://www.sparxsystems.com.au/uml-tutorial.html

    UML Project 1

  • 8/2/2019 3. UML Fundamentals

    48/49

    UML Project 1

    The following requirements are for a computerized registration system:

    The Registrar sets up the curriculum for a semesterOne course may have multiple course offerings

    Students select 4 primary courses and 2 alternate coursesOnce a student registers for a semester, the billing system is notified so the

    student ma be billed for the semesterStudents may use the system to add/drop courses for a period of time afterregistrationProfessors use the system to receive their course offering catalogs

    logon validation

    1. Find the actors and the s stem re uired functionalities use cases

    2. Prioritizethe

    use

    cases

    3. Detaileachusecase

    4. Putthemtogetherintoausecasemodel

    . rototypeuser nter ace opt ona

  • 8/2/2019 3. UML Fundamentals

    49/49