what are the oops concept in java explain with real time
examples

Answer Posted / magesh

We have the following oops concepts like
1.Abtsrction
2.Encapsulation
3.Inheritance
4.Polymorphism

Abstraction:

hiding unnecessary data from the users and making the
application as user friendly then it is called as
abstrcation

ex:Any mail account the user is simply filling the form and
he don't know how it is developed.

Encapsulation:

Wrapping the data and code as a single unit is called as
encapsulation.

ex:Capsule is the best real time example for it.In it we
will have two types of drugs combined as single capsule.

Inheritance :
Acquiring the properties from one class(base class or parent
class)to another class(derived class or child class)is
called as inheritance.

Ex:Inventing laptop from desktop.

Polymorphism:

Single entity behaving in different forms is called as
polymorphism

ex:Mouse is for click the buttons and dragging the bars or
placing the pointer in a particular place

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to print nodes of a Binary tree?

1750


What is exception in java?

561


can rmi and corba based applications interact ?

656


What is the public field modifier?

536


What is consumer interface?

550






How does sublist works in java?

532


EDS (Electronic Data Systems India Pvt Ltd) at Chennai on 16-12-2006.

8608


What does java ide mean?

628


what is the difference between a threads start() and run() methods? : Java thread

516


State the significance of public, private, protected class?

645


What are the parts of methodology?

537


What is substring in java?

608


What is the benefit of inner classes in java?

594


Can we declare a constructor as final?

669


What is null data type?

531