Design Patterns: What is a type
- by contactmatt
A very basic question, but after reading the "Design Patterns: Elements of reusable OO Software" book, I'm a little confused.
The book states,
"An object's type only refers to its
interface-the set of request to which
it can respond. An object can have
many types, and objects of different
classes can have the same type."
Could someone please better explain what a Type is? I also don't understand how one object can have multiple types...unless the book is speaking of polymorphism....