2.4 Knowledge Areas in Software Engineering
2.4.2 Software Design
Software design fundamentals
Software design is defined as the process of defining the characteristics of the system or component and its result. This characteristics can be its architecture, components, interface and many others. This process represents, within the software life cycle the activity of analysing of the requirements producing a software internal structure description.
Design can be separated into two main activities: top-level design, where the architectural design is performed, describing the top-level struc-ture, organization and description of it’s components; and the detailed design where it’s component it’s described into more detail to allow the proper construction of that component. The result of this design should be a set of models and/or artefacts that can log the major decisions taken.
There are several principles involved when approaching software design.
Abstraction is a principle where the information is viewed in a very high level, removing specificity from the components leading into the produc-tion, parametrization and specification of the solution. There are several levels of abstraction, and it’s normal that the level of abstractions is re-duced with the evolution of the project. Abstraction can also be divided into the elements it represents: data, procedural and control iteration as many others.
One important principle is the relationship between modules, that can be divided into coupling, the strength of the relationships, and cohesion, how the elements of each module are integrated.
A recommended and often used techniques are decomposition and modu-larization, dividing the problem into smaller independent problems, that can be treated separately and then integrated into a major goal.
Encapsulation is a technique, very related with the object oriented paradigm, in which the internal details of each module or component are isolated, with each module acting like a black box, isolating the detail of each component. It is also often to separate the interface from the the im-plementation of each module, which is related to the previous concept of encapsulating the components and separating what it’s known to the users.
Software design has to correctly capture all the characteristics of the sys-tem, and nothing else. Fulfilling sufficiency, completeness and primitive-ness.
Key issues in software design
Software design addresses many issues in its process, it as to deal with
concurrency issues, related to the efficiency of the execution of processes and how to decompose the system into processes and threads.
All this process, if they run concurrently, have to be synchronized and scheduled which strongly relies on the atomicy of the design.
The data-flow control and the data organization is also crucial to define the design, how to react to different events, according to its characteristics and how to handle them properly
The distribution of the software across the hardware is also an impor-tant task when addressing software design, specially when handling with distributed software, and when related with how the components will com-municate and the decision to the use or the non-use of middle-ware, are decisions that have to be taken in this process.
Interaction and the presentation of the information to the user is also an important task of the process of design software, which information is pertinent for the user to see and for whom is important to be seen. The handling of the information, and for how long will it remain accurate and will be available or other issues when dealing with the process of Software Design.
Software structure and architecture
The software architecture is a description of its components, how they are organized and the relationship between them. With the evolution of software engineering the architectures started to be decomposed, not only by abstraction levels but by the style they reflect of the system that also introduces the notion of architecture families, with a common set of con-straints that each style follow. There are several styles and structures of architectures which can go from distributed systems, interactive systems, adaptable systems among others. The use of architectural styles is rec-ommended for it’s common use nowadays creating an easy understanding of technical constraints for common related platforms, although it should not disregard the specific aspects of the system..
Other standardization commonly used within software engineering are de-sign patterns, which differentiate mainly from the architectural styles by it’s level of abstraction. Design patterns are also called micro-architectural patterns, and they describe common solutions for common problems.
The reuse of software has also to be addressed in the design process and it is an optional approach to the development of a system. There are several families of programs or frameworks, often addressed as packages, that can be used to resolve common problems. The reuse of components is also an option to be addressed in the design process.
Software design quality analysis and evaluation
The quality of a software design is strongly related to the quality of the product delivered, therefore the measure and review of the quality of the software design is a important activity of the design process and the soft-ware qualities (section2.3) can be measured. Obviously some of the soft-ware qualities cannot be asset during the design process, because they have to deal with the execution of the software. All of the qualities should be re-visited after the implementation (the satisfaction of the software qualities in the design process does not imply the satisfaction of it’s implementa-tion).
There are several techniques that can provide an aid to ensure the quality of the software design. Review of the design’s artefacts with formal or in-formal tracing, static analysis or non-executable analysis or more dynamic approaches using simulation and prototyping.
Qualities are often hard to quantify, and therefore to measure quality is not an easy task, but it can help to estimate various aspects of software design. The use of measures to asset the size, quality and structure of the design have been proposed according to the approach chosen to perform the design. When referring to measures there are two main categories, the functional oriented design measures and the object oriented design measures. The fist category approaches design structure by decomposing the design into its functions and computing measures for each function.
The second category uses measures at the level of class, a subcomponent of the design representation (normally a class diagram), internal data.
Software design notations
The use of software design notations are used to built common terms, that can be an aid when understanding the design. There are several software design notations that are based into different levels of design, abstraction and design styles. These notations will not be extent in this document.
For further informations of software design notations please address to the bibliography [17]. The important idea to take from this sub-area is that it is advisable for a software development methodology to have a software design notation or to promote the use of one.
Software design strategies and methods
A software design strategy guides the design process and the method, being more specific defines the use of a notation and a process that have to be carried to produce a design artefact. There are several strategies, that exist when performing the design, and as the previous sub-area it will not be further detailed in this document. The use of design strategies and
methods is a good aid to the design process and a SDM should address the use of one, or to promote it.