Identifying Object Relationships, Attributes, and Methods.

Slides:



Advertisements
Similar presentations
Systems Analysis and Design 8th Edition
Advertisements

System Modelling System modelling helps the analyst to understand the functionality of the system and models are used to communicate with customers. Different.
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System modeling 2.
Lecture 9 Object-Oriented Analysis
©Ian Sommerville 2006Software Engineering, 8th edition. Chapter 8 Slide 1 System models.
7M701 1 Software Engineering Systems Models Sommerville, Ian (2001) Software Engineering, 6 th edition: Chapter 7 (some items)
©Ian Sommerville 2004Software Engineering, 7th edition. Chapter 8 Slide 1 System models September 29, 2008.
Modified from Sommerville’s originalsSoftware Engineering, 7th edition. Chapter 8 Slide 1 System models.
7M822 Software Engineering: System Models 14 September 2009.
Systems Analysis and Design in a Changing World, Tuesday, Feb 27
Systems Analysis and Design in a Changing World, Fifth Edition
Sadegh Aliakbary Sharif University of Technology Fall 2010.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 System models l Abstract descriptions of systems whose requirements are being.
Chapter 4 System Models A description of the various models that can be used to specify software systems.
The Software Development Life Cycle: An Overview Presented by Maxwell Drew and Dan Kaiser Southwest State University Computer Science Program.
System models Abstract descriptions of systems whose requirements are being analysed Abstract descriptions of systems whose requirements are being analysed.
Unified Modeling Language, Version 2.0
Chapter 7 System models.
Object oriented classification Classification is the process of checking to see if an object belongs to a category or a class, is regarded as a basic attribute.
System models l Abstract descriptions of systems whose requirements are being analysed.
Modified by Juan M. Gomez Software Engineering, 6th edition. Chapter 7 Slide 1 Chapter 7 System Models.
CS3773 Software Engineering Lecture 04 UML Class Diagram.
Software Engineering, 8th edition Chapter 8 1 Courtesy: ©Ian Somerville 2006 April 06 th, 2009 Lecture # 13 System models.
Systems Analysis & Design 7 th Edition Chapter 5.
Systems Analysis and Design 8 th Edition Chapter 6 Object Modeling.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 7 Slide 1 Chapter 7 System Models.
Unit-3 Identifying use cases Object Analysis Classification Identifying Object relationships Attributes and Methods.
5 Systems Analysis and Design in a Changing World, Fifth Edition.
Lecture 1: UML Class Diagram September 12, UML Class Diagrams2 What is a Class Diagram? A class diagram describes the types of objects in the system.
Slide 1 Systems Analysis and Design With UML 2.0 An Object-Oriented Approach, Second Edition Chapter 2: Introduction to Object-Oriented Systems Analysis.
Object-Oriented Modeling: Static Models. Object-Oriented Modeling Model the system as interacting objects Model the system as interacting objects Match.
Slide 1 Systems Analysis and Design With UML 2.0 An Object-Oriented Approach, Second Edition Chapter 2: Introduction to Object-Oriented Systems Analysis.
Identifying Object Relationships, Attributes, and Methods
1 Unified Modeling Language, Version 2.0 Chapter 2.
MODULE:VII OBJECT ANALYSIS: CLASSIFICATION
 To explain why the context of a system should be modelled as part of the RE process  To describe behavioural modelling, data modelling and object modelling.
