UML Lab Week-1
UML Lab Week-1
and
documenting
the
artifacts
of
Visualizing
Specifying
Constructing
Documenting
Requirements
Architecture
Design
Source code
Project plans
Tests
Releases
5. Active Classes
6. Components
7. Nodes Classes
2. Behavioral Things:
1. Interactions
2. State Machines
3. Grouping Things:
1. Packages
4. Annotational Things:
1. Notes
Diagrams in UML:
1. Class Diagram.
2. Object Diagram.
3. Usecase Diagram.
4. Sequence Diagram.
5. Collaboration Diagram.
6. Statechart
Diagram.
7. Activity Diagram.
8. Component
Diagram.
9. Deployement
Diagram.
Relations:
Association
Dependency
Generalization
Realization
Directed Association
Aggregation and
Composition
Association:
An association is a structural relationship that specifies the
relation between two objects when they are at the same
level (peer level systems).
An Association can specify the relationship, role of the class
and Multiplicity.
An Association used in class diagram, Component diagram,
deployment diagram, usecase diagrams.
The multiplicity can be represented as 1-1..*,*,01.
It is represented as follows:
Directed Association:
Links a semantic association between two classes in the
UML diagram.
Directed association is used in class diagram, Component
diagram, deployment diagram, usecase diagrams.
Symbol:
Aggregation:
Links a semantic association between two classes in the
UML diagram.
Aggregation is used in class diagram.
Symbol:
Composition:
Links a semantic association between two classes in the
UML diagram.
Composition is used in class diagram.
Symbol:
Generalization:
Generalization is a specification relationship in which objects
of the specialized element (the child ) are substitutable for
objects of the generalization element (the parent).It is used in
class diagram.
Symbol:
Dependency:
A dependency is a semantic relationship in which if there is
any change occurred in one object that may effect other object.
Symbol:
Realization:
Realization is a Specified tool that can be represented by
providing a relationship with classifier.
Dependency is used in class diagram, Component
diagram, deployment diagram, usecase diagrams.
Symbol:
Class diagrams:
A class diagram is that which represents a set of classes,
interfaces,
and
collaborations
and
their
relationships,
Uses:
A class diagram is used to model the static design view of a
system.
Object diagrams:
An object diagram shares the same common
properties of all other diagrams.
Uses:
An object diagram is used to model the static design view of
a system.
UseCase Diagrams:
A usecase diagram shares the common properties as all
diagrams. It distinguishes in the contents of use cases, actors,
dependency, and generalization relationships.
Symbol:-
Uses:
A Use case diagram is used to model the static design view of
a system.
Interaction Diagrams:
An Interaction diagram shares the same common properties
as all other diagrams. It differs in its contents
Objects
Links
Messages
It includes two diagrams Sequence and Collaboration.
Sequence Diagrams:
A sequence diagram emphasizes the time ordering of
messages.
Sequence
diagrams
have
two
features
that
(i)Path
(ii) The Sequence number
Object: It is an instance of a class.
Symbol:
Stimulus:
Stimulus
is
communication
between
two
Create:
Destroy:
Uses:
Interaction diagrams are used to model the dynamic aspects of
a system. It is obtained in two ways:
(i) To model flows of control by time ordering.
(ii) To model flows of control by
organization. State Chart Diagrams:
State: A state is a condition during the life of an object or an
interaction during which it satisfies some condition, performs
some action, or waits for some event.
It is represented by a rounded rectangle.
Symbol:
Initial State:
An initial is a kind of pseudo state that represents the starting
point in a region of a state machine. It has a single outgoing
transition to the default state of the enclosing region, and has
no incoming transitions. There can be one (and only one) initial
state in any given region of a state machine. It is not itself a
state but acts as a marker.
Symbol:
Final State: A final state represents the last or "final" state of
the enclosing composite state. There may be more than one
final state at any level signifying that the composite state can
end in different ways or conditions. When a final state is
reached and there are no other enclosing states it means that
the entire state machine has completed its transitions and no
more transitions can occur.
Symbol:
Activity Diagram:
It represents the different activities in the system.
Action State: An action state represents the execution of an
atomic action, typically the invocation of an operation. An
action state is a simple state with an entry action whose only
exit transition is triggered by the implicit event of completing
the
execution
of
the
entry
action.
The
state
therefore
Symbol:
Component Diagrams:
replaceable
part
of
system
that
encapsulates
executable
files.
An
Artifact
may
constitute
the
Deployment Diagrams:
Package: A package is a grouping of model elements. Packages
themselves may be nested within other packages. A package
may contain subordinate packages as well as other kinds of
model elements. All kinds of UML model elements can be
organized into packages.
Symbol:
executable
files.
An
Artifact
may
constitute
the