explain how many oops concepts available in java with realtime
scenarios?
Answer Posted / sakthi k
Encapsulation
Wrapping up of data and member function
together. Eg: Capsule is the good example for encapsulation.
Polymorphism
Ability of an object to take more than one form.
Poly-Many, Mor-Shape. For Eg: Anniyan film .
Compile time polymorphism otherwise known as
Static polymorphism.
Runtime polymorphism otherwise known as Dynamic
polymorphism.
Abstraction:
Represents the information without including the
background details.
For Eg: ATM Machine . .It provides the results
without including the background transaction.
Inheritance:
The process of acquiring base class property is
known as Inheritance.
Types
*Single inheritance
*Multiple inheritance
*Multi level inheritance: Eg:grand father-
father-son relationship.
*Hierachical inheritance
*Hybrid inheritance
Object:
Real time entity(attributes). Collection of its
own property.
Everything in the world is considered as real
objects.
Is This Answer Correct ? | 25 Yes | 2 No |
Post New Answer View All Answers
Can we have more than one package statement in source file ?
What is meant by binding in rmi?
What is difference between path and classpath?
What is the exception hierarchy in java?
Why do we need data serialization?
why using interface interface ?
v-model life cycle
How many digits can a float hold?
Can a lock be acquired on a class in java programming?
In a container there are 5 components. I want to display all the component names, how will you do that?
What is the difference between comparison done by equals method and == operator?
What do you mean by static variable?
Is string passed by reference in java?
What are 5 boolean operators?
Can we declare a class as abstract without having any abstract method?