Data Flow Diagrams: Supplementary Material To Support Bennett, Mcrobb and Farmer

You might also like

Download as ppt, pdf, or txt
Download as ppt, pdf, or txt
You are on page 1of 26

Data Flow Diagrams

Supplementary material to support


Bennett, McRobb and Farmer:
Object Oriented Systems Analysis and
Design Using UML, (4th Edition),
McGraw Hill, 2005.
© 2010 Bennett, McRobb and Farmer 1
In This Presentation You Will Learn:
• What data flow diagrams (DFDs) are
• What DFDs can be used for
• Why DFDs are not used in object-oriented
analysis and design
• Variations in notation for DFDs

© 2010 Bennett, McRobb and Farmer 2


What are DFDs?
• Data flow diagrams (DFDs) are one of the
diagramming techniques used in
structured systems analysis and design
• Data flow diagrams show:
– Data flowing through a system to or from
users (external entities)
– The processes that transform the data
– The data stores that hold the data

© 2010 Bennett, McRobb and Farmer 3


What do DFDs look like?

Client name +
Campaign name 2.4
Campaign
Check
Manager
Campaign
Budget surplus Budget

Budget Cost

Campaigns Adverts

© 2010 Bennett, McRobb and Farmer 4


Elements of DFDs
• External Entities
– People, organizations or systems that the
system being modelled communicates with
– Rather like actors, except an external entity is
not necessarily a direct user of the system
– Typically trigger processes
Campaign
Manager

© 2010 Bennett, McRobb and Farmer 5


Elements of DFDs
• Processes
– Processes that transform data in
some way
– Named and numbered
– Normally require at least one input
and produce at least one output
– Inputs / outputs (I/O) may flow to or 2.4
from other processes, data stores Check
Campaign
or external entities Budget

© 2010 Bennett, McRobb and Farmer 6


Elements of DFDs
• Data Stores
– Represent the places where data is stored
– Typically files or database tables
– In a manual system can represent physical
data stores, like card indexes or filing systems

Campaigns

© 2010 Bennett, McRobb and Farmer 7


Elements of DFDs
• Data Flows
– Flows of data between:
• external entities and processes
• processes and other processes
• processes and data stores
– Can be simple data elements or complex data
structures
Client name +
Campaign name

© 2010 Bennett, McRobb and Farmer 8


Data Dictionaries
• DFDs are supported by data dictionary entries
• Each element is defined in a data dictionary
– Data elements - name and data type
– Data structures - name and composition
– Data flows - name and content
– Data stores - name and data structures contained
– Processes - name and specification of the process,
for example in Structured English

© 2010 Bennett, McRobb and Farmer 9


Levels of DFDs
• Context Diagram
– Shows the system and the external entities
with which it interacts
• Top Level Diagram
– Shows the main processes in the system - a
decomposition of the context diagram process
• Lower Level Diagrams
– Decomposition of the processes in the top
level - can be successively decomposed

© 2010 Bennett, McRobb and Farmer 10


Context Diagram
Staff Assignment Payment
Campaign Accountant
Manager Campaign
Staff
Client
Staff Grade
Agate
Campaign Advert Completion
Staff
Budget Management Contact
Client Contact
System
Advert
Campaign
Staff Concept Note
Concept Note Staff

© 2010 Bennett, McRobb and Farmer 11


Top Level Diagram (Level 0)
Client
Clients Staff
1. 4.
Campaign Accountant
Record Client Staff Maintain
Manager Staff Grade
Clients Staff
Staff Members Payment
Campaign Staff
Staff Advert Completion
Budget 2. Campaigns
Plan and 5. Staff
Manage Campaign Manage Contact
Staff Assignment Contact Adverts Client Contact
Campaigns Cost + Completion Date

Adverts
Advert
Campaign 3.
Prepare Advert Concept
Staff 6. Note
Adverts Browse Staff
Concept Note
Concept Note Concept
Notes
Concept
Notes
Note

