Unit 1 Part 1
Unit 1 Part 1
Unit 1 Part 1
UML Introduction
- Grady Booch, The Unified Modeling Language User Guide (2nd
Edition)
• The UML was developed in 1994-95 by Grady Booch, Ivar Jacobson,
and James Rumbaugh at the Rational Software.
• In 1997, it got adopted as a standard by the Object Management
Group (OMG).
OO Analysis and Design
The purpose of OO is given below:
• To identify the objects of a system.
• To identify their relationships.
• To make a design that is executable when the concepts of OO are
employed.
Following are the steps where OO concepts are applied and implemented:
Step 1: OO Analysis
Step 2: OO Design
Step 3: OO Implementation
Why we model?
• "Modeling is a central part of all the activities that lead up to the
deployment of good software.
• We build models to communicate the desired structure and behavior
of our system.
• We build models to visualize and control the system's architecture.
• We build models to better understand the system we are building,
often exposing opportunities for simplification and reuse.
• And we build models to manage risk."
Importance of Modeling
• Modeling is a proven & well accepted engineering techniques. In
building architecture, we develop architectural models of houses to
help visualize the final products.
• In Unified Modeling Language (UML), a model may be structural,
emphasizing the organization of the system or it may be behavioral,
emphasizing the dynamics of the system.
• A model is a simplification of reality, providing blueprints of a system.
UML, in specific:
• Permits you to specify the structure or behavior of a system.
• Helps you visualize a system.
• Provides template that guides you in constructing a system.
• Helps to understand complex system part by part.
• Document the decisions that you have made.
We build model so that we can better understand the system we are
developing. A model may encompass an overview of the system under
consideration, as well as a detailed planning for system design,
implementation and testing.
Principles of UML Modeling
• The choice of model is important.
• Every model may be expressed at different levels of precision.
• The best models are connected to reality.
• No single model is sufficient.
SYSTEM,MODEL,VIEW
• A model is an abstraction describing a subset of a system
• A view depicts selected aspects of a model
• A notation is a set of graphical or textual rules for depicting views
• Views and models of a single system may overlap each other
Examples:
• System: Aircraft
• Models: Flight simulator, scale model
• Views: All blueprints, electrical wiring, fuel system
Introduction to UML
• The unified modeling language (UML) is a standard language for
writing software blueprints of the system.
Definition: The UML is a language for
• Visualizing
• Specifying
• Constructing
• Documenting the objects of a software system.
• UML is a language that provides vocabulary and the rules for
combining words in that vocabulary for the purpose of
communication.
• Vocabulary and rules of a language tell us how to create and real
well-formed models, but they don’t tell you what model you should
create and when should create them.
Model?
• A model is a simplification of reality.
• A model provides the blueprints of a system.
• A model may be structural, emphasizing the organization of the
system, or it may be behavioral, emphasizing the dynamics of the
system.
Why do we model?
• We build models so that we can better understand the system we are
developing.
Building blocks of UML /Elements of UM L
Building blocks of UML are divided into:
1. Things
2. Relationships
3. Diagrams
1. Things in the UML: There are four kinds of things in the UML:
i. Structural things
ii. Behavioral things
iii. Grouping things
iv. Annotational things
i. Structural things are the nouns of UML models. These are the static parts
of a model, representing elements that are either conceptual or physical.
In all, there are seven kinds of structural things.
a. Class
b. Interface
c. Collaboration
d. Use case
e. Active class
f. Component
g. Node
a. Class: Class is a description of a set of objects that share the same
attributes, operations, relationships, and semantics.
A class implements one or more interfaces. Graphically, a class is
rendered as a rectangle, usually including its name, attributes, and
operations.
• Object: An individual that describes the behavior and the functions of
a system. The notation of the object is similar to that of the class; the
only difference is that the object name is always underlined and its
notation is given below;
b. Interface: Interface is a collection of operations that specify a service
of a class or component. An interface therefore describes the
externally visible behavior of that element. An interface might
represent the complete behavior of a class or component or only a part
of that behavior.
• An interface is rendered as a circle together with its name. An
interface rarely stands alone. Rather, it is typically attached to the
class or component that realizes the interface.
ISpelling
C. Collaboration: Collaboration defines an interaction and is a society
of roles and other elements that work together to provide some
cooperative behavior. Therefore, collaborations have structural, as well
as behavioral, dimensions. A given class might participate in several
collaborations.
• Graphically, a collaboration is rendered as an ellipse with dashed
lines, usually including only its name.