0% found this document useful (0 votes)
9 views4 pages

Notes

The document explains the purpose and components of activity diagrams in software development, highlighting their role in visualizing workflows, concurrent processing, and complex decision-making. It details various notations used in activity diagrams, such as initial states, action states, decision nodes, and final states. The conclusion emphasizes the utility of activity diagrams in illustrating project tasks and their importance in understanding interdependencies.
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)
9 views4 pages

Notes

The document explains the purpose and components of activity diagrams in software development, highlighting their role in visualizing workflows, concurrent processing, and complex decision-making. It details various notations used in activity diagrams, such as initial states, action states, decision nodes, and final states. The conclusion emphasizes the utility of activity diagrams in illustrating project tasks and their importance in understanding interdependencies.
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

AIM: Develop the activity diagram to represent flow from one activity to another for

software development

Theory:
Activity Diagram
Activity diagrams show the steps involved in how a system works, helping us understand the
flow of control. They display the order in which activities happen and whether they occur one
after the other (sequential) or at the same time (concurrent). These diagrams help explain
what triggers certain actions or events in a system.
 An activity diagram starts from an initial point and ends at a final point, showing different
decision paths along the way.
 They are often used in business and process modeling to show how a system behaves
over time.
Use of Activity Diagram
Activity diagrams are useful in several scenarios, especially when you need to visually
represent the flow of processes or behaviors in a system. Here are key situations when you
should use an activity diagram:
1. Modeling Workflows or Processes: When you need to map out a business process,
workflow, or the steps involved in a use case, activity diagrams help visualize the flow of
activities.
1. Concurrent or Parallel Processing: If your system or process involves activities
happening simultaneously, an activity diagram can clearly show the parallel flow of tasks.
1. Understanding the Dynamic Behavior: When it’s essential to depict how a system
changes over time and moves between different states based on events or conditions,
activity diagrams are effective.
1. Clarifying Complex Logic: Use an activity diagram to simplify complex decision-
making processes with branching paths and different outcomes.
1. System Design and Analysis: During the design phase of a software system, activity
diagrams help developers and stakeholders understand how different parts of the system
interact dynamically.
1. Describing Use Cases: They are useful for illustrating the flow of control within a use
case, showing how various components of the system interact during its execution.
Activity Diagram Notations
1. Initial State

The starting state before an activity takes place is depicted using the initial state.

A process can have only one initial state unless we are depicting nested activities. We use a
black filled circle to depict the initial state of a system. For objects, this is the state when they
are instantiated. The Initial State from the UML Activity Diagram marks the entry point and
the initial Activity State.

2. Action or Activity State

An activity represents execution of an action on objects or by objects. We represent an


activity using a rectangle with rounded corners. Basically any action or event that takes place
is represented using an activity.

3. Action Flow or Control flows

Action flows or Control flows are also referred to as paths and edges. They are used to show
the transition from one activity state to another activity state.

An activity state can have multiple incoming and outgoing action flows. We use a line with
an arrow head to depict a Control Flow. If there is a constraint to be adhered to while making
the transition it is mentioned on the arrow.

4. Decision node and Branching

When we need to make a decision before deciding the flow of control, we use the decision
node. The outgoing arrows from the decision node can be labelled with conditions or guard
expressions. It always includes two or more output arrows.
5. Guard
A Guard refers to a statement written next to a decision node on an arrow sometimes within
square brackets.

The statement must be true for the control to shift along a particular direction. Guards help us
know the constraints and conditions which determine the flow of a process.

6. Fork

Fork nodes are used to support concurrent activities. When we use a fork node when both the
activities get executed concurrently i.e. no decision is made before splitting the activity into
two parts. Both parts need to be executed in case of a fork statement. We use a rounded solid
rectangular bar to represent a Fork notation with incoming arrow from the parent activity
state and outgoing arrows towards the newly created activities.

7. Join

Join nodes are used to support concurrent activities converging into one. For join notations
we have two or more incoming edges and one outgoing edge.

8. Merge or Merge Event

Scenarios arise when activities which are not being executed concurrently have to be merged.
We use the merge notation for such scenarios. We can merge two or more activities into one
if the control proceeds onto the next activity irrespective of the path chosen.

We use a rectangular column to represent a swimlane as shown in the figure above.

9. Final State or End State


The state which the system reaches when a particular process or activity ends is known as a
Final State or End State. We use a filled circle within a circle notation to represent the final
state in a state machine diagram. A system or a process can have multiple final states.

Conclusion:
Activity diagrams can be used for illustrating the sequence of project tasks. These diagrams
can be created with a minimum effort and gives you a clear understanding of interdependent
tasks. In addition, the activity diagram is an input for the critical path method.

You might also like