What is design? • It’s where you stand with a foot in two worlds— the world of technology and the world of people and human purposes— and you try to bring the two together.... • Requirements model: provides detail about data, function, and behavior • Design model: provides detail about software architecture, data structures, interfaces, and components that are necessary to implement the system. Maria Hilal, Software Engg - Fall 2022 3 Design Model Pyramid
Maria Hilal, Software Engg - Fall 2022 4
Maria Hilal, Software Engg - Fall 2022 5 Design Concepts 1. Abstraction 2. Architecture 3. Patterns 4. Modularity 5. Information Hiding 6. Functional independence
Maria Hilal, Software Engg - Fall 2022 6
1. Abstractions • Highest level – solution is stated in broad terms – using the language of the problem environment. • Lower levels – more detailed description of the solution – Problem-oriented terminology coupled with implementation-oriented terminology • Lowest level – the solution is stated in a manner that can be directly implemented.
Maria Hilal, Software Engg - Fall 2022 7
Abstractions contd. • Procedural abstraction – specific details of a function is suppressed. – open the door walk to the door, reach out and grasp knob, turn knob and pull door, step away from moving door, etc. • Data abstraction – named collection of data that describes a data object – Door a set of attributes e.g., door type, swing direction, opening mechanism, weight, dimensions • Procedural abstraction open would make use of information contained in the attributes of the data abstraction door.
Maria Hilal, Software Engg - Fall 2022 8
2. Architecture • The structure or organization of program components (modules), the manner in which these components interact, and the structure of data that are used by the components.
Maria Hilal, Software Engg - Fall 2022 9
3. Patterns • The patterns enable you to apply design knowledge to domain-specific problems that have been encountered and solved by others. • Each pattern describes a problem that occurs over and over again in our environment and then describes the core of the solution.
Maria Hilal, Software Engg - Fall 2022 10
4. Modularity • Development can be more easily planned • Software increments can be defined and delivered • Changes can be more easily accommodated • Testing and debugging can be conducted more efficiently • Long-term maintenance can be conducted without serious side effects. Maria Hilal, Software Engg - Fall 2022 11 5. Information Hiding • Modules should be specified and designed so that information (algorithms and data) contained within a module is in-accessible to other modules that have no need for such information.
Maria Hilal, Software Engg - Fall 2022 12
6. Functional independence • Developing modules with “single-minded” function and an “aversion” to excessive interaction with other modules. • Each module addresses a specific set of requirements • Cohesion: functional strength of a module – performs a single task, requiring little interaction with other components in other parts of a program • Coupling is an indication of the relative interdependence among modules. • Strive for the lowest possible coupling Maria Hilal, Software Engg - Fall 2022 13 Quiz-3 • Draw sequence diagram of Sign-in use case. • Draw a class diagram of the library management system. Write assumptions where necessary.
Maria Hilal, Software Engg - Fall 2022 14
References Software Engineering, 9th Edition, Ian Sommerville Software Engineering, a practitioners approach by Roger S. Pressman, 7th Edition