An accessor is a member function that allows someone to retrieve the contents of a protected data member. For an accessor to perform its function, the following conditions must be met: