Page 151 -
P. 151
134 Chapter 5 System modeling
Data-flow diagrams
Data-flow diagrams (DFDs) are system models that show a functional perspective where each transformation
represents a single function or process. DFDs are used to show how data flows through a sequence of processing
steps. For example, a processing step could be the filtering of duplicate records in a customer database. The data
is transformed at each step before moving on to the next stage. These processing steps or transformations
represent software processes or functions where data-flow diagrams are used to document a software design.
http://www.SoftwareEngineering-9.com/Web/DFDs
Many business systems are data processing systems that are primarily driven by
data. They are controlled by the data input to the system with relatively little external
event processing. Their processing involves a sequence of actions on that data and the
generation of an output. For example, a phone billing system will accept information
about calls made by a customer, calculate the costs of these calls, and generate a bill
to be sent to that customer. By contrast, real-time systems are often event driven with
minimal data processing. For example, a landline phone switching system responds to
events such as ‘receiver off hook’ by generating a dial tone, or the pressing of keys on
a handset by capturing the phone number, etc.
5.4.1 Data-driven modeling
Data-driven models show the sequence of actions involved in processing input data
and generating an associated output. They are particularly useful during the analysis
of requirements as they can be used to show end-to-end processing in a system. That
is, they show the entire sequence of actions that take place from an input being
processed to the corresponding output, which is the system’s response.
Data-driven models were amongst the first graphical software models. In the
1970s, structured methods such as DeMarco’s Structured Analysis (DeMarco, 1978)
introduced data-flow diagrams (DFDs) as a way of illustrating the processing steps
in a system. Data-flow models are useful because tracking and documenting how the
data associated with a particular process moves through the system helps analysts
and designers understand what is going on. Data-flow diagrams are simple and intu-
itive and it is usually possible to explain them to potential system users who can then
participate in validating the model.
The UML does not support data-flow diagrams as they were originally proposed and
used for modeling data processing. The reason for this is that DFDs focus on system
functions and do not recognize system objects. However, because data-driven systems
are so common in business, UML 2.0 introduced activity diagrams, which are similar to
data-flow diagrams. For example, Figure 5.14 shows the chain of processing involved in
the insulin pump software. In this diagram, you can see the processing steps (repre-
sented as activities) and the data flowing between these steps (represented as objects).
An alternative way of showing the sequence of processing in a system is to use UML
sequence diagrams. You have seen how these can be used to model interaction but, if