Latest Tutorials| Questions and Answers|Ask Questions?|Site Map



Home Help Java E Encapsulation

Related Tutorials


 
 

Share on Google+Share on Google+

Encapsulation

Advertisement
In OOPs, these concepts are implemented through a class definition and achieved through the object creation process, programmatically.

Encapsulation

     

OOPs revolve around the four concepts:

1. Encapsulation
2. Polymorphism
3. Abstraction
4. Inheritance

In OOPs, these concepts are implemented through a class definition and achieved through the object creation process, programmatically.

Here we will discuss Encapsulation briefly:

-- Encapsulation is an important programming concept. 
-- It helps in separating the states of an object from its behavior. 
-- It plays a vital role in maintaining security in the code by hiding the object's data (describing its state) from any unwanted external modifications.
-- Java provides the access rights to the external entities through the four different access modifiers, these are public, private, protected and default. 
-- Encapsulation allows the object being used within an application to know about the data according to the user's requirement.
-- Unwanted data that is not required by an object is kept hidden by the process of encapsulation. It is also known as information hiding.
-- Information hiding restricts the outsiders in seeing inside an object and thus providing security.

Read more at :

www.roseindia.net/java/beginners/oop-in-java.shtml

Advertisements

If you enjoyed this post then why not add us on Google+? Add us to your Circles



Liked it!  Share this Tutorial


Follow us on Twitter, or add us on Facebook or Google Plus to keep you updated with the recent trends of Java and other open source platforms.

Posted on: April 3, 2006

Related Tutorials

Discuss: Encapsulation  

Post your Comment


Your Name (*) :
Your Email :
Subject (*):
Your Comment (*):
  Reload Image
 
 
Comments:0
DMCA.com