Structural pattern: Difference between revisions

Content deleted Content added
mNo edit summary
more examples from c2.com
Line 4:
 
* [[Adapter pattern]]: 'adapts' one interface for a class into one that a client expects
** Retrofit Interface Pattern<ref>http://c2.com/cgi/wiki?RetrofitInterfacePattern</ref> or <ref>http://c2.com/cgi/wiki?ExternalPolymorphism</ref>: An adapter used as a new interface for multiple classes at the same time.
** Adapter pipeline: Use multiple adapters for debugging purposes.<ref>http://c2.com/cgi/wiki?AdapterPipeline</ref>
* [[Aggregate pattern]]: a version of the [[Composite pattern]] with methods for aggregation of children
* [[Bridge pattern]]: decouple an abstraction from its implementation so that the two can vary independently
** Tombstone: An intermediate "lookup" object contains the real ___location of an object.<ref>http://c2.com/cgi/wiki?TombStone</ref>
* [[Composite pattern]]: a tree structure of objects where every object has the same interface
* [[Decorator pattern]]: add additional functionality to a class at runtime where subclassing would result in an exponential rise of new classes