Delegation: Forces (Cont.)
Declaring a problem domain class as a subclass of a utility class is bad:
- If you declare a class as a subclass of vector, you run the risk of vector changing in an incompatible way.
- Client classes may assume the superclass
- Client classes can call the public methods of the utility superclass, which defeats its encapsulation.