Enable Configurable Behavior With Plugin

instances of a class require configurable behavior
extract an interface for the pluggable behavior and have instances by default configured with a NullObject implementation

Context:
Enable Configurable Behavior With Plugin is a variation on Enable Substitution With Interfaces where the substitution allows the context class to be configured with an external implementation of a given interface. Configuring the default implementation with a NullObject relieves the context class from having to deal with the variation between a null referenc and given plugin.

Refactoring Thumbnails, Copyright © 2004 - 2005, Sven Gorts, All Rights Reserved.

[ Overview Page ] [ Thumbnail Catalog ]