Which three statements are benefits of encapsulation?

Which three statements are benefits of encapsulation?

Which three statements are benefits of encapsulation?

A.
allows a class implementation to change without changing t he clients

B.
protects confidential data from leaking out of the objects

C.
prevents code from causing exceptions

D.
enables the class implementation to protect its invariants

E.
permits classes to be combined into the same package

F.
enables multiple instances of the same class to be created safely



Leave a Reply 11

Your email address will not be published. Required fields are marked *


IDEN

IDEN

I do believe all the ideas you have offered in your post. They are very convincing and can certainly work. Still, the posts are very short for novices. May just you please prolong them a bit from next time? Thank you for the post:
IDEN http://www.net-ict.be/

Rohit

Rohit

It should be ABD

Alonso

Alonso

ADF.

B Option is not refering to the class structure, but of some bussiness Logic. It does not make sense for me.
In other hand, Option F refers about making immutable classes for make instance safelly

Jeremy

Jeremy

ABF.

A already said class can be changed.
So D said class is invariant is wrong.

Martin Lee

Martin Lee

Hi, I have passed OCAJP 7 (1Z0-803) EXAM with 98%. I would like to share my exam experience with those who are going to take this exam. I learned the Mala Gupta’s book and PassLeader 1Z0-803 dumps. They were describing and explaning the key points of the exam very clearly. To be honest, I read Mala Gupta’s book mainly because of the interest how the basic things in Java are handled internally and I started to take the PassLeader 1Z0-803 dumps (http://www.passleader.com/1z0-803.html), around one week before the exam. Good luck to future Oracle exam takers!

Hans

Hans

A Changing class should not influence clients.
B is an example of well encapsulation, with private instance variables that are only available through setters and getters.
F Because not C,D,E.

Kurt

Kurt

The correct answer is ABD