what are the characteristics of oops?

Answer Posted / bhoomi

The Three OOP Principles
All object-oriented programming languages provide mechanisms that help you implement
the object-oriented model. They are encapsulation, inheritance, and polymorphism.
Let’s take a look at these concepts now.
Encapsulation
Encapsulation is the mechanism that binds together code and the data it manipulates,
and keeps both safe from outside interference and misuse. One way to think about
encapsulation is as a protective wrapper that prevents the code and data from being
arbitrarily accessed by other code defined outside the wrapper. Access to the code
and data inside the wrapper is tightly controlled through a well-defined interface.The power of encapsulated code is that everyone knows how to access it and thus
can use it regardless of the implementation details—and without fear of unexpected
side effects.

Inheritance
Inheritance is the process by which one object acquires the properties of another object.
This is important because it supports the concept of hierarchical classification. As
mentioned earlier, most knowledge is made manageable by hierarchical (that is, top-down)
classifications.However, by use of inheritance, an object need only define those qualities that make it
unique within its class. It can inherit its general attributes from its parent. Thus, it is the
inheritance mechanism that makes it possible for one object to be a specific instance of
a more general case.

Polymorphism
Polymorphism (from the Greek, meaning “many forms”) is a feature that allows one
interface to be used for a general class of actions. The specific action is determined by
the exact nature of the situation.
the concept of polymorphism is often expressed by the phrase “one
interface, multiple methods.” This means that it is possible to design a generic interface
to a group of related activities. This helps reduce complexity by allowing the same
interface to be used to specify a general class of action. It is the compiler’s job to select the
specific action (that is, method) as it applies to each situation. You, the programmer, do
not need to make this selection manually. You need only remember and utilize the
general interface.

Is This Answer Correct ?    2 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Get me a number puzzle game-program

1690


What is the types of inheritance?

598


What is encapsulation in simple terms?

535


What is debug class?what is trace class? What differences are between them? With examples.

1604


What type of loop is a for loop?

682






Write a program to reverse a string using recursive function?

1788


Why do we use class in oops?

553


What is use of overloading?

604


How to hide the base class functionality in Inheritance?

636


How to use CMutex, CSemaphore in VC++ MFC

4326


What are the 4 main oop principles?

677


Write a program to sort the number with different sorts in one program ??

1914


What do you mean by variable?

572


What is and I oop mean?

616


What is cohesion in oop?

619