Question: Which are true about mutator and accessor methods? (Select all that apply.) 1.The accessor and mutator methods of a parent class must be included in
Which are true about mutator and accessor methods? (Select all that apply.)
1.The accessor and mutator methods of a parent class must be included in the definition of a child class.
2.A method named getName would likely be an accessor method.
3.They are usually set to be private so they can be used by the class to update or retrieve the data stored in the class.
4.A mutator method is used by another class to retrieve data from an object.
5.They can be inherited by child classes.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
