what are the main underlying concepts of object orientation?
Answers were Sorted based on User's Feedback
Answer / shahir
Mainly there are four concepts for OOAD.
1.Abstraction -grouping of data and behaviour(operations)
into a conceptual object.
2.Encapsulation -Its the implementation mode of data
abstraction.With encapsulation, we can accomplish data
hiding
3.Polymorphism -Polymorphism refers to the process whereby
an object invokes a method of another object in a common
manner (with the same name) without understanding or caring
how it is accomplished.
4.Inheritance-When an object is derived from another
object. It inherits all the properties etc
| Is This Answer Correct ? | 11 Yes | 2 No |
Answer / prasi
Abstraction - Interfaces are the best examples of
abstraction .
Encapsulation - Classes are best examples of encapsulation.
Generally we encapsulate what varies &
we abstract commonalities...
One more thing, You should always subclass for behabiours..
you should never subclass for properties / attributes. If
only properties vary, then you have got to encapsulate them
in somewhere else e.g. in a class or in some collection
object like - Properties in Java / Map
Hope this helps..
| Is This Answer Correct ? | 7 Yes | 2 No |
What does the keyword virtual represented in the method definition?
Does a class inherit the constructor of its super class?
Difference: Object Oriented Analysis (OOA) and Object Oriented Design (OOD)?
What is the use if instanceof keyword?
What is polymorphism and abstraction?
0 Answers Agilent, Integreon, ZS Associates,
Give any criteria when you use an abstract class and an interface?
0 Answers Sans Pareil IT Services,
What is data encapsulation and what's its significance?
What is the practical implementation of inner classes?
Explain the mechanism of composition?
Explain about overriding polymorphism?
what are the different ways for a method to be overloaded?
What's the benefit of using inheritance?