Database Reference
In-Depth Information
observe these types of objects. Two main reasons warrant the indication of gener-
alization and specialization in a data model:
Although each subtype object may share most of its attributes with all the other
subtypes, certain attributes may apply only to that subtype.
Only the instances of certain subtype objects may participate in some rela-
tionships.
In practice, how do you note these special object types while modeling the infor-
mation requirements? You may adopt the top-down or the bottom-up approach.
You may look at several objects and realize that these may be subtypes of some
supertype object. Conversely, you may examine an object and find that it would
break down into subtype objects. Let us summarize these two routes:
Generalization. Create object boxes for every possible type of business object.
Examine objects and see whether some of these may be subtypes of some other
object. Suppress the differences between the subtypes, identify the common attrib-
utes, and generalize to define the supertype object.
Specialization. Create object boxes for only the high-level business objects. That is,
ignore any possible variations in the set of attributes for instances within each high-
level object. In the case of the medical center, first you would come up with the
PATIENT object. Then examine the instances within the object and note the dif-
ferences in the sets of attributes for the instances. Separate out the instances that
possess the same set of instances as a special subtype object for PATIENT.
Supersets and Subsets
Object sets that are supertypes are also known as supersets; similarly, subtype object
sets are also called subsets. Figure 6-17 presents a few examples of supersets and
subsets.
Note each superset and the corresponding subsets. Taking any particular
example, while modeling the information requirements you could model by the
generalization method from the subsets or by the specialization method from the
superset.
Generalization Hierarchy
Refer back to Figure 6-16 showing the subsets and the superset representing
patients in a medical center. As certain attributes for a subset are derived from the
superset, the superset and its subsets form a hierarchy in the arrangement of these
objects in a data model. The hierarchical, top-down arrangement with the superset
object box above the subset boxes gives an indication of how the superset provides
the attributes common to the subsets in real-world situations.
Figure 6-16 shows two levels of the hierarchy, PATIENT at the higher level
and the other three objects one level down. Sometimes, you will come across more
Search WWH ::




Custom Search