Introduction to Object-Oriented programming.

What is an object in the "real-world"? 

(Definitions found on the dictionary.)

Imagine now a written document as an object. Think of the characteristics of this object.

The material and the author are objects themselves. Length and title are characteristics of the written document. We can do the as we did for the book with the author and the material....

Author as an object

If we keep on going.... we could go on forever.  There is a point where we want to stop.  Objects are made of other objects...

We want a car.

We can buy it at the dealer :-)

We can build it ourselves.

Do we buy the engine or do we build one?

 

Lets think JAVA!

How do we model objects in JAVA?

Imagine now the same written document as a JAVA object. Think of the characteristics of this object.

 

Think ....

JAVA has predefined classes and objects for us to use. We don't have to build everything from scratch.