Given the definition of the Vehicle class: class Vehicle { String name; void setName (String name) { this.name = name; } String getName() { return name; } } Which action encapsulates the Vehicle class? Vehicle class public.
For encapsulation to be carried out, the variable must be private and accessed via methods, starting with "get" or "is" also for "boolean" and "set". So the answer is C.
This section is not available anymore. Please use the main Exam Page.1z0-809 Exam Questions
Log in to ExamTopics
Sign in:
Community vote distribution
A (35%)
C (25%)
B (20%)
Other
Most Voted
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
Destroyer
Highly Voted 4 years, 12 months agoiSnover
Most Recent 10 months, 3 weeks agosteefaand
10 months, 3 weeks ago