ramesh kondeti
encapsulation
1 Answer(s)      2 years and 4 months ago
Posted in : Java Beginners

how encapsulation is achieved? if i write private variables in my source code, it will achieve encapsulation. this statement is true in all cases....

View Answers

February 17, 2011 at 3:33 PM


Encapsulation is achieved by declaring variables as Private in a class- this gives access to data to only member functions of the class. A next level of accessibility is provided by the Protected keyword which gives the derived classes the access to the member variables of the base class- a variable declared as Protected can at most be accessed by the derived classes of the class.









Related Pages:
encapsulation
encapsulation   how encapsulation is achieved? if i write private variables in my source code, it will achieve encapsulation. this statement is true in all cases
encapsulation vs abstraction
encapsulation vs abstraction  what is the difference between encapsulation and abstraction
Encapsulation & Abstraction - Java Interview Questions
Encapsulation & Abstraction  What is the difference between Encapsulation and Abstraction
Encapsulation & Abstraction - Java Interview Questions
Encapsulation & Abstraction  What is the difference between Encapsulation and Abstraction
Encapsulation
Encapsulation       OOPs revolve around the four concepts: 1. Encapsulation 2. Polymorphism 3.... Here we will discuss Encapsulation briefly: -- Encapsulation is an important
Reg:Encapsulation - Java Interview Questions
Reg:Encapsulation  where we use encapsulation in programs? how we know that is encapsulated?  Hi Friend, Encapsulation is a process... have to use the encapsulation feature.It hide the details by making the fields
Encapsulation in Java 7
Encapsulation in Java 7 This tutorial describe concept of  Encapsulation. It is one of OOPs concept. Encapsulation : Encapsulation is a way of wrapping up data and methods into a single unit. Encapsulation puts the data safe from
Encapsulation VS Abstraction - Java Beginners
Encapsulation VS Abstraction  Real Time sample code for Encapsulation... private.  Hi Friend, Encapsulation-Encapsulation is a process... to think about encapsulation is as a protective wrapper that prevents code and data
Encapsulation in Java
Encapsulation along with Inheritance, Polymorphism, and Abstraction are the four concepts of Object Oriented Programming (OOPs). Encapsulation in Java... and provides access to them by public methods. Encapsulation is a type of data
Difference between Encapsulation and Abstraction in Java
In this section we will discuss about the difference between Encapsulation and Abstraction in Java. Encapsulation is a process of hiding all the data.... Encapsulation in Java is represented using  private, package-private
Factory Pattern
is good since it encourages Encapsulation and Delegation. A class may need
Addition of two Number in Class
in which uses of class consists of a collection of type of encapsulation instance
java
java  Im asking for simple java program with encapsulation pls
pls help me with this question
pls help me with this question  how to write a program in C++ using encapsulation,polymorphism,inheritance and abstraction?(all these concepts should come in a single program
java - Java Beginners
java   Can you provide me the example program which uses all the concepts like encapsulation ,inheritance ,polymorphism in a single program
oops concepts
oops concepts  What is polymorphism?Explain with an example. What is abstraction?Explain with an example. What is inheritance?Explain with an example. What is encapsulation?Explain with an example
Core Java - Java Beginners
Core Java  Can u give real life and real time examples of abstraction, Encapsulation,Polymarphism....?  I guess you are new to java and new to roseindia as well.. anyways given is the encapsulation example http
corejava - Java Beginners
of Encapsulation in java? I'm a core Java beginner.  Hi,Here is the description of Encapsulation in java:Encapsulation is a process of binding... encapsulation is as a protective wrapper that prevents code and data from being
java bits 7 - Java Interview Questions
encapsulation. D. The cardlD and limit variables break polymorphism. E. The setCardlnformation method breaks encapsulation
java - Java Beginners
java  pl. let me know few progrograms on encapsulation. thanks... int displayVolume() {return (length*width*height);} } class Encapsulation...(); System.out.println("Volume is : " + vol); } } Encapsulation
Oops Definition - Java Beginners
Oops Definition  What is Abstraction and Encapsulation? What is the Difference Between Abstraction and Encapsulation? Regards M.KethraBalan....). Encapsulation - This is an important programming concept that assists in separating
java basics
java basics  What are Encapsulation, Inheritance and Polymorphism?  Encapsulation - Hiding the implementation details of a Class. Once a class is Encapsulated then we Cannot directly access that class
Object-Oriented Design - Overview
Java: Object-Oriented Design - Overview Encapsulation Article GetterEradicator It's a nice article about Encapsulation by Martin Fowler. Fowler is one of leading authors in the design area. His (with Kent Beck and other coauthors
java
java  purpose of encapsulation?   The basic purpose of encapsulation is SECURITY. You won't want anyone to steal into your pages or your programs easily by using java. When you declare an instance variable(I hope you
CAP - Code Analysis Plugin
in your architektur, will help to improve the encapsulation. As a result your
arraylist
Duplicates from ArryaList   Encapsulation And Abstraction   
OOPs concepts in Java
Object Inheritance Encapsulation Abstraction Polymorphism Class: Class... object at a time. Abstract deals with interface. Encapsulation: Encapsulation means wrapping up data and behavior of an object in a class. Encapsulation also
Object-Oriented Language: Java / APIs, Java OOPs
oriented concepts are: Encapsulation Inheritance Polymorphism
Java7 : OOPs Concepts
following concepts: Abstraction Encapsulation Inheritance Polymorphism... and show only essential features. Encapsulation: Encapsulation is a way
PHP Mutator Accessor
PHP Mutator and Accessor Methods: In object-oriented programming, the mutator method (also called "setter") is used to initialize the member variables of a class. According to the encapsulation principle the variables
java
encapsulation. Pls friends. Thank you.  Hi, Are you looking for SWING
java
, same goes for the rest.It must define polymophysm and have encapsulation. Pls
constructors - Java Beginners
would erode the encapsulation abilities of the language. class
java - Java Interview Questions
? What are Encapsulation, Inheritance and Polymorphism? n many which i guess is lot
Polymorphism
Polymorphism        OOPs revolve around the four concepts: 1. Encapsulation 2. Polymorphism 3. Abstraction 4. Inheritance In OOPs, these concepts are implemented through
inherittance
inherittance  Develop a class Borrower which has 5 important fileds, namely borrowerId, borrowerName, borrowerLastName, contactNumber and dateOfBirth. Your class must demonstrate good encapsulation where all fileds get
ejb - EJB
. Encapsulation of environmental dependencies EJB 3.0 now uses the annotations and dependency injection mechanism to encapsulation the environmental
hai
hai  bring out the oop features in java with examples?   Java OOPS Features   Encapsulation Example: public class Box { private int length; private int width; private int height; public void setLength(int p
Creational Design Pattern
Encapsulation and Delegation. A class may need it?s subclasses to specify the objects
Inheritance
Inheritance        OOPs revolve around the four concepts: 1. Encapsulation 2. Polymorphism 3. Abstraction 4. Inheritance In OOPs, these concepts are implemented through a class
OOP
concepts: 1. Encapsulation 2. Polymorphism 3. Abstraction 4. Inheritance In OOPs
JavaScript Object Oriented Feature
to be reentrant.  Encapsulation The Object-Oriented program using... collisions. The Object-Oriented program Encapsulation supports data hiding... the remainder of the program from the implementation . Encapsulation is a 
Abstraction : Java Glossary
Abstraction : Java Glossary       OOPs revolve around the four concepts: 1. Encapsulation 2. Polymorphism 3. Abstraction 4. Inheritance In OOPs, these concepts
Core Java Doubts - Java Beginners
and Encapsulation? 6)Give brief notes over collections? And their usage?  ..., it deals with the outside view of an object (interface). Encapsulation
OOPs and Its Concepts in Java
class, method, inheritance, encapsulation, abstraction, polymorphism etc. Class...; Encapsulation - This is an important programming concept that assists in separating
Java - Java Beginners
class, method, inheritance, encapsulation, abstraction, polymorphism etc
Java: Strengths
-oriented programming features (inheritance, encapsulation
Introduction
code and adding the additional features as needed. Encapsulation: ....  Encapsulation, Inheritance and Polymorphism are main pillars of OOPs. These have been described below : Encapsulation: Encapsulation is the process
Java Nested Class
. It increases encapsulation. Nested classes can lead to more