[go: up one dir, main page]

0% found this document useful (0 votes)
14 views28 pages

Chapter 5_Design Concepts

Chapter 5 discusses software quality and design concepts, emphasizing the importance of attributes like availability, interoperability, performance, testability, security, usability, and functionality. It outlines various software design approaches, including structured programming and object-oriented design, and introduces key principles such as modularity, abstraction, and separation of concerns. The chapter also covers design patterns and the evolution of software design, highlighting the significance of creating a well-structured and maintainable software system.

Uploaded by

ashwini biradar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
14 views28 pages

Chapter 5_Design Concepts

Chapter 5 discusses software quality and design concepts, emphasizing the importance of attributes like availability, interoperability, performance, testability, security, usability, and functionality. It outlines various software design approaches, including structured programming and object-oriented design, and introduces key principles such as modularity, abstraction, and separation of concerns. The chapter also covers design patterns and the evolution of software design, highlighting the significance of creating a well-structured and maintainable software system.

Uploaded by

ashwini biradar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 28

Chapter 5 Design Concepts

By
Mrs. Bharati A.Patil
 Software Quality: Software quality is defined as a field of study and practice that describes the
desirable attributes of software products. There are two main approaches to software quality: defect
management and quality attributes. Quality can be defined in a different manner. The quality definition
may differ from person to person.
 Software quality guidelines:
 A design of the software must be modular i.e the software must be logically partitioned into
elements. In design, the representation of data , architecture, interface and components should be
distinct. A design must carry appropriate data structure and recognizable data patterns.
 Software Quality Attributes:
 Availability
 This attribute is indicative as to whether an application will execute the tasks it is assigned to perform.
Availability also includes certain concepts that relate to software security, performance, integrity, reliability,
dependability, and confidentiality. In addition, top-notch availability indicates that a software-driven system
will repair any operating faults so that service outage periods would not exceed a specific time value.
 Interoperability
 Software-driven systems could be required to communicate and act in tandem to solve certain tasks.
Interoperability describes the ability of two systems to engage in the exchange of information via certain
interfaces. Therefore, Software Quality Assurance engineers must examine the interoperability attribute in
terms of both syntactic and semantic interoperability.
Continue..
 Performance
 This attribute pertains to the ability of a software-driven system to conform to timing requirements. From a
testing point of view, it implies that Software Testing engineers must check whether the system responds to
various events within defined time limits. These events may occur in the form of clock events, process
interruptions, messages, and requests from different users, and others.
 Testability
 Software testability indicates how well a software-driven system allows Software Testing professionals to
conduct tests in line with predefined criteria. This attribute also assesses the ease with which Software
Quality Assurance engineers can develop test criteria for a said system and its various components. Engineers
can assess the testability of a system by using various techniques such as encapsulation, interfaces, patterns,
low coupling, and more.
 Security
 This attribute measures the ability of a system to arrest and block malicious or unauthorized actions that
could potentially destroy the system. The attribute assumes importance because security denotes the ability of
the system to protect data and defend information from unauthorized access. Security also includes
authorization and authentication techniques, protection against network attacks, data encryption, and such
other risks. It is imperative for Software Testing professionals to regularly conduct updated security checks
on systems.
Continue..
 Usability
 Every software-driven system is designed for ease of use to accomplish certain tasks. The attribute of
usability denotes the ease with which users are able to execute tasks on the system; it also indicates the kind
of user support provided by the system. The most well-known principle for this property is KISS (Keep It
Simple Stupid). In addition, Software Quality Assurance engineers must test software to check whether it
supports different accessibility types of control for people with disabilities. Usability has a critical and long
standing bearing on the commercial fortunes of a software application or package.
 Functionality
 This attribute determines the conformity of a software-driven system with actual requirements and
specifications. Most Software Testing professionals view this attribute as crucial and a foremost requirement
of a modern application, and would therefore advocate the performance of tests that assess the desired
functionality of a system in the initial stages of Software Testing initiatives.
Evolution of Software Design
Structural programming approach

Object Oriented approach

Design Patterns
Continue..
 Structured Programming Approach, can be defined as a programming approach in which the program is made as a
single structure. It means that the code will execute the instruction by instruction one after the other. It doesn’t support
the possibility of jumping from one instruction to some other with the help of any statement like GOTO, etc.
Therefore, the instructions in this approach will be executed in a serial and structured manner. The languages that
support Structured programming approach are:
 C
 C++
 Java
 C#
 Design Pattern:
 Design patterns represent the best practices used by experienced object-oriented software developers. Design
