3. GuidanceNPR 7150.2 describes the software detail design activity, which is preliminary at project Preliminary Design Review (PDR) and baselined at Critical Design Review (CDR) (topic 7.08 - Maturity of Life Cycle Products at Milestone Reviews), as occurring after the completion of the software architectural design process. This, in turn, is the "process of defining the architecture, components, modules, interfaces, and data" of a system or component. The software work product detailed design, which flows out of the software architectural definition (see SWE-057 - Software Architecture), and the preliminary design phase, is focused on defining the lower-level components, modules, and interfaces, and bringing them to a level of maturity sufficient to begin coding activities. 3.1 Design ReadinessA review of the success criteria for Preliminary Design Reviews (PDRs) (see 7.09 - Entrance and Exit Criteria) by the software development team will assure the readiness to proceed to the detailed design phase. The software development team then decides which criteria are necessary for the project. An example checklist for determining readiness to begin software detailed design activities is shown below. It suggests "readiness" questions the software team leader can ask before starting and continuing into and during the detailed design activity. This checklist also assists the leader in understanding the software design issues of the project. If the leader cannot answer a question affirmatively, the project leader must determine whether or not they are ready to proceed. Consider the following before starting the detailed design: Consider the following during detailed design: See also PAT-014 - Architecture Design Checklist, PAT-015 - Detailed Design Checklist, PAT-031 - Critical Design Analysis Checklist, 3.2 Coding Standards and ProcessesThe design activity proceeds from the software architectural definition (see SWE-057 - Software Architecture). The key decomposition and dependency features and the design/coding standards specified or begun during the development of the software architecture are then maintained and/or completed during the design phase of the software development life cycle. The software development team reviews and maintains the selected coding standards (see SWE-061 - Coding Standards) that were established for all the languages being used, documented, or referenced in the project's software documentation. The initial steps in developing the software detailed design involve the definition of functions, inputs, and outputs for each component.  In some projects that employ component-based development, the components may be pre-existing and fixed, or customizable in only a limited way. The design focus then lies in integrating existing components to form new systems.  The software development team can describe the design by using a programming design language or by using pseudocode. Consideration can be given to the reuse of software for all or some major components, such as: - Application generators.
- Database management systems.
- Human-computer interaction utilities.
- Mathematical utilities.
- Graphical utilities.
- Library modules.
- Library modules with shells built to standardize interfaces (e.g., for error handling) and enhance portability.
Once the final functions are determined, they are coded into the selected programming language. Although the decomposition activities nominally occur during the software architecting activities, the software development team must revisit the architecture if one or more of the decomposition criteria will not be satisfied in the proposed detailed design: - Will the module have too many statements?
- Will the module be too complex?
- Does the module have low "cohesion" (a measure of how strongly related each piece of functionality expressed by the source code of a software module is)?
- Does the module have high "coupling" (the degree to which each program module relies on each other in the other modules)?
- Does the module contain similar processing to other modules?
See also SWE-207 - Secure Coding Practices, 3.3 Design ConsiderationsA best practice is to use modularity in the design, with minimal coupling between components and maximum cohesion within each component. Modular designs are more understandable, reusable, and maintainable than designs consisting of components with complicated interfaces and poorly matched groupings of functions. Each level of design is best described by including only the essential aspects and omitting the inessential detail. This means the design description includes the appropriate degree of "abstraction" (Abstraction captures and represents only those details about an object that is relevant to the current perspective). This enhances understandability, adaptability, and maintainability. Component-based software engineering emphasizes the use of software components with distinct functionality that overlap as little as possible. This is a reuse-based approach for developing software for defining, implementing, and joining independent components into systems. Wikipedia is a good source for top-level information on this approach. The last step of detailed design (some may also say this is the first step of the coding phase) includes the initial steps for coding the process modules in preparation for unit testing. This transition from detailed design to the coding and test phase of the software life cycle occurs when the team begins to compile the developed work products into the programming language (see SWE-060 - Coding Software and SWE-061 - Coding Standards). See also SWE-157 - Protect Against Unauthorized Access, SWE-185 - Secure Coding Standards Verification, 3.4 Detailed Design Documentation and Progress ReviewsAs a part of this requirement, the software development team must record descriptions of the design down to the lower-level units. The main records or outputs of the detailed design phase are captured in the following set of project documents and work products: When documenting elements of the detailed design include information such as - Identifier and types.
- Purpose and function.
- Constraints.
- Subordinates and dependencies.
- Interfaces.
- Resources.
- Processing characteristics and special needs, if any (e.g., required timing or special conditions necessary to execute).
- Other enabling data (e.g., products from the use of Universal Modeling Language (UML) or a tool such as Rhapsody).
Progress against plans is monitored by project management and documented at regular intervals in progress reports. Developers verify detailed designs in design reviews, level by level. Peer reviews and inspections of the software design before coding begins are used to eliminate design errors before conducting testing. See the guidance (SWE-087 - Software Peer Reviews and Inspections for Requirements, Plans, Design, Code, and Test Procedures) related to software peer reviews and inspection of design items. See also Topic 7.10 - Peer Review and Inspections Including Checklists Two variations of software/peer reviews/inspections are useful: - Design inspection.
- Scenario-based analyses.
In a design inspection, the software development team traces the logic of a module from beginning to end. In scenario-based analyses, component behavior is examined for responses due to specific inputs. 3.5 Design MaintenanceOnce these detailed designs are created, they are maintained to reflect the current project status, progress, and plans, which will change over the life of the project. If requirements changes occur, or if the design approach proves faulty, the software architecture design may need to be changed before continuing with the detailed design of the software work products. When requirements change (SWE-071 - Update Test Plans and Procedures), software designs, test plans, procedures, and the resulting test reports may also need to be updated or revised to reflect the changes. Just as the project team ensures that initial detailed designs and their reports are reviewed and approved before use, the team also ensures that updates are also reviewed and approved in the following project procedures. (See SWE-080 - Track and Evaluate Changes) The software development team must continue to maintain accurate and current software design descriptions throughout the operation and maintenance phases of a project. The Software Architecture Review Board , a software engineering sub-community of practice, is a good resource of software design information including sample documents, reference documents, and expert contacts. 3.6 Additional Guidance Additional guidance related to this requirement may be found in the following materials in this Handbook: 3.7 Center Process Asset Libraries
See the following link(s) in SPAN for process assets from contributing Centers (NASA Only). |