CS212: Object Oriented Analysis and Design GRASP Design Principles.

Slides:



Advertisements
Similar presentations
ARCHITECTURES FOR ARTIFICIAL INTELLIGENCE SYSTEMS
Advertisements

Ch:8 Design Concepts S.W Design should have following quality attribute: Functionality Usability Reliability Performance Supportability (extensibility,
Object-Oriented Analysis and Design CHAPTER 17, 25: GRASP PATTERNS 1.
GRASP Patterns M Taimoor Khan
Feb R. McFadyen1 From the Merriam-Webster’s online dictionary ( Main Entry: an·thro·po·mor·phism Pronunciation: -"fi-z&m Function:
Copyright W. Howden1 Lecture 6: Design Evaluation and Intro to OO Design Patterns.
NJIT More GRASP Patterns Chapter 22 Applying UML and Patterns Craig Larman Prepared By: Krishnendu Banerjee.
February Ron McFadyen1 From the Merriam-Webster’s online dictionary ( Main Entry: an·thro·po·mor·phism Pronunciation: -"fi-z&m.
Low Coupling High Cohesion
GRASP : Designing Objects with Responsibilities
WEL COME PRAVEEN M JIGAJINNI PGT (Computer Science) MCA, MSc[IT], MTech[IT],MPhil (Comp.Sci), PGDCA, ADCA, Dc. Sc. & Engg.
October 20, 2005Architectural Design, ECEN Architectural Design Architecture Business Cycle Design for Maintainability ECEN 5543 / CSCI 5548 SW Eng.
Chapter 22 Object-Oriented Design
Fall 2009ACS-3913 Ron McFadyen1 From the Merriam-Webster’s online dictionary ( Main Entry: an·thro·po·mor·phism Date: 1753 an interpretation.
Object-oriented design CS 345 September 20,2002. Unavoidable Complexity Many software systems are very complex: –Many developers –Ongoing lifespan –Large.
Systems Analysis and Design in a Changing World, Fifth Edition
GENERAL CONCEPTS OF OOPS INTRODUCTION With rapidly changing world and highly competitive and versatile nature of industry, the operations are becoming.
GRASP Pattern Zhen Jiang West Chester University
GRASP Principles. How to Design Objects The hard step: moving from analysis to design How to do it? –Design principles (Larman: “patterns”) – an attempt.
CSCI-383 Object-Oriented Programming & Design Lecture 9.
Ceg860 (Prasad)L6MR1 Modularity Extendibility Reusability.
Chapter 17. GRASP General Responsibility Assignment Software Patterns (Principles) OOD: after identifying requirements, create domain model, define responsiblities.
An Introduction to Design Patterns. Introduction Promote reuse. Use the experiences of software developers. A shared library/lingo used by developers.
SOEN 6011 Software Engineering Processes Section SS Fall 2007 Dr Greg Butler
Architecture GRASP Realization of use cases in interaction diagrams Design class diagram Design ( how )
Requirements To Design--Iteratively Chapter 12 Applying UML and Patterns Craig Larman.
BTS430 Systems Analysis and Design using UML Design Patterns.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 27. Review UML dynamic view – State Diagrams.
CS 325: Software Engineering February 12, 2015 Applying Responsibility-Assignment Patterns Design Patterns Situation-Specific Patterns Responsibility-Assignment.
GRASP: Designing Objects With Responsibilities
Object-Oriented Analysis and Design Mar 11, 2008.
SOEN 343 Software Design Section H Fall 2006 Dr Greg Butler
SOEN 343 Software Design Section H Fall 2006 Dr Greg Butler
Chapter 17 GRASP: Designing Objects with Responsibilities. 1CS6359 Fall 2011 John Cole.
Design Patterns. Patterns “Each pattern describes a problem which occurs over and over again in our environment, and then describes the core of the solution.
COMP 6471 Software Design Methodologies Winter 2006 Dr Greg Butler
GRASP: Designing Objects with Responsibilities
CS212: Object Oriented Analysis and Design Lecture 9: Function Overloading in C++
1 What is OO Design? OO Design is a process of invention, where developers create the abstractions necessary to meet the system’s requirements OO Design.
Introduction to Design Patterns Part 1. © Lethbridge/Laganière 2001 Chapter 6: Using design patterns2 Patterns - Architectural Architectural Patterns:
Elements of OO Abstraction Encapsulation Modularity Hierarchy: Inheritance & Aggregation 4 major/essential elements3 minor/helpful elements Typing Concurrency.
Introducing Allors Applications, Tools & Platform.
1 Class Diagrams. 2 Overview Class diagrams are the most commonly used diagrams in UML. Class diagrams are for visualizing, specifying and documenting.
Object-Oriented Analysis and Design Mar 9, 2008.
Patterns Roberto Damiani Mendes. Roteiro Definition; Definition; Architecture Patterns; Architecture Patterns; Design Patterns; Design Patterns; GRASP.
Com S 362: Object-Oriented Analysis and Design From Design To Code.
SOFTWARE DESIGN AND ARCHITECTURE LECTURE 31. Review Creational Design Patterns – Singleton Pattern – Builder Pattern.
SOEN 343 Software Design Section H Fall 2006 Dr Greg Butler
What’s Ahead for Embedded Software? (Wed) Gilsoo Kim
Copyright © Craig Larman All Rights Reserved COMP-350 Object-Oriented Analysis and Design GRASP: Designing Objects with Responsibilities Reference:
Chapter 17 Designing with Responsibilities. Fig
References: Applying UML and patterns Craig Larman
Design. 2 The Need for Software Blueprints Knowing an object-oriented language and having access to a library is necessary but not sufficient in order.
GRASP: More Patterns for Assigning Responsibilities Presented By Dr. Shazzad Hosain.
Lecture 2 Intro. To Software Engineering and Object-Oriented Programming (2/2)
Basic Characteristics of Object-Oriented Systems
TK2023 Object-Oriented Software Engineering CHAPTER 13d GRASP Patterns: High Cohesion.
GRASP.
TK2023 Object-Oriented Software Engineering
Elaboration: Iteration 2. Elaboration: Iteration 2 Basics Iteration 1 ends with : All the software has been tested: The idea in the UP is to do early,
CS212: Object Oriented Analysis and Design
GRASP – Designing Objects with Responsibilities
Design Patterns: MORE Examples
CHAPTER 5 GENERAL OOP CONCEPTS.
Conception OBJET GRASP Patterns
Apply Expert, Creator, Controller, Low Coupling, High Cohesion
The Object Oriented Approach to Design
GRASP : Designing Objects with Responsibilities
CS223: Software Engineering
SOEN 343 Software Design Computer Science and Software Engineering Department Concordia University Fall 2005 Instructor: Patrice Chalin.
Presentation transcript:

CS212: Object Oriented Analysis and Design GRASP Design Principles

Recap of Lecture 7 Arrays Pointers Pointer to members Dynamic Memory allocation

Outline of lecture 8 Modularity and Typing GRASP Principle Polymorphism Name mangling Overloading

Automated Gardner On a hydroponics farm, plants are grown in a nutrient solution, without sand, gravel, or other soils. Maintaining the proper greenhouse environment is a delicate job and depends on the kind of plant being grown and its age. One must control diverse factors such as temperature, humidity, light, pH, and nutrient concentrations. On a large farm, it is not unusual to have an automated system that constantly monitors and adjusts these elements. Simply stated, the purpose of an automated gardener is to efficiently carry out, with minimal human intervention, growing plans for the healthy production of multiple crops.

Automated Gardner On a hydroponics farm, plants are grown in a nutrient solution, without sand, gravel, or other soils. Maintaining the proper greenhouse environment is a delicate job and depends on the kind of plant being grown and its age. One must control diverse factors such as temperature, humidity, light, pH, and nutrient concentrations. On a large farm, it is not unusual to have an automated system that constantly monitors and adjusts these elements. Simply stated, the purpose of an automated gardener is to efficiently carry out, with minimal human intervention, growing plans for the healthy production of multiple crops.

Automated Gardner On a hydroponics farm, plants are grown in a nutrient solution, without sand, gravel, or other soils. Maintaining the proper greenhouse environment is a delicate job and depends on the kind of plant being grown and its age. One must control diverse factors such as temperature, humidity, light, pH, and nutrient concentrations. On a large farm, it is not unusual to have an automated system that constantly monitors and adjusts these elements. Simply stated, the purpose of an automated gardener is to efficiently carry out, with minimal human intervention, growing plans for the healthy production of multiple crops.

Objects collaborate with other objects to achieve a task How objects cooperate with one another define the boundaries of each abstraction and thus the responsibilities and protocol of each object.

Meaning of Modularity The act of partitioning a program into individual components can reduce its complexity to some degree It creates a number of well-defined, documented boundaries within the program. Classes and objects form the logical structure of a system Abstractions are kept in modules to produce the system’s physical architecture.

Deciding on the right set of modules for a given problem is almost as hard a problem as deciding on the right set of abstractions. Modularity is the property of a system that has been decomposed into a set of cohesive and loosely coupled modules

Object design After identifying the requirements and creating a domain model, then Add methods to the software classes, Define the messaging between the objects to fulfil the requirements But how? What method belongs where? How should the objects interact? This is a critical, important, and non-trivial task

GRASP Patterns/Principles The GRASP patterns are a learning aid Help one understand essential object design Apply design reasoning in a methodical, rational, explainable way. This approach to understanding and using design principles is based on patterns of assigning responsibilities. Not been invented to create new ways of working, but to better existing one

GRASP Name chosen to suggest the importance of grasping fundamental principles to successfully design object-oriented software Acronym: G eneral R esponsibility A ssignment S oftware P atterns Describe fundamental principles of object design and responsibility General principles, may be overruled by others

Nine GRASP Principles Creator Information Expert Low Coupling Controller High Cohesion Polymorphism Indirection Pure Fabrication Protected Variations A non-user interface object Creation of objects Focused, manageable and understandable Change in one class having lower impact on others Model-view-controller pattern Where to delegate responsibilities Variation of behaviors based on type Artificial class, Open-close principle Avoid impact of variations of some element on others

The Meaning of Typing Precise characterization of structural or behavioural properties Express abstractions using the underlying programming language. Strongly, or weakly typed: consistency Static and dynamic typing: timing

Polymorphism Refers to ‘one name having many forms’ ‘Different behaviour of an instance depending upon the situation’. An ‘overloaded function’ refers to a function having (one name and) more than one distinct meanings. Polymorphism in C++ Compile Time Function overloading Operator overloading Runtime Virtual Function Not only does it provide support for compile-time polymorphism, it also adds flexibility and convenience.

Thank you Next Lecture: Function Overloading - II