Uml Unit-5
Uml Unit-5
(Autonomous)
UNIT-6
By
Mr. V.TATA RAO
Assistant Professor,
Dept of CSE
CONTENTS:
Architectural Modeling
Component
Deployment
Component diagrams
Deployment diagrams.
References:
https://www.geeksforgeeks.org/unified-modeling-language-uml-introduction/.
https://www.tutorialspoint.com/uml/uml_modeling_types.htm
Purpose of Component Diagrams
Component diagram is a special kind of diagram in UML. The purpose
is also different from all other diagrams discussed so far.
It does not describe the functionality of the system but it describes the
components used to make those functionalities.
Thus from that point of view, component diagrams are used to
visualize the physical components in a system.
These components are libraries, packages, files, etc.
Component diagrams can also be described as a static implementation
view of a system.
Static implementation represents the organization of the components
at a particular moment.
A single component diagram cannot represent the entire system but a
collection of diagrams is used to represent the whole.
The purpose of the component diagram can be summarized as −
• Visualize the components of a system.
• Construct executables by using forward and reverse engineering.
• Describe the organization and relationships of the components.
How to Draw a Component Diagram?
Component diagrams are used to describe the physical artifacts of a
system. This artifact includes files, executables, libraries, etc
The purpose of this diagram is different. Component diagrams are
used during the implementation phase of an application.
However, it is prepared well in advance to visualize the
implementation details.
Initially, the system is designed using different UML diagrams and
then when the artifacts are ready, component diagrams are used to get
an idea of the implementation.
How to Draw a Component Diagram?
This diagram is very important as without it the application cannot be
implemented efficiently.
A well-prepared component diagram is also important for other
aspects such as application performance, maintenance, etc.
Before drawing a component diagram, the following artifacts are to be
identified clearly −
• Files used in the system.
• Libraries and other artifacts relevant to the application.
• Relationships among the artifacts.
How to Draw a Component Diagram?
After identifying the artifacts, the following points need to be kept
in mind.
•Use a meaningful name to identify the component for which the
diagram is to be drawn.
•Prepare a mental layout before producing the using tools.
•Use notes for clarifying important points.
Following is a component diagram for order management system.
Here, the artifacts are files. The diagram shows the files in the
application and their relationships. In actual, the component
diagram also contains dlls, libraries, folders, etc.
In the following diagram, four files are identified and their
relationships are produced. Component diagram cannot be
matched directly with other UML diagrams discussed so far as it is
drawn for completely different purpose.
How to Draw a Component Diagram?
Where to Use Component Diagrams?
We have already described that component diagrams are used to visualize the static
implementation view of a system. Component diagrams are special type of UML
diagrams used for different purposes.
These diagrams show the physical components of a system. To clarify it, we can say
that component diagrams describe the organization of the components in a system.
Organization can be further described as the location of the components in a system.
These components are organized in a special way to meet the system requirements.
As we have already discussed, those components are libraries, files, executables, etc.
Before implementing the application, these components are to be organized. This
component organization is also designed separately as a part of project execution.
Component diagrams are very important from implementation perspective. Thus, the
implementation team of an application should have a proper knowledge of the
component details
Component diagrams can be used to −
•Model the components of a system.
•Model the database schema.
•Model the executables of an application.
•Model the system's source code.
Component Diagrams
Component diagrams are used in modeling the physical aspects of
object-oriented systems.
A component diagram shows the organization and dependencies among
a set of components.
Component diagrams are used to model the static implementation view
of a system.
Component diagrams are essentially class diagrams that focus on a
system’s components.
Graphically, a Component diagram is a collection of vertices and arcs.
Component diagrams are used for visualizing, specifying, and
documenting component- based systems and also for constructing
executable systems through forward and reverse engineering.
Component diagrams commonly contain Components, Interfaces and
Dependency, generalization, association, and realization relationships. It
may also contain notes and constraints.
THINGS REQUIRED TO DRAW COMPONENT DIAGRAM
Symbol Name Description
A variety of shapes make up deployment diagrams. This list offers an overview of the
basic elements you may encounter, and you can see most of these items illustrated in
the image below.
Artifact: A product developed by the software, symbolized by a rectangle with the
name and the word “artifact” enclosed by double arrows.
Association: A line that indicates a message or other type of communication between
nodes.
Component: A rectangle with two tabs that indicates a software element.
Dependency: A dashed line that ends in an arrow, which indicates that one node or
component is dependent on another.
Interface: A circle that indicates a contractual relationship. Those objects that realize
the interface must complete some sort of obligation.
Node: A hardware or software object, shown by a three-dimensional box.
Node as container: A node that contains another node inside of it—such as in the
example below, where the nodes contain components.
Stereotype: A device contained within the node, presented at the top of the node,
with the name bracketed by double arrows.
DEPLOYMENT DIAGRAM FOR LIBRARY MANAGEMENT SYSTEM
DEPLOYMENT DIAGRAM FOR ATM