Design process is generally considered a two-step process

  • Architectural design (or, high-level/top-level design)
    how software is organised into components.
  • Detailed design
    the desired behaviour of these components.

Output of these two processes is a set of models and artifacts that record major decisions, and rationale for each. By recording the rationale, long-term maintainability of the software product is enhanced.

Design principles

Abstraction

View of an object that focuses on information relevant to the particular purpose and ignores remainder.
Two key mechanisms:

  • Parameterisation
    Representing data as named parameters.
  • Specification
    procedural, data and control (iteration) abstraction

Coupling and Cohesion

Coupling: measure of interdependence among modules in a program.
Cohesion: measure of the strength of association of elements within a module.

Decomposition and modularisation

Large software is divided into
a number of smaller named components
having well-defined interfaces that
describe component interactions.

Place different functionalities and responsibilities in different components.

Encapsulation and information hiding

Grouping and packaging the internal details of an abstraction.
Making those details inaccessible to external entities.

Seperation of interface and implementation

Defining a component by specifying a public interface that is seperate from detail of how the component is realised.

Sufficiency, completeness and primitiveness

Sufficiency and completeness means esuring that a component captures all the important characteristics of an abstration and nothing more.

Primitiveness means the design is based on patterns that are easy to implement.

Seperation of Concerns

A concern is an area of interested with respect to software design.
A design concern is an area of design that is relevant to one or more of its stakeholders.
Each architecture view frames one or more concerns.

Seperating concerns by views allows interested stakeholders to focus on a few things at a time - a means of managing complexity.