patterns are solutions to general problems that software developers faced during software development.
Types of Design Pattern:Singleton object, Factory Method, Object pool.
Continue..
 Singleton pattern: The singleton pattern is one of the simplest design patterns. Sometimes we need to have only one
instance of our class for example a single DB connection shared by multiple objects as creating a separate DB
connection for every object may be costly. Similarly, there can be a single configuration manager or error manager in an
application that handles all problems instead of creating multiple managers.
 Factory Method Pattern: A Factory Pattern or Factory Method Pattern says that just define an interface or
abstract class for creating an object but let the subclasses decide which class to instantiate. In other words,
subclasses are responsible to create the instance of the class.
 Object pool pattern: The object pool pattern is a software creational design pattern that uses a set of
initialized objects kept ready to use – a "pool" – rather than allocating and destroying them on demand. A client
of the pool will request an object from the pool and perform operations on the returned object. When the client
has finished, it returns the object to the pool rather than destroying it; this can be done manually or
automatically.
Software Design is the process to transform the user requirements into some suitable form, which helps the
programmer in software coding and implementation. During the software design phase, the design document is
produced, based on the customer requirements as documented in the SRS document. Hence the aim of this phase
is to transform the SRS document into the design document.
The following items are designed and documented during the design phase:
•Different modules required.
•Control relationships among modules.
•Interface among different modules.
•Data structure among the different modules.
•Algorithms required to implement among the individual modules.
Continue..
 Objectives of Software Design:
1. Correctness:
A good design should be correct i.e. it should correctly implement all the functionalities of the system.
2. Efficiency:
A good software design should address the resources, time and cost optimization issues.
3. Understandability:
A good design should be easily understandable, for which it should be modular and all the modules are
arranged in layers.
4. Completeness:
The design should have all the components like data structures, modules, and external interfaces, etc.
5. Maintainability:
A good software design should be easily amenable to change whenever a change request is made from the
customer side.
Continue..
 Software Design Concepts:
Concepts are defined as a principal idea or invention that comes in our mind or in thought to understand
something. The software design concept simply means the idea or principle behind the design. It describes how
you plan to solve the problem of designing software, the logic, or thinking behind how you will design software. It
allows the software engineer to create the model of the system or software or product that is to be developed or
built. The software design concept provides a supporting and essential structure or model for developing the right
software. There are many concepts of software design and some of them are given below:
Continue..
1. Abstraction- hide relevant data
Abstraction simply means to hide the details to reduce complexity and increases efficiency or quality.
Different levels of Abstraction are necessary and must be applied at each stage of the design process so that
any error that is present can be removed to increase the efficiency of the software solution and to refine the
software solution. The solution should be described in broadways that cover a wide range of different things
at a higher level of abstraction and a more detailed description of a solution of software should be given at
the lower level of abstraction.
2. Modularity- subdivide the system
Modularity simply means to divide the system or project into smaller parts to reduce the complexity of the
system or project. In the same way, modularity in design means to subdivide a system into smaller parts so
that these parts can be created independently and then use these parts in different systems to perform different
functions. It is necessary to divide the software into components known as modules because nowadays there
are different software available like Monolithic software that is hard to grasp for software engineers. So,
modularity is design has now become a trend and is also important.
3. Architecture- design a structure of something
Architecture simply means a technique to design a structure of something. Architecture in designing software
is a concept that focuses on various elements and the data of the structure. These components interact with
each other and use the data of the structure in architecture.
Continue..
4.Refinement- removes impurities
Refinement simply means to refine something to remove any impurities if present and increase the quality.
The refinement concept of software design is actually a process of developing or presenting the software or
system in a detailed manner that means to elaborate a system or software. Refinement is very necessary to
find out any error if present and then to reduce it.
5.Pattern- a repeated form
The pattern simply means a repeated form or design in which the same shape is repeated several times to
form a pattern. The pattern in the design process means the repetition of a solution to a common recurring
problem within a certain context.
6.Information Hiding- hide the information
Information hiding simply means to hide the information so that it cannot be accessed by an unwanted party.
In software design, information hiding is achieved by designing the modules in a manner that the information
gathered or contained in one module is hidden and it cant be accessed by any other modules.
7.Refactoring- reconstruct something
Refactoring simply means to reconstruct something in such a way that it does not affect the behavior or any
other features. Refactoring in software design means to reconstruct the design to reduce and complexity and
simplify it without affecting the behavior or its functions. Fowler has defined refactoring as “the process of
changing a software system in a way that it won’t affect the behavior of the design and improves the internal
structure”.
Separation of Concerns
 The most important principle in Software Engineering is the Separation of Concerns (SoC): The idea that a
