In the real world, you often have many objects
of the same kind. For example, your bicycle is just one of many bicycles
in the world. Using object-oriented terminology, we say that your
bicycle object is an
instance
of the class of objects known as bicycles. Bicycles have some state
(current gear, current cadence, two wheels) and behavior (change gears,
brake) in common. However, each bicycle's state is independent of and
can be different from that of other bicycles.
When building bicycles, manufacturers take
advantage of the fact that bicycles share characteristics, building many
bicycles from the same blueprint. It would be very inefficient to
produce a new blueprint for every individual bicycle manufactured.
In object-oriented software, it's also possible
to have many objects of the same kind that share characteristics:
rectangles, employee records, video clips, and so on. Like the bicycle
manufacturers, you can take advantage of the fact that objects of the
same kind are similar and you can create a blueprint for those objects.
A software blueprint for objects is called a
class.