Booch Method

Chapter 4. Classification


Questions List

1. The Importance of Proper Classification

  1. What is the relation between classification and object-oriented development?
  2. Why is classification difficult?

2. Identifying Classes and Objects

  1. What kinds of approaches are there in classification?
  2. How to use the classification approaches to OO design?
  3. What kind of methodologies are there to find classes and objects?

3. Key Abstractions and Mechanisms

  1. What is a key abstraction?
  2. How to find a key abstraction?
  3. What is a mechanism?
  4. How to find a mechanism?


Note:


1. The Importance of Proper Classification

Q1.1: What is the relation between classification and object-oriented development? (Ref: 4.1, p.146, p.167)

The identification of classes and objects is the fundamental issue and the hardest part of object-oriented analysis and design. Classification is fundamentally a problem of finding sameness, which helps to identify generalization, specialization and aggregation hierarchies among classes. Classification also guides us in making decisions about modularization.

The nature of classification is an incremental and iterative process.

Q1.2: Why is classification difficult? (Ref: 4.1, p.150)

There are two important reasons for this:

  1. There is no such thing as a perfect classification, although certainly some classifications are better than others. Any classification is relative to the perspective of the observer doing the classification.
  2. Intelligent classification requires a tremendous amount of creative insight. Sometimes the answer is evident, sometimes it is a matter of taste, and at other times, the selection of suitable components is a crucial point in the analysis.





2. Identifying Classes and Objects

Q2.1: What kinds of approaches are there in classification? (Ref: 4.2, p.150)

Historically, there have only been three general approaches to classification:

  1. Classical categorization
    In this approach, all the entities that have a given property or collection of properties in common form a category. Such properties are necessary and sufficient to define the category. For example, To summarize, this approach uses related properties as the criteria for sameness among object. However, as the second example in the above suggests, this is not always satisfactory.
  2. Conceptual clustering
    This is a more modern variation of the classical approach. In this approach, classes are generated by first formulating conceptual descriptions of these classes and then classifying the entities according to the description. For example, Thus conceptual clustering represents more of a probabilistic clustering of objects.
  3. Prototype theory
    There are still some situations in which the above two approaches are inadequate. This leads us to the more recent approach to classification called prototype theory. In this classification, a class of objects is represented by a prototypical object, and an object is considered to be a member of this class if and only if it resembles this prototype in significant way. For example, In conceptual clustering, we group things according to distinct concepts. In prototype theory, we group things according to the degree of their relationship to concrete prototypes.

Q2.2: How to use the classification approaches to OO design? (Ref: 4.2, p.154)

From practician's view point, the classification approaches in Q2.1 seems to be far removed from reality. However, these approaches have direct application to object-oriented design.

  1. In our experience, we identify classes and objects first according to the properties relevant to our particular domain. Here, we focus upon identifying the structures and behavior that are part of the vocabulary of our problem space. This is the classical categorization approach.
  2. If the above approach fails to yield a satisfactory class structure, then we next consider conceptual clustering. Here, we focus our attention upon the behavior of collaborating objects.
  3. If either of the above approaches fails to capture our understanding of our the problem domain, then we consider classification by association, through which clusters of objects are defined according to how closely each resembles some prototypical object (prototype theory).

Q2.3: What kind of methodologies are there to find classes and objects? (Ref: 4.2, p.155)

Booch defines the object-oriented analysis and design as follows:

There are a number of proven approaches (methodologies) for analysis that are relevant to object-oriented systems.





3. Key Abstractions and Mechanisms

Q3.1: What is a key abstraction? (Ref: 4.3, p.162)

A key abstraction is a class or object that forms part of the vocabulary of the problem domain. The primary value of identifying such abstractions is that they give boundaries to our problem: they highlight the things that are in the system and therefore relevant to our design, and suppress the things that are outside the system and therefore superfluous.

The identification of key abstractions is highly domain-specific. The appropriate choice of objects depends, of course, on the purpose to which the application will be put and the granularity of information to be manipulated.

Q3.2: How to find a key abstraction? (Ref: 4.3, p.162)

The identification of key abstractions involves two processes:

Booch recommend the use of scenarios to drive the processes of identifying classes and objects (key abstractions).

Q3.3: What is a mechanism? (Ref: 4.3, p.164)

A mechanism is a structure whereby objects collaborate to provide some behavior that satisfies a requirement of the problem. Whereas the design of a class embodies the knowledge of how individual objects behave, a mechanism is a design decision about how collections of objects cooperate.

Q3.4: How to find a mechanism? (Ref: 4.3, p.165)

For example, consider a system requirement for an automobile. Pushing the accelerator should cause the engine to run faster, and releasing the accelerator should cause the engine to run slower. How this actually comes about is absolutely immaterial to the driver. Any mechanism may be employed as long as it delivers the required behavior, and thus which mechanism is selected is largely a matter of design choice.