OOSE Lab
OOSE Lab
EX.NO: 1
Study the basic essentials of Unified Modelling Language
DATE:
Problem Statement:
This study aims to understand the basic concepts of Unified Modelling Language
and focus on design approach of UML.
Design Approach:
a) UML Synonyms:
UML is graphical modelling language in the field of Software Engineering.
UML is used to specify, visualize, construct, and document the artefacts (major
elements) of the software system. It provides a set of graphical notations and
concepts to represent the design and structure of systems, making it a widely
adopted tool for communication and collaboration among software developers and
stakeholders
c) Goal of UML
Modelling 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 behaviour of our system
Visualize and control the system’s architecture
Better understand the system we are building, often exposing
opportunities for simplification, reuse and manage risk.
d) Evolution of UML:
1) UML began in the mid-1990s as a common notation for software modelling.
2) UML 2.0 (2003) marked a major upgrade, introducing new diagrams and
improved precision.
3) Subsequent versions (UML 2.x) refined features and addressed issues.
4) UML 2.5 (2015) modernized UML, aligning it with agile development.
5) Ongoing efforts post-2017 aim to adapt UML to evolving software
engineering practices.
1
Register No:921321104243
I. Things
Anything that is a real-world entity or object is termed as things. It can be
divided into several different categories:
i. Structural things
ii. Behavioural things
iii. Grouping things
iv. Annotational things
i. Structural things
Class: A Class is a set of identical things that outlines the functionality and
properties of an object. It also represents the abstract class whose functionalities
are not defined. Its notation is as follows :
2
Register No:921321104243
Object: An individual that describes the behaviour 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:
Collaboration: It represents the interaction between things that is done to meet the
goal. It is symbolized as a dotted ellipse with its name written inside it.
Use case: Use case is the core concept of object-oriented modelling. It portrays a set
3
Register No:921321104243
Actor: It comes under the use case diagrams. It is an object that interacts with the
system, for example, a user.
4
Register No:921321104243
ii. Behavioral Things
They are the verbs that encompass the dynamic parts of a model. It depicts the
behaviour of a system. They involve state machine, activity diagram, interaction
diagram, grouping things, annotation things
State Machine: It defines a sequence of states that an entity goes through in the
software development lifecycle. It keeps a record of several distinct states of a
system component.
5
Register No:921321104243
It is a method that together binds the elements of the UML model. In UML, the
package is the only thing, which is used for grouping.
Package: Package is the only thing that is available for grouping behavioural and
structural things
Note: It is used to attach the constraints, comments, and rules to the elements of
the model. It is a kind of yellow sticky note.
6
Register No:921321104243
II. Relationships
Association: A set of links that associates the entities to the UML model. It tells
how many elements are actually taking part in forming that relationship. It is
denoted by a dotted line with arrowheads on both sides to describe the
relationship with the element on both sides.
7
Register No:921321104243
III. Diagrams
The diagrams are the graphical implementation of the models that incorporate
symbols and text. Each symbol has a different meaning in the context of the
UML diagram. There are thirteen different types of UML diagrams that are
available in UML 2.0, such that each diagram has its own set of a symbol. And
each diagram manifests a different dimension, perspective, and view of the
system. UML diagrams are classified into three categories that are given below:
Structural Diagram
Behavioural Diagram
Interaction Diagram
o Class diagram
o Object diagram
o Package diagram
o Component diagram
o Deployment diagram
o Activity diagram
o State machine diagram
o Use case diagram
o Timing diagram
o Sequence diagram
o Collaboration diagram
8
Register No:921321104243
f) UML diagram:
Classes diagrams
Objects diagrams
Deployment diagrams
Package diagrams
Composite structure diagram
Component diagram
Structural model represents the framework for the system and this framework is
the place where all other components exist. Hence, the class diagram, component
diagram and deployment diagrams are part of structural modelling. They all
represent the elements and the mechanism to assemble them. The structural model
never describes the dynamic behaviour of the system. Class diagram is the most
widely used structural diagram.
Activity diagrams
Interaction diagrams
Use case diagrams
9
Register No:921321104243
architectural modelling.
h) UML Notation:
This is just an extension to the UML building block section discussed in Chapter Two.
Structural Things
Graphical notations used in structural things are most widely used in UML. These are
considered as the nouns of UML models. Following are the list of structural things.
Classes
Object
Interface
Collaboration
Use case
Active classes
Components
Nodes
Class Notation
UML class is represented by the following figure. The diagram is divided into four parts.
The top section is used to name the class.
The second one is used to show the attributes of the class.
The third section is used to describe the operations performed by the class.
The fourth section is optional to show any additional components.
Classes are used to represent objects. Objects can be anything having properties and
responsibility.
10
Register No:921321104243
Object Notation
The object is represented in the same way as the class. The only difference is the name which is
underlined as shown in the following figure.
As the object is an actual implementation of a class, which is known as the instance of a class.
Hence, it has the same usage as the class.
Interface Notation
Interface is represented by a circle as shown in the following figure. It has a name which is
generally written below the circle.
Interface is used to describe the functionality without implementation. Interface is just like a
template where you define different functions, not the implementation. When a class
implements the interface, it also implements the functionality as per requirement.
Collaboration Notation
Collaboration is represented by a dotted eclipse as shown in the following figure. It has a name
written inside the eclipse.
11
Register No:921321104243
Use case is represented as an eclipse with a name inside it. It may contain additional
responsibilities.
Actor Notation
An actor can be defined as some internal or external entity that interacts with the system.
12
Register No:921321104243
An actor is used in a use case diagram to describe the internal or external entities.
Initial state is defined to show the start of a process. This notation is used in almost all
diagrams.
The usage of Initial State Notation is to show the starting point of a process.
Final state is used to show the end of a process. This notation is also used in almost all diagrams
to describe the end.
The usage of Final State Notation is to show the termination point of a process.
Active class looks similar to a class with a solid border. Active class is generally used to
describe the concurrent behavior of a system.
13
Register No:921321104243
Component Notation
A component in UML is shown in the following figure with a name inside. Additional elements
can be added wherever required.
Component is used to represent any part of a system for which UML diagrams are made.
Node Notation
A node in UML is represented by a square box as shown in the following figure with a name. A
node represents the physical component of the system.
Node is used to represent the physical part of a system such as the server, network, etc.
Behavioral Things
14
Register No:921321104243
Dynamic parts are one of the most important elements in UML. UML has a set of powerful
features to represent the dynamic part of software and non-software systems. These features
include interactions and state machines.
Interaction Notation
Interaction is basically a message exchange between two UML components. The following
diagram represents different notations used in an interaction.
15
Register No:921321104243
State machine describes the different states of a component in its life cycle. The notations are
described in the following diagram.
State machine is used to describe different states of a system component. The state can be
active, idle, or any other depending upon the situation.
Grouping Things
Organizing the UML models is one of the most important aspects of the design. In UML, there
is only one element available for grouping and that is package.
Package Notation
Package notation is shown in the following figure and is used to wrap the components of a
system.
16
Register No:921321104243
Annotational Things
In any diagram, explanation of different elements and their functionalities are very important.
Hence, UML has notes notation to support this requirement.
Note Notation
This notation is shown in the following figure. These notations are used to provide necessary
information of a system.
Relationships
A model is not complete unless the relationships between elements are described properly.
The Relationship gives a proper meaning to a UML model. Following are the different types of
relationships available in UML.
Dependency
Association
Generalization
Extensibility
Dependency Notation
Dependency is an important aspect in UML elements. It describes the dependent elements and
the direction of dependency.
Dependency is represented by a dotted arrow as shown in the following figure. The arrow head
17
Register No:921321104243
represents the independent element and the other end represents the dependent element.
Association Notation
Association describes how the elements in a UML diagram are associated. In simple words, it
describes how many elements are taking part in an interaction.
Association is represented by a dotted line with (without) arrows on both sides. The two ends
represent two associated elements as shown in the following figure. The multiplicity is also
mentioned at the ends (1, *, etc.) to show how many objects are associated.
Generalization Notation
Generalization is represented by an arrow with a hollow arrow head as shown in the following
figure. One end represents the parent element and the other end represents the child element.
18
Register No:921321104243
Extensibility Notation
All the languages (programming or modeling) have some mechanism to extend its capabilities
such as syntax, semantics, etc. UML also has the following mechanisms to provide extensibility
features.
Extensibility notations are used to enhance the power of the language. It is basically additional
elements used to represent some extra behavior of the system. These extra behaviors are not
covered by the standard available notations.
19
Register No:921321104243
Business Process Modelling: UML activity diagrams are employed to
model and understand business processes, aiding in business analysis and
improvement.
System Design and Redesign: Use UML during the design phase of
software development and when redesigning systems to ensure a clear and
comprehensive blueprint for implementation.
Conclusion:
Studying UML is crucial for software professionals, offering a standardized language
for effective communication, collaboration, systematic design and understanding
software systems.
20
Register No:921321104243
EX.NO: 2
DATE:
21