The designer of the class retains control of the class's implementation:
For example, in the Time class, there might be a getHours method, even though there may not be a hours instance variable.
Java just provides a convenient framework for writing robust code.