Design Concepts and Principles
Design Concepts and Principles
Design Concepts and Principles
Data interface
Dictionary design
architectural
design
STD
data
design
CSPEC
modelling
Prototype
Spec
Design
Design Principles [Dav95]
The design process should not suffer from
‘tunnel vision.’
The design should be traceable to the analysis
model.
The design should not reinvent the wheel.
The design should “minimize the intellectual
distance” between the software and the
problem as it exists in the real world.
The design should exhibit uniformity and
integration.
Design Principles [Dav95]
The design should be structured to
accommodate change.
The design should be structured to degrade
gently, even when aberrant data, events, or
operating conditions are encountered.
Design is not coding, coding is not design.
The design should be assessed for quality as it
is being created, not after the fact.
The design should be reviewed to minimize
conceptual (semantic) errors.
Fundamental Concepts
abstraction—data, procedure, control
refinement—elaboration of detail for all abstractions
modularity—compartmentalization of data and function
architecture—overall structure of the software
Structural properties
Extra-structural properties
Styles and patterns
procedure—the algorithms that achieve function
hiding—controlled interfaces
Data Abstraction
door
manufacturer
model number
type
swing direction
inserts
lights
type
number
weight
opening mechanism
details of enter
algorithm
walk to door;
reach for knob;
cost of
software
module
integration
cost
clients "secret"
Data-centered architectures
Data flow architectures
Call and return architectures
Object-oriented architectures
Layered architectures
Data-Centered Architecture
Client Client
software software
Client Client
software software
Data store
(repository or
blackboard)
Client
Client software
software
Client Client
software software
Data Flow Architecture
pipes filter filter
filter
application layer
utility layer
core layer
Analyzing Architectural Design
1. Collect scenarios.
2. Elicit requirements, constraints, and environment
description.
3. Describe the architectural styles/patterns that have
been chosen to address the scenarios and
requirements: module, process and data flow views
4. Evaluate quality attributes by considered each
attribute in isolation.
5. Identify the sensitivity of quality attributes to various
architectural attributes for a specific architectural
style.
6. Critique candidate architectures (developed in step 3)
using the sensitivity analysis conducted in step 5.
An Architectural Design
Method
customer requirements
"four bedrooms, three baths,
lots of glass ..."
architectural design
Deriving Program Architecture
Program
Architecture
Partitioning the Architecture
“horizontal” and “vertical”
partitioning are required
Horizontal Partitioning
define separate branches of the module
hierarchy for each major function
use control modules to coordinate
communication between functions
function 1 function 3
function 2
Vertical Partitioning: Factoring
design so that decision making and
work are stratified
decision making modules should reside
at the top of the architecture
decision-makers
workers
Why Partitioned Architecture?
results
results in
in software
software that
that isis easier
easier to
to test
test
leads
leads to
to software
software that
that isis easier
easier to
to maintain
maintain
results
results in
in propagation
propagation of of fewer
fewer side
side effects
effects
results
results in
in software
software that
that isis easier
easier to
to extend
extend
Structured Design
objective:
objective: to
to derive
derive aa program
program
architecture
architecture that
that is
is partitioned
partitioned
approach:
approach:
the
the DFD
DFD isis mapped
mapped into
into aa program
program
architecture
architecture
the PSPEC and STD are used to indicate
the PSPEC and STD are used to indicate
the
the content
content ofof each
each module
module
notation:
notation: structure
structure chart
chart
Flow Characteristics
Transform flow
transaction
action paths
transaction centre
Transaction
flow
General Mapping Approach
isolate incoming and outgoing flow
boundaries; for transaction flows, isolate
the transaction center
b g h
a e f
d
c i
j
data flow model
x1 "Transform" mapping
x2 x3 x4
b c d e f g i
a h j
Factoring
direction of increasing
decision making typical "decision
making" modules
B A
A
B
C
action path
T
Transaction Example
fixture setting fixture
servos
commands
operator process
operator
report display
commands screen
robot control
robot
control
software
assembly
record
in reality, other
commands
would also be shown
Refining the Analysis Model
1. write an English language processing narrative
for the level 01 flow model
determine
command select report
type
generate report
control report display
robot screen
send
control
assembly
value robot
record
control
system
robot control
Level 2 Data Flow Diagram
command error msg
produce
error
msg
status format
read command setting fixture setting
command determine
invalid command setting
validate read raw setting
command fixture
status combined
determine status
type
assembly
record
start /stop
Transaction Mapping Principles
isolate the incoming flow path
a x2 x3 x4
d e f g h x3.1 l m n
i j
k
Isolate Flow Paths
command error msg
produce
error
msg
status format
read command setting fixture setting
command invalid command determine
setting
validate read raw setting
command fixture
status combined
determine status
type
assembly
record
start /stop
Map the Flow Model
process
operator
commands
command determine
input type
controller
command determine
input type
controller
build
prototype #1
interface
build
prototype # n
interface
user
evaluate's
interface
design
modifications
are made
evaluation
is studied by
designer
Interface design
is complete