Question OOP-ENC-0059
MediumWhich is NOT an example of encapsulation?
- A.
An inner helper class marked private
- B.
A private field with a validating setter
- C.
Sign up free to see the answer and a step-by-step explanation.
Popular companies
Prepare company by company
Hiring pattern, syllabus, past questions and mocks for each company.
All companiesPractice by subject
Encapsulation question
Which is NOT an example of encapsulation?
An inner helper class marked private
A private field with a validating setter
Sign up free to see the answer and a step-by-step explanation.
A subclass overriding a method of its parent
A module exposing only a few public functions