1 SWE Introduction to Software Engineering Lecture 14 – System Modeling.
Identification of Classes. Object Oriented Analysis (OOA) OOA is process by which we identify classes that play role in achieving system goals & requirements.
Basic Characteristics of Object-Oriented Systems
Chapter 5: Structural Modeling
Slide 1 Unified Modeling Language, Version 2.0 Object-Oriented SAD.
Engineering, 7th edition. Chapter 8 Slide 1 System models.
Unit-3 Identifying use cases Object Analysis Classification
Identifying Object Relationships, Attributes and Methods
Unit - 3 OBJECT ORIENTED DESIGN PROCESS AND AXIOMS
Classes and their relationships
Object-Oriented Modeling
Object-oriented and Structured System Models
Business System Development
DATA REQIREMENT ANALYSIS
Chapter 5: Structural Modeling
Systems Analysis and Design With UML 2
UNIT-III object-oriented analysis process
Systems Analysis and Design With UML 2
Abstract descriptions of systems whose requirements are being analysed
OBJECT RELATIONSHIPS, ATTRIBUTES, AND METHODS
Object Oriented Concepts
Advanced Java Programming
Object Oriented Analysis and Design
Domain Class Diagram Chapter 4 Part 2 pp
System models October 5, 2005.
Lec 3: Object-Oriented Data Modeling
Chapter 20 Object-Oriented Analysis and Design
Appendix A Object-Oriented Analysis and Design
Understand and Use Object Oriented Methods
Systems Analysis – ITEC 3155 Modeling System Requirements – Part 2
Object Oriented Analysis and Design
Chapter 5.
Appendix A Object-Oriented Analysis and Design
UML  UML stands for Unified Modeling Language. It is a standard which is mainly used for creating object- oriented, meaningful documentation models for.
Presentation transcript:

Identifying Object Relationships, Attributes, and Methods

Goals Analyzing relationships among classes. Identifying association. Association patterns. Identifying super- and subclass hierarchies.

Introduction Identifying aggregation or a-part-of compositions. Class responsibilities. Identifying attributes and methods by analyzing use cases and other UML diagrams.

Objects contribute to the behavior of the system by collaborating with one another. —Grady Booch

In OO environment, an application is the interactions and relationships among its domain objects. All objects stand in relationship to others, on whom they rely for services and controls.

Objects Relationships Three types of relationships among objects are: – Association. – Super-sub structure (also known as generalization hierarchy). – Aggregation and a-part-of structure.

Associations A reference from one class to another is an association. Basically a dependency between two or more classes is an association. For example, Jackie works for John.

Associations (Con’t) Some associations are implicit or taken from general knowledge.

Guidelines For Identifying Associations Association often appears as a verb in a problem statement and represents relationships between classes. For example a pilot can fly planes.

Guidelines For Identifying Associations (Con’t) Association often corresponds to verb or prepositional phrases such as part of, next to, works for, contained in, etc.

Common Association Patterns Common association patterns include: Location Association: next To, part of, contained in, ingredient of etc. : For example cheddar cheese is an ingredient of the French soup.

Common Association Patterns (Con’t) Communication association—talk to, order to. For example, a customer places an order with an operator person.

Eliminate Unnecessary Associations Implementation association. Defer implementation-specific associations to the design phase. Ternary associations. Ternary or n-ary association is an association among more than two classes

Eliminate Unnecessary Associations (Con’t) Directed actions (derived) associations can be defined in terms of other associations. Since they are redundant you should avoid these types of association.

Eliminate Unnecessary Associations (Con’t) Grandparent of Ken can be defined in terms of the parent association.

Superclass-Subclass Relationships Recall that at the top of the class hierarchy is the most general class, and from it descend all other, more specialized classes. Sub-classes are more specialized versions of their super-classes.

Guidelines For Identifying Super-sub Relationships: Top-down Look for noun phrases composed of various adjectives on class name. Example, Military Aircraft and Civilian Aircraft. Only specialize when the sub classes have significant behavior.

Guidelines For Identifying Super-sub Relationships: Bottom-up Look for classes with similar attributes or methods. Group them by moving the common attributes and methods to super class. Do not force classes to fit a preconceived generalization structure.

Guidelines For Identifying Super-sub Relationships: Reusability Move attributes and methods as high as possible in the hierarchy. At the same time do not create very specialized classes at the top of hierarchy. This balancing act can be achieved through several iterations.

Guidelines For Identifying Super- sub Relationships: Multiple inheritance Avoid excessive use of multiple inheritance. It is also more difficult to understand programs written in multiple inheritance system.

Multiple inheritance (Con’t) One way to achieve the benefits of multiple inheritance is to inherit from the most appropriate class and add an object of other class as an attribute. In essence, a multiple inheritance can be represented as an aggregation of a single inheritance and aggregation. This meta model reflects this situation. Multiple Inheritance Single InheritanceAggregation

A-Part-of Relationship - Aggregation A-part-of relationship, also called aggregation, represents the situation where a class consists of several component classes.