Separate Interface From Implementation

a client is directly dependent upon its server implementation
extract an interface describing the client's needs and code against that interface

Context:

When client code needs to coordinate different implementations of a similar abstraction Separate Interface From Implementation can be useful to Enable Substitution With Interfaces.

After separating an interface from its implementation it is advisable to apply Hide Implementation With Interface to any remaining clients that still acces the server implementation directly.

Separate Interface From Implementation is a key refactoring to Break Module Depencencies With Adapter

See also :Extract Interface[Fowler]

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

[ Overview Page ] [ Thumbnail Catalog ]