An object is a person, place, thing, concept, or possibly event.
An attribute is a characteristic of an object.
A behavior is an action that an object is capable of performing.
Focusing on objects makes it easy for us to understand complex things. Objects enable us to look at details that are of interest to us and ignore other details that we are not interested in.
Inheritance is a way for one object to receive attributes and behaviors of another object in what programmers call an is a relationship.
Attributes and behaviors need to be defined in one object, such as Person. Other objects that require those attributes and behaviors ”such as Student, Teacher, Department Chair, Dean, Secretary, and Bursar ”can inherit the object. This allows for attributes and behaviors to be defined in only one object, making it easy to add new attributes and behaviors or remove existing attributes and behaviors.
The attributes of the order form in Figure 1-1 are as follows :
Shipping & Handling
The behaviors of the order form in Figure 1-1 are as follows:
Enter order information
Modify order information
Look up order
These are common objects that inherit a Person object:
Board of Trustees
See Figure B-1.
Figure B-1: The relationship between the Person object and objects that are persons