software system must be decomposed into parts that overlap in functionality as little as possible. It is so
central that it appears in many different forms in the evolution of all methodologies, programming languages
and best practices.
 Separation of concerns is a design concept, that suggest any complex problem can be more easily handled if
it is subdivided into pieces that can each be solved and/or optimizes independently.
 A concern is a feature or behaviour that is specified as a part of the requirement model for the software. By
separating concerns into smaller, and therefore more manageable pieces, a problem takes less effort and time
to solve.
 Separation of concerns is manifested(Markesd/visible) in other related design concepts:
 Modularity.
 Aspects
 Functional independence
 Refinement
Information Hiding
 The concept of modularity leads you to a fundamental question: “How do I decompose a software solution to
obtain the best set of modules?”
 The principle of information hiding [Par72] suggests that modules be “characterized by design decisions that
(each) hides from all others.” In other words, modules should be specified and designed so that information
(algorithms and data) contained within a module is inaccessible to other modules that have no need for such
information.
 Hiding implies that effective modularity can be achieved by defining a set of independent modules that
communicate with one another only that information necessary to achieve software function.
 The use of information hiding as a design criterion for modular systems provides the greatest benefits when
modifications are required during testing and later during software maintenance. Because most data and
procedural detail are hidden from other parts of the software.
 Modules must be specified and designed so that the information like algorithm and data presented in a
module is not accessible for other modules not requiring that information.
Functional independence
 Functional independence: The functional independence is the concept of separation and related to the
concept of modularity, accessed using abstraction and information hiding.
 The functional independence is two criteria i.e Cohesion and coupling.
 Cohesion: Cohesion is an extension of the information hiding concept.
 A cohesive module performs a single task and it requires a small interaction with the other components in
other parts of the program.
 Coupling:
Coupling is an indication of interconnection between modules in a structure of software.
Continue..
Aspects(Features/phases)
• A representation of a cross-cutting concern that must be accommodated as refinement and modularization occur.
• For example : (Module A cross cut Module B means B cannot be satisfied without considering A).
• We group the requirements into modules based on the coupling and cohesion characteristics.Eg.Consider a
software like an Online shopping web application.
• In this application some of the requirements are browse through items, create a shopping cart, billing and payment,
track the order.eg.
• We browse some items, doesn’t need the user to authenticate himself/herself through some authentication
mechanism. but other requirements like billing, and track order needs to authenticate the user before doing these
processes.
• hence the requirements to authenticate the user is a part of multiple concerns like billing, tracking etc.hence it is a
generic concern that crosscut across the other concerns like billing and tracking. Hence when a requirement is part
of multiple other concerns, it becomes a crosscutting concern. this is called Aspect.
Object Oriented Design Concepts
 Object
 Object is an entity that has state and behavior. It may be physical and logical. For example: mouse, keyboard,
chair, table, pen etc.
 Class
 Class can be defined as a collection of objects. It is a logical entity that has some specific attributes and methods.
For example: if you have a student class then it should contain an attribute and method i.e. an email id, name, age,
roll number etc. class student
 Method
 Method is a function that is associated with an object.
 Inheritance
 Inheritance specifies that one object acquires all the properties and behaviors of parent object. By using
inheritance we can define a new class with a little or no changes to the existing class. The new class is
known as derived class or child class and from which it inherits the properties is called base class or parent
class. It provides re-usability of the code.
Continue..
 Polymorphism
 Polymorphism defines that one task can be performed in different ways. For example: We have a
class animal and all animals talk. But they talk differently. Here, the "talk" behavior totally
depends on the animal. So, the abstract "animal" does not actually "talk", but specific animals
have a concrete implementation of the action "talk“.
 Encapsulation
 Encapsulation is used to restrict access to methods and variables. In encapsulation, code and data
are wrapped together within a single unit from being modified by accident.
 Data Abstraction
 Data abstraction and encapsulation are synonymous as data abstraction is achieved through
encapsulation.
 Abstraction is used to hide internal details and show only functionalities. Abstracting something
means to give names to things, so that the name captures the basic idea of what a function or a
whole program does.
Different levels of Software Design
 Different levels of Software Design:
