Object-oriented concepts and features

Java is an object-oriented programming language, object-oriented programming is an idea, under the guidance of our object-oriented thinking, the use of the Java language to design, develop computer programs. The object here refers to the reality of all things, every thing all have their own attributes and behaviors. Object-oriented computer programming is in process, referring to the reality of things, the properties of the characteristics of things, abstracted behavioral characteristics, describe the design ideas into computer events. It is different from the process-oriented thinking, the emphasis is achieved by calling the object's behavior, rather than trying to operate step by step to achieve.

Feature 

Object-oriented thinking is a more in line with our thinking habits of thought, it can be complex things simple, and we became a commander from the performer. Object-oriented languages, comprising the three basic characteristics, i.e. encapsulation, inheritance and polymorphism.

For example:

Process for: clothes off -> find a bowl -> put some detergent -> add water -> soak for 10 minutes -> rub -> Clothes washing -> wrung -> dry up

Object-oriented: the clothes off -> turn on automatic washing machine -> throw clothes -> button -> dry up

the difference:

Process-oriented: emphasis on steps.

Object-oriented: emphasis on object, the object here is the washing machine.

Guess you like

Origin www.cnblogs.com/libinhong/p/10988800.html