Can we access private data outside of the class directly in
java programming language? Why There is no runtime checking
in java, which leads to access the private data directly
outside of a class?
Answer Posted / chaitali
No,we cannot access private data outside of class in java.
There is only compile time checking and no runtime check in
java because Java supports concepts like Polymorphism and
reflection where on runtime certain decisions are taken
| Is This Answer Correct ? | 14 Yes | 14 No |
Post New Answer View All Answers
Why do we need hashset in java?
What is the main advantage of passing argument by reference?
Explain different ways of creating a thread. Which one would you prefer and why?
Explain the reason behind ending a program with a system.exit(0)?
I am unable to find or learn about print command. I have a graphical program in core java in applet but i want to give print command but i have coding for that so if anyone know about this plz mail me on avdhesh_chauhan007@yahoo.co.in
What is the Concept of Encapsulation in OOPS
Which is bigger float or double?
How do you compare values in java?
What is role of void keyword in declaring functions?
What is byte [] in java?
Can you pass functions in java?
Can you call one constructor from another if a class has multiple constructors?
Explain about anonymous inner classes ?
What is the difference between int and integer in java?
What is nested interface?