0% found this document useful (0 votes)
16 views30 pages

UML and Class Diagrams: Advanced Programming I

Uploaded by

Suhvvh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
16 views30 pages

UML and Class Diagrams: Advanced Programming I

Uploaded by

Suhvvh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 30

UML and Class Diagrams

Advanced Programming I

Author: Eng. Carlos Andrés Sierra, M.Sc.


[email protected]

Computer Engineer
Lecturer
Universidad Distrital Francisco José de Caldas

2024-I

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 1 / 24


Outline

1 Unified Modeling Language (UML)

2 UML Diagrams

3 UML Class Diagrams

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 2 / 24


Unified Modeling Language (UML)

Outline

1 Unified Modeling Language (UML)

2 UML Diagrams

3 UML Class Diagrams

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 3 / 24


Unified Modeling Language (UML)

Basics of UML

The Unified Modeling Language


(UML) is a general-purpose,
developmental, modeling
language in the field of
software engineering, that is
intended to provide a standard
way to visualize the design of a
system.
The UML represents a
collection of best engineering
Figure: Prompt: Draw a software practices that have proven
architect drawning some software successful in the modeling of
desings. large and complex systems.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 4 / 24


Unified Modeling Language (UML)

Basics of UML

The Unified Modeling Language


(UML) is a general-purpose,
developmental, modeling
language in the field of
software engineering, that is
intended to provide a standard
way to visualize the design of a
system.
The UML represents a
collection of best engineering
Figure: Prompt: Draw a software practices that have proven
architect drawning some software successful in the modeling of
desings. large and complex systems.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 4 / 24


Unified Modeling Language (UML)

Importance of UML

The UML is a standard


language for specifying,
visualizing, constructing, and
documenting the artifacts of
software systems.
It is a powerful and flexible
language that is used to model
systems in an object-oriented
way.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 5 / 24


Unified Modeling Language (UML)

Importance of UML

The UML is a standard


language for specifying,
visualizing, constructing, and
documenting the artifacts of
software systems.
It is a powerful and flexible
language that is used to model
systems in an object-oriented
way.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 5 / 24


UML Diagrams

Outline

1 Unified Modeling Language (UML)

2 UML Diagrams

3 UML Class Diagrams

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 6 / 24


UML Diagrams

List of UML Diagrams

UML has 14 types of diagrams, which can be divided into two


categories:
Structural Diagrams: These diagrams represent the static aspects of
the system. Here are some examples: Class Diagram, Object Diagram,
Component Diagram, Deployment Diagram, among others.
Behavioral Diagrams: These diagrams represent the dynamic aspects
of the system. Here are some examples: Activity Diagram, Sequence
Diagram, State Diagram, among others.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 7 / 24


UML Diagrams

List of UML Diagrams

UML has 14 types of diagrams, which can be divided into two


categories:
Structural Diagrams: These diagrams represent the static aspects of
the system. Here are some examples: Class Diagram, Object Diagram,
Component Diagram, Deployment Diagram, among others.
Behavioral Diagrams: These diagrams represent the dynamic aspects
of the system. Here are some examples: Activity Diagram, Sequence
Diagram, State Diagram, among others.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 7 / 24


UML Diagrams

UML Deployment Diagrams I


Deployment diagrams are used to visualize the physical hardware and
software expected to be used in real-world execution of a system.

Figure: Prompt: Draw an UML deployment diagram for a simple system.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 8 / 24


UML Diagrams

UML Deployment Diagrams II

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 9 / 24


UML Diagrams

UML Activity Diagrams I


Activity diagrams are used to model workflow and business processes.

Figure: Prompt: Draw an UML activity diagram for a simple process.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 10 / 24


UML Diagrams

UML Activity Diagrams II

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 11 / 24


UML Diagrams

UML Sequence Diagrams I


Sequence diagrams are used to model interactions between objects in a
system.

Figure: Prompt: Draw an UML sequence diagram for a simple system.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 12 / 24


UML Diagrams

UML Sequence Diagrams II

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 13 / 24


UML Diagrams

UML State Diagrams I


State diagrams are used to model the dynamic behavior of an object in a
system.

Figure: Prompt: Draw an UML state diagram for a simple system.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 14 / 24


UML Diagrams

UML State Diagrams II

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 15 / 24


UML Diagrams

Business Process Diagrams I


Business process diagrams are used to model the workflow and business
processes of an organization.

Figure: Prompt: Draw a business process diagram for a simple organization.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 16 / 24


UML Diagrams

Business Process Diagrams II

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 17 / 24


UML Class Diagrams

Outline

1 Unified Modeling Language (UML)

2 UML Diagrams

3 UML Class Diagrams

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 18 / 24


UML Class Diagrams

Basic Concepts of UML Class Diagrams

A class diagram is a type of


static structure diagram that
describes the structure of a
system by showing the system’s
classes, their attributes,
operations, and the relationships
among the classes.
A class diagram is a collection
of classes and interfaces that are
used to model the objects in a
system.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 19 / 24


UML Class Diagrams

Basic Concepts of UML Class Diagrams

A class diagram is a type of


static structure diagram that
describes the structure of a
system by showing the system’s
classes, their attributes,
operations, and the relationships
among the classes.
A class diagram is a collection
of classes and interfaces that are
used to model the objects in a
system.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 19 / 24


UML Class Diagrams

Types of Objects Relations

Association: A relationship
between two classes that is used
to represent a connection
between the classes.
Aggregation: A relationship
between two classes that is used
to represent a part-whole
relationship between the classes.
Composition: A relationship
between two classes that is used
to represent a stronger
part-whole relationship between
the classes.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 20 / 24


UML Class Diagrams

Types of Objects Relations

Association: A relationship
between two classes that is used
to represent a connection
between the classes.
Aggregation: A relationship
between two classes that is used
to represent a part-whole
relationship between the classes.
Composition: A relationship
between two classes that is used
to represent a stronger
part-whole relationship between
the classes.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 20 / 24


UML Class Diagrams

Types of Objects Relations

Association: A relationship
between two classes that is used
to represent a connection
between the classes.
Aggregation: A relationship
between two classes that is used
to represent a part-whole
relationship between the classes.
Composition: A relationship
between two classes that is used
to represent a stronger
part-whole relationship between
the classes.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 20 / 24


UML Class Diagrams

Good practices in UML Class Diagrams

Use singular nouns for class


names.
Use CamelCase for class names.
Use singular nouns for
attributes.
Use camelCase for attributes.
Use verbs for operations as
methods.
Use camelCase for operations.

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 21 / 24


UML Class Diagrams

Class Diagram Example

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 22 / 24


Q&A

Outline

1 Unified Modeling Language (UML)

2 UML Diagrams

3 UML Class Diagrams

MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 23 / 24


Q&A

Thanks!

Questions?

Repo:
github.com/engandres/ud-public/courses/advanced-programming
MSc. C.A. Sierra (UD FJC) Advanced Programming I 2024-I 24 / 24

You might also like