InterviewSolution
| 1. |
How Can You Prevent Accessing Of The Private Parts Of My Class By Other Programmers (violating Encapsulation)? |
|
Answer» ENCAPSULATION only hides the details of the implementation from users of the data type, and PROVIDES a public user INTERFACE. Encapsulation only maintains the INTEGRITY of the internal coding inside the methods of a class, but not able to prevent accessing the private or PROTECTED parts of a class by the user. Encapsulation only hides the details of the implementation from users of the data type, and provides a public user interface. Encapsulation only maintains the integrity of the internal coding inside the methods of a class, but not able to prevent accessing the private or protected parts of a class by the user. |
|