OOSAD Chapter 7

Report
Chapter 7:
Conceptual Data Modeling
(Adapted)
Object-Oriented Systems Analysis and
Design
Joey F. George, Dinesh Batra,
Joseph S. Valacich, Jeffrey A. Hoffer
© Prentice Hall, 2004
7-1
Conceptual Data Model

A detailed model that shows the overall
content and structure (relationships) of
organizational data

Independent of any DBMS product or other
implementation considerations.
Chapter 7
© Prentice Hall, 2004
7-2
Chapter 7
© Prentice Hall, 2004
7-3
Conceptual Data Model Elements
Classes
Attributes
Identifiers
Associations (Relationships)
Special Relationships: aggregation, composition
generalizations
Time dimensions
Integrity rules
Security controls
Chapter 7
© Prentice Hall, 2004
7-4
Classes & Objects
Class
Name
List of attributes
List of methods
(processes)
createStudent()
Class
Instances
= Objects
Chapter 7
© Prentice Hall, 2004
7-5
Kinds of Attributes

Simple attributes – contain single data item

Identifiers – unique value per object, key values
(keys): <<PK>>
More 

Multivalued attributes – contain multiple values
simultaneously (e.g., tel. number):
<<multivalued>>
More 

Composite attributes – group of related attributes
(e.g., address)
More 
Chapter 7
© Prentice Hall, 2004
7-6
Primary key is a unique identifier;
no two Student instances will have the same
studentId value.
Multivalued attribute can
contain multiple values; a
student may have several phone
numbers
Chapter 7
© Prentice Hall, 2004
7-7
Composite attributes have multiple sections (subattributes).
They are treated as separate classes in conceptual data models.
Chapter 7
© Prentice Hall, 2004
7-8
Relationships
This relationship indicates that employees work
in departments.
Chapter 7
© Prentice Hall, 2004
7-9
Relationship Degree

The number of classes that participate in a
relationship

Types of degrees:
– Unary – a relationship between objects of the
same class
– Binary – a relationship between objects of two
different classes
– Ternary – a relationship between objects of
three different classes
Chapter 7
© Prentice Hall, 2004
7-10
Binary
Chapter 7
© Prentice Hall, 2004
7-11
• Ternary relationships are simultaneous; mutual dependence of
the classes involved (tight coupling): the Ships class must be related to
Vendor who makes Part that is shipped into Warehouse.
• To track fully parts contained in a shipment, vendor and warehousing
info must be included.
• Ternary relationship cannot be broken down to three binary relationships
between
7-12
Chapter
7 Ships and each of the other classes.
© Prentice Hall, 2004
Multiplicity (Cardinality)

The number of objects that participate in a relationship.
Multiplicity is UML’s name for Cardinality.

Multiplicity question: Each object of one class is associated with how
many objects of the other class?
Minimum Multiplicity vs. Maximum Multiplicity = the minimum
number of objects in a relationship vs. the maximum number of objects
in a relationship
Chapter 7
© Prentice Hall, 2004
7-13
Multiplicity Types
One – to – one
One – to – many
Many – to – many
Look at the maximum multiplicity to determine type.
Often, we just state max. multiplicity.
Relationship types often called after multiplicity types.
Do NOT mix with this relationship degree!
Chapter 7
© Prentice Hall, 2004
7-14
If just one number but two on
the other, the former usually means
both min. and max. multiplicity.
Also used: 0..*
For finite max. multiplicity=3:
0..3
Multiplicity notation is:
Chapter 7
© Prentice Hall, 2004
min..max
7-15
Associative Class

A special purpose class that represents an
association (relationship) between classes
and contains attributes and/or relationships
in its own right

Represented as a class connected to an
association with a dotted line
Chapter 7
© Prentice Hall, 2004
7-16
A Certificate represents a relationship between an
employee and a course, and has an attribute pertaining to
that relationship
Chapter 7
© Prentice Hall, 2004
7-17
Special Relationships
• Part-Whole
One class represents the whole, and the other represents the
part (e.g., Team—Player).
• Generalization
 One class forms a broader category and the

other class is a sub-category (e.g., superclass = Employee,
subclasses = PartTimeEmployee, and FullTimeEmployee).
Inheritance works.
Chapter 7
© Prentice Hall, 2004
7-18

similar documents