There are three different levels of software design. They are:
1. Architectural Design:
The architecture of a system can be viewed as the overall structure of the system & the way in which
structure provides conceptual integrity of the system. The architectural design identifies the software as a
system with many components interacting with each other. At this level, the designers get the idea of the
proposed solution domain.
2. Preliminary or high-level design:
Here the problem is decomposed into a set of modules, the control relationship among various modules
identified and also the interfaces among various modules are identified. The outcome of this stage is called
the program architecture. Design representation techniques used in this stage are structure chart and UML.
3. Detailed design:
Once the high level design is complete, detailed design is undertaken. In detailed design, each module is
examined carefully to design the data structure and algorithms. The stage outcome is documented in the form
of a module specification document.
Design Classes
• Object Oriented is a popular design approach for analyzing and designing an application.
• Most of the languages like C++, Java, .net are use object oriented design concept.
• Object-oriented concepts are used in the design methods such as classes, objects, polymorphism, encapsulation,
inheritance, dynamic binding, information hiding, interface, constructor, destructor.
• The main advantage of object oriented design is that improving the software development and maintainability.
• Another advantage is that faster and low cost development, and creates a high quality software.
• The disadvantage of the object-oriented design is that larger program size and it is not suitable for all types of
program.
 Design classes
• A set of design classes refined the analysis class by providing design details.
Continue..
 There are five different types of design classes and each type represents the layer of the design architecture
these are as follows:
1. User interface classes These classes are designed for Human Computer Interaction(HCI).
 These interface classes define all abstraction which is required for Human Computer Interaction(HCI).
 2. Business domain classes These classes are commonly refinements of the analysis classes.
 These classes are recognized as attributes and methods which are required to implement the elements of the
business domain.
 3. Process classes
It implement the lower level business abstraction which is needed to completely manage the business domain
class.
4. Persistence classes
It shows data stores that will persist behind the execution of the software.
5. System Classes
System classes implement software management and control functions that allow to operate and communicate in
computing environment and outside world.
Design class characteristic
 1.Complete and sufficient
A design class must be the total encapsulation of all attributes and methods which are required to exist
for the class.
2. Primitiveness: The method in the design class should fulfil one service for the class.
 If service is implemented with a method then the class should not provide another way to fulfil same
thing.
 3. High cohesion: A cohesion design class has a small and focused set of responsibilities.
 For implementing the set of responsibilities the design classes are applied single-mindedly to the
methods and attribute.
 4. Low-coupling :All the design classes should collaborate with each other in a design model.
 The minimum acceptable of collaboration must be kept in this model.
 If a design model is highly coupled then the system is difficult to implement, to test and to maintain
over time.
Dependency Inversion
 The general idea of this principle is as simple as it is important: High-level modules, which provide complex
logic, should be easily reusable and unaffected by changes in low-level modules, which provide utility features. To
achieve that, you need to introduce an abstraction that decouples the high-level and low-level modules from each
other.
 Based on this idea, Robert C. Martin’s definition of the Dependency Inversion Principle consists of two parts:
 High-level modules should not depend on low-level modules. Both should depend on abstractions.
 Abstractions should not depend on details. Details should depend on abstractions.
 An important detail of this definition is, that high-level and low-level modules depend on the abstraction. The
design principle does not just change the direction of the dependency, as you might have expected when you read
its name for the first time. It splits the dependency between the high-level and low-level modules by introducing
an abstraction between them. So in the end, you get two dependencies:
 the high-level module depends on the abstraction, and
 the low-level depends on the same abstraction.
Design Model
 1.Data design elements: The data design element produced a model of data that represent a high level of
abstraction.
 This model is then more refined into more implementation specific representation which is processed by the
computer based system.
 The structure of data is the most important part of the software design.
 2. Architectural design elements: The architecture design elements provides us overall view of the system.
 The architectural design element is generally represented as a set of interconnected subsystem that are derived
from analysis packages in the requirement model.
 The architecture model is derived from following sources: The information about the application domain to
built the software.
 Requirement model elements like data flow diagram or analysis classes, relationship and collaboration between
them.
 The architectural style and pattern as per availability.
 3. Interface design elements: The interface design elements for software represents the information flow within it
and out of the system.
 They communicate between the components defined as part of architecture.
Continue..
 Following are the important elements of the interface design:
1. The user interface
2. The external interface to the other systems, networks etc.
3. The internal interface between various components.

4. Component level diagram elements: The component level design for software is similar to the set of
detailed specification of each room in a house.
 The component level design for the software completely describes the internal details of the each software
component.
 The processing of data structure occurs in a component and an interface which allows all the component
operations.
 In a context of object-oriented software engineering, a component shown in a UML diagram.
 The UML diagram is used to represent the processing logic.
Continue..
 Deployment level design elementsThe deployment level design element shows the software functionality
and subsystem that allocated in the physical computing environment which support the software.
 Following figure shows three computing environment as shown. These are the personal computer, the CPI
server and the Control panel.
Thank
Yo

You might also like