Use of Abstract Types
Abstract types are an important feature in statically typed OO languages. Many dynamically typed languages have no equivalent feature (although the use of duck typing makes abstract types unnecessary); however traits are found in some modern dynamically-typed languages.
Some authors argue that classes should be leaf classes (have no subtypes), or else be abstract.
Abstract types are useful in that they can be used to define and enforce a protocol; a set of operations which all objects that implement the protocol must support.
Read more about this topic: Abstract Type
Famous quotes containing the words abstract and/or types:
“For although memories, of a season, for example,
Melt into a single snapshot, one cannot guard, treasure
That stalled moment. It too is flowing, fleeting;
It is a picture of flowing, scenery, though living, mortal,
Over which an abstract action is laid out in blunt,
Harsh strokes.”
—John Ashbery (b. 1927)
“The wider the range of possibilities we offer children, the more intense will be their motivations and the richer their experiences. We must widen the range of topics and goals, the types of situations we offer and their degree of structure, the kinds and combinations of resources and materials, and the possible interactions with things, peers, and adults.”
—Loris Malaguzzi (19201994)