Object-oriented programming: Difference between revisions

Content deleted Content added
Design patterns: Moved info from object (computer science)
Object patterns: separate out the anti-pattern
Line 257:
 
*[[Prototype pattern|Prototype object]]: a specialized metaobject from which other objects can be created by copying
 
*[[God object]]: knows or does too much; example of an [[anti-pattern]]
 
*[[Singleton pattern|Singleton object]]: only instance of its class for the lifetime of the program
 
*[[Filter object]]: receives a stream of data as its input and transforms it into the object's output
 
As an example of an object [[anti-pattern]], the [[God object]] knows or does too much.
 
===Inheritance and behavioral subtyping===