Your SlideShare is downloading. ×
Uml
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×
Saving this for later? Get the SlideShare app to save on your phone or tablet. Read anywhere, anytime – even offline.
Text the download link to your phone
Standard text messaging rates apply

Uml

2,547
views

Published on

An Introduction on UML

An Introduction on UML


1 Comment
10 Likes
Statistics
Notes
No Downloads
Views
Total Views
2,547
On Slideshare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
0
Comments
1
Likes
10
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide
  • Sequential:Only one call to an instance may be outstanding at once. Guarded: Multiple calls from concurrent threads may occur simultaneously to one instance, but only one is allowed to commence. The others are blocked until the performance of the first operation is complete. (Designers to ensure that deadlocks can’t occur)Concurrent: Multiple calls from concurrent threads may occur simultaneously to one instance on any concurrent operation. All of them may process concurrently with correct semantics. (Inside the method implementation synchronization problems are correctly addressed.)
  • Transcript

    • 1. UML
      U M L(Unified Modeling Language)BYCh. Vishwa MohanProject ManagerVision Krest Embedded Systems
    • 2. Software Development Life Cycle (SDLC)
      Requirement Definition
      Requirement Analysis.
      System Design
      Prototyping
      Construction
      Integration
      Testing
      Implementation
      Documentation
      Maintenance.
    • 3. What is a Process?
    • 4. What are the Life Cycle Types ?
      Structured Methods
      Code and Fix (Traditional)
      Waterfall
      Spiral
      Ward & Mellor (Real Time & Embedded Systems)
      Object Oriented Methods
      OOA/OOD By Coad & Yourdon
      OOD By Booch
      OMT By Rambaugh
      OOSE by Jacobson
    • 5. Drawbacks of Traditional Methods !
      Adaptability to change is very poor.
      Bugs.
      Person Dependency
      No way to communicate with team members.
      No way to model the system
      Limited user involvement.
      Persons involved in the analysis will required to go for coding and further phases.
    • 6. Benefits of the Object Oriented Methodologies:
      New requirements can be added at later stage and their integration will be very easy.
      It’s possible to deal with more complex systems.
      Easy way to make communication between software developers and experts.
      Seen over the whole of their lifetime, OO models are more stable and thus easier to modify.
      OO abstraction allows increases reusability of work outcomes.
      Finally it’s more fun.
    • 7. Steps involved in the OO Software Development:
      Identify the objects and their attributes.
      Study operations associated with the objects.
      Design classes from objects having similar characteristics.
      Establish relationship between classes.
      Implement the classes and relationships between them.
    • 8. UML
      What is Model ?
      Representation in a certain medium of some thing in the same or other medium.
      A model represents the blueprint of the system. It is an abstract representation of a system.
      What is In a Model ?
      Semantics:
      It captures the classes, associations, states, use cases and messages.
      Visual Representation:
      How to represent model elements. Different tool vendors shows different representation for the same model.
    • 9. What is UML ?
      UML is a general purpose visual modeling language that is used to specify, visualize, construct, and document the artifacts of a software intensive system.
      UML enables system builders to create blue prints that capture their vision in a standard easy-to understand way and communication them to others.
      UML can be used with all processes, throughout the development life cycle, and across different implementation technologies.
      UML captures the static and dynamic behavior of systems.
    • 10. What is a Visual Modeling ?
      Basically, the modeling captures the essential parts of the system.
      Computer system basically automate business processes. However, it’s not easy to build software systems on time and within budget.
      Building a complex software system requires blueprint. You don’t construct a building without a blueprint. Visual modeling is the blueprint for software systems.
      Finally we can say, Visual Modeling is the key to successful software development.
    • 11. What is a Visual Modeling?
    • 12. Benefits of Visual Modeling?
      Visual Modeling captures business process
      Use case analysis is a technique to capture business process from users perspective.
      Visual Modeling is a communication tool.
      Use visual modeling to capture business objects and logic.
      Use visual modeling to analyze and design your application.
      Visual Modeling manages complexity.
      Visual Modeling defines software architecture.
      With the help of Visual modeling language your model your system independent of implementation language.
      Visual Modeling promotes reuse.
      Here Visual Modeling can be used as component browser and it can also be used to model component assembly.
    • 13. UML Concepts are:
      The UML may be used to:
      • Display the boundary of a system & its major functions using use cases and actors
      • 14. Illustrate use case realizations with interaction diagrams
      • 15. Represent a static structure of a system using class diagrams
      • 16. Model the behavior of objects with state transition diagrams
      • 17. Reveal the physical implementation architecture with component & deployment diagrams
      • 18. Extend your functionality with stereotypes
    • OO Software Development with UML
      Inside the UML, you can not only describes data and functions; their interconnections and their relationships with the surrounding world (I.e., with other data and functional units) can be defined in a differential way.
      • This dependency relationship helps the programmers from development to coding phase. It helps the programmers higher degree of complexity.
    • What are the Benefits of UML?
      Reverse Engineering
      Re-engineering
      Forward Engineering
      Documentation Development
      Source Code Generation.
    • 19. Different Diagrams in UML
      Use Case Diagram
      Class Diagram
      Sequence Diagram
      Collaboration Diagram
      State Transition Diagram
      Activity Diagram
      Component Diagram
      Module Diagram
      Deployment Diagram.
      Presentation Diagram
    • 20.
    • 21. UML Views
      Static Views
      Dynamic Views
      • Static View:
      • 22. Static View is the foundation of UML. It captures the object Structure. It doesn’t contains details of dynamic behavior.
      • 23. The key elements in the Static View are
      • 24. Classifier
      • 25. Relationships
    • Classifiers:
      A classifier is a modeling element, that defines the structure and behavior. Classifiers are:
      Classes
      Interfaces
      Data types
      Nodes
      Actors
      Signal
      Behavioral things are classified by other classifiers use cases and signals.
      A Classifier have identity, state, behavior & relationships.
      Relationships among classifiers are: Association, Generalization, various kinds of dependency including Realization and Usage.
    • 26. Classes:
      A Class defines a set of objects that have a state and behavior.
      State is described by its attributes and associations.
      A Class has unique name within its container. The class has a visibility with respect to its container.
      If a class is a part of package then you can represent the class preceded with package name.
      • Eg: HouseHoldApp::WashingMachine
    • Use Case Diagram
      Use Case Diagrams are used to model the interaction of system with the external actors.
      A use case is a description of a system’s behavior from a users standpoint. It consists of group of actors, a set of use cases.
      Use case diagram is used to
      Modeling the system from user point of view
      It shows the boundaries between system and the outside world.
      It is a powerful tool to gather functional requirements.
      Used to identify external users.
      An Actor is a stereotype of class.It is an object outside the scope of the system under discussion.
      In UML three types of relationships between use cases are defined:
      Include
      Extend
      Generalization (Uses)
      Communication between Actors and Use cases can either be Unidirectionalor Bi-directional.
    • 27. Actor
      Registrar
      Faculty
      Student
      Billing System
      An actor is someone or some thing that must interact with the system under development.
      An Actor is a stereo type of class.
      An actor is represented with a sticky man.
    • 28. Use Case
      Maintain Schedule
      Maintain Curriculum
      Request Course Roster
      A use case is a pattern of behavior the system exhibits
      • Each use case is a sequence of related transactions performed by an actor and the system in a dialogue.
      • 29. Use case represented with oval.
      Actors are examined to determine their needs
      • Registrar -- maintain the curriculum
      • 30. Professor -- request roster
      • 31. Student -- maintain schedule
      • 32. Billing System -- receive billing information from registration
    • Use Case Diagram
      Request Course Roster
      Professor
      Student
      Maintain Schedule
      Maintain Curriculum
      Faculty
      Registrar
      Use case diagrams are created to visualize the relation ships between actors and use cases.
    • 33. <<uses>>
      Register for courses
      <<uses>>
      Logon validation
      Maintain curriculum
      Uses and Extends Use Case Relationship
      As the use cases are documented, other use case relationships may be discovered
      • A uses relationship shows behavior that is common to one or more use cases.
      • 34. An extends relationship shows optional behavior
    • Use Case Diagram :
    • 35. Use Case Realization
      The use case diagram presents an outside view of the system
      • Interaction diagrams describe how use cases are realized as interactions among societies of objects
      Two types of interaction diagrams
      • Sequence diagrams
      • 36. Collaboration diagrams
    • Class Diagram:
      Class diagram is the heart of OOAD.
      A class diagram shows the existence of classes and their relationships in the logical view of a system.
      The class diagram depicts the static structure of a system. UML modeling elements in this diagram are:
      Classes and their structure and behavior (attributes & operations)
      Their Relationships with other classes.
      Multiplicity and Navigation indicator.
      Role Names
      Class: The common noun corresponding to every object identified in the problem domain is a class.
      A class is a collection of objects with common structure, common behavior, common relationships and common semantics.
      Classes are found by examining the objects in sequence and collaboration diagram
    • 37. Class Diagram
      Classes can represent
      Physical thing (Airplane)
      Business thing (order, invoice)
      Logical thing (broadcasting schedule)
      Application thing (Button, Cerror)
      Computer thing (hash table)
      Behavior thing (A Task)
      Types of Classes you can show
    • Classes
      ScheduleAlgorithm
      RegistrationManager
      RegistrationForm
      Professor
      Course
      Student
      CourseOffering
      Inside UML a class is represented with three compartments:
      First compartment represented with class name.
      Second is represented with attributes
      Finally third compartment is used to represent the behaviors of a class.
    • 42. Attributes
      CourseOffering
      number
      loation
      time
      The structure of a class is represented by its attributes.
      Attributes may be found by examining class definitions, the problem requirements, and by applying domain knowledge.
      Each course offering
      has a number, location
      and time
    • 43. Operations
      registration
      registration
      form
      manager
      RegistrationManager
      3: add course(joe, math 01)
      addCourse(Student,Course)
      The behavior of a class is represented by its operations.
      Operations may be found by examining interaction diagrams.
    • 44. Relationships
      Relationships provides pathway for communication between objects.
      Sequence and/or collaboration diagrams are examined to determine what links between objects need to exist to accomplish the behavior.
      If two objects need to “talk” there must be a link between them.
      Three types of relationships are:
      Association, Aggregation and Dependency.
    • 45. Interfaces:
      Interfaces does not have attributes. So there is no state for interfaces.
      Interfaces doesn’t have outgoing associations that are visible to it.
      You can draw the following relationships with interfaces
      An Interface is represented by a Circle with small line attached to it.
      Interface
    • 48. Association
      An association establishes relationship between two classes. It is a bi-directional.
      Data can flow both directions across association.
      The frequency of association is called Multiplicity.
      You can apply constraints on association (eg: ordered, or etc., )
      One way of association is called directed association, in which only one side knows the other, but not vice versa.
      Different types of associations are:
      • Recursive Association
      • 49. Attributed Association
      • 50. Qualified Association
      • 51. Derived Association
      • 52. Directed Association
    • Aggregation & Dependency
      An aggregation is a stronger form of relationship where the relationship is between a whole and its parts.
      • An aggregation is shown as a line connecting the related classes with a diamond next to the class representing the whole.
      A dependency relationship is a weaker form of relationship showing a relationship between a client and a supplier where the client does not have semantic knowledge of the supplier.
      • A dependency is shown as a dashed line pointing from the client to the supplier.
    • Finding Relationships
      RegistrationMgr
      RegistrationMgr
      .NET : Course
      3: add student(joe)
      Course
      Relationships are discovered by examining the interaction diagrams.
      • If two objects must talk there must be a path way for communication.
    • Typical Class Diagram
    • 53. Multiplicity
      Multiplicity defines how many objects participate in a relationship.
      • It defines the number of instances of one class related to ONE instance of the other class.
      • 54. For each association and aggregation, there are two multiplicity decisions to make: one for each end of the relationship
      • 55. A class also has multiplicity.
    • Navigation
      Although association and aggregation are bi-directional by default, it is often desirable to restrict navigation to one direction.
      • If navigation is restricted, an arrowhead is added to indicate the direction of the navigation.
    • Concurrency
      Inside class diagram, you can specify the attribute concurrency for each method. This concurrency states that it’s semantic of concurrent calls to the same passive instance.
      Basically it addresses the synchronization problem in the case of multiple threads.
      The different concurrency options are:
    • Inheritance
      Inheritance is a relationships between a superclass and its subclass.
      There are two ways to find inheritance:
      • Generalization
      • 58. Specialization.
      Common attributes, operations, and/or relationships are shown at the highest applicable level in the hierarchy.
    • 59. Inheritance Representation
    • 60. Links
      Link: A Link is an instance of an association. It connects objects rather then classes.
      • Link name should be under lined.
      Mohan:Faculty
      JayaMukhi:Batch
      Teaches
    • 61. Stereotypes
      Stereotype and Constraints are two constructs the UML provided for extending the language.
      • Stereotype is nothing but adding new features to the existing elements and make is as new element.
      • 62. Stereotypes can be sued to extend the UML notational elements.
      Stereotypes may be used to classify and extend associations, inheritance relationships, classes, and components.
      Examples of stereotypes:
      Class Stereotypes: Actor, boundary, entity, utility, exception.
      Inheritance Stereotypes: uses and extends.
      Component Stereotypes: subsystem.
    • 63. Constraints
      A Constraint is an expression which restricts the possible contents, states are the semantics of a model element which must always be satisfied.
      Constraints are always enclosed in braces.
      The below represents constraint on association.
      Bank Teller
      Customer
      Servers {ordered}
      Chooses
      .NET Course
      Student
      {Or}
      Java Course
      Chooses
    • 64. Sequence Diagram:
      Objects are usually identified by studying the problem domain. The main tools to study the objects behavior are:
      • Sequence Diagram
      • 65. State Transition Diagram
      • 66. Activity Diagram
      • 67. Collaboration Diagram
      Sequence diagram is a tool to model the dynamic behavior of the system.
      • It shows a graphical method to illustrate the sequence of events that occur one particular execution of the system.
      • 68. The sequence diagram shows the interaction between objects in a time sequence.
      • 69. The messages can be : Simple, Synchronous, Asynchronous and Reply messages.
    • Representation of Messages
      The below are the symbols of the message representations.
    • 70. Sequence Diagram
      registration
      registration
      math 101
      math 101
      : Student
      form
      manager
      section 1
      1: fill in info
      2: submit
      3: add course(joe, math 01)
      4: are you open?
      5: are you open?
      6: add (joe)
      7: add (joe)
      A Sequence diagram displays the object interaction arranged in a time sequence.
    • 71. Sequence Diagram
    • 72. State Transition Diagram
      A state transition diagram shows:
      • The life history of a given class.
      • 73. The events that cause a transition from one state to another.
      • 74. The actions that result from a state change.
      State transition diagrams are created for objects with significant dynamic behavior.
    • 75. State Transition Diagram
    • 76. Collaboration Diagram
      The Collaboration diagram shows a set of interactions between selected objects in a specific limited situation (context), focusing on the relations between the objects and their topography.
      • A Collaboration diagram displays the object interactions organized around objects and their links to one another.
      • 77. The collaboration diagram shows the chronological sequence of the messages, their names, responses and their arguments.
      Like sequence diagram collaboration diagram also shows the object interaction.
      • The sequence diagram is organized according to time and collaboration diagram is organized according to space.
      • 78. The sequence diagram and collaboration diagram are similar in fact semantically they are equivalent. You can turn a sequence diagram into equivalent collaboration diagram and vice versa.
    • Collaboration Diagram
    • 79. Component Diagram
      Component diagram illustrate the organizations and dependencies among software components.
      A component may be:
      • A source Code Component
      • 80. A run time Component
      • 81. An executable component.
    • Typical Component Diagram
    • 82. Deployment Diagram
      Registration
      Database
      Main
      Library
      Building
      Dorm
      The deployment diagram shows the configuration or run-time processing elements and the software processes living on them.
      The deployment diagram visualizes the distribution of components across the enterprise.
    • 83.
    • 84.
    • 85.
    • 86.
    • 87. Questions ?