+ 2
Java private variable public class
What is the use of setting instance variables private in a class and define public get and set methods to access them... Such a indirect method plus tedious?
6 Answers
+ 12
It's for security... You prohibit direct edit this way....
+ 2
Encapsulation.
+ 1
How??... I don't get the point... How can that be insecure... And what kind of security it provides???
+ 1
THANKYOU... They must say it Data Validation Technique... As far as i could get it... One again Thanks :)
0
hello