© 2010 Bennett, McRobb and Farmer 12


Level 1 Diagram

Staff Members

Client Contact
Staff
5.1
Set Client
Contact
Contact

Adverts
Advert Completion

5.2 Completion Date


Set Advert
Completed

© 2010 Bennett, McRobb and Farmer 13


Data Dictionary
• Advert Completion = Advert Name +
Completion Date
• Advert Name = Name of advert. Format:
X(40)
• Completion Date = Date on which advert
was completed. Format: dd/mm/yyyy.

© 2010 Bennett, McRobb and Farmer 14


Data Dictionary
• Client Contact = Staff ID + Advert Name
• Staff = Staff ID + First Name + Last Name
+ Start Date + Grade + Date Of Birth
• Staff Members = {Staff}
• Contact = Staff ID

© 2010 Bennett, McRobb and Farmer 15


Process Definition
Process 5.1 Set Client Contact
BEGIN
FIND Staff in Staff Members with Staff ID
that matches Staff ID in Client Contact
Contact = Staff ID
Write Contact to Adverts using Advert
Name
END
© 2010 Bennett, McRobb and Farmer 16
Types of DFD
• In some approaches different kinds of
DFD are produced:
– Current physical - existing system with
physical stores, manual processes and
physical descriptions of I/O
– Current logical - abstraction of current
physical to eliminate “the way it’s done now”
– Proposed logical - proposed new system

© 2010 Bennett, McRobb and Farmer 17


What DFDs can be used for
• Modelling existing systems that are to be
re-engineered using an object-oriented
approach
• Modelling data flows in systems that do no
more than transform data
• Modelling business processes in existing
manual systems
• Determining the automation boundary for
a system (what is to be computerized)

© 2010 Bennett, McRobb and Farmer 18


Why DFDs aren’t used in O-O
• In DFDs a clear separation is made
between processes and stored data
• It is assumed that all data is ‘visible’ to any
process that needs to access it
• In an O-O system the processes that
operate on data are the methods of the
classes that contain the data as attributes
• Data is encapsulated within objects, and
may be hidden too

© 2010 Bennett, McRobb and Farmer 19


Variations in Notation
• We have used the notation from Yourdon
(1989) because it is the simplest to draw!
• Alternatives include
– Structured Analysis and Design Technique
(SADT)
– Structured Systems Analysis and Design
Method (SSADM)

© 2010 Bennett, McRobb and Farmer 20


SADT

Client name +
Campaign name 2.4
Campaign
Check
Manager
Campaign
Budget surplus Budget

Budget Cost

Campaigns Adverts

© 2010 Bennett, McRobb and Farmer 21


SSADM

Client name + 2.4


Campaign Campaign name
Manager Check
Campaign
Budget
Budget surplus

Budget Cost

D1 Campaigns D2 Adverts

© 2010 Bennett, McRobb and Farmer 22


SSADM
• SSADM probably has the most complex
notation, which we have not covered here,
including:
– Flows and stores of physical materials
– Notation for duplicate elements appearing in
the same diagram
– Special numbering systems for manual and
transient data stores

© 2010 Bennett, McRobb and Farmer 23


Other Structured Techniques
• In a structured approach, data structures
are usually modelled separately in an
Entity-Relationship Diagram (ERD), but
ERDs don’t show processes
• Entity Life Histories show the events that
affect entities over time
• Structure Diagrams show program
structure as a tree hierarchy of modules

© 2010 Bennett, McRobb and Farmer 24


Summary
In this presentation you have learned about:
• What data flow diagrams (DFDs) are
• What DFDs can be used for
• Why DFDs are not used in object-oriented
analysis and design
• Variations in notation for DFDs

© 2010 Bennett, McRobb and Farmer 25


References
• Yourdon (1989)
• Skidmore, Mills and Farmer (1994)
(For full bibliographic details, see Bennett,
McRobb and Farmer)

© 2010 Bennett, McRobb and Farmer 26

You might also like