April 24, 2012

Non-Virtual Interface Design Pattern

The Non-Virtual Interface Design Pattern is described here: http://www.blackwasp.co.uk/NVI.aspx

Basically the pattern promotes the use of non-virtual public base class methods that can be used by clients. A set of overridable behaviours are exposed (as protected or protected internal) that are invoked directly by exposed public methods in the base class. This way the base class behaviour can be overriden by deriving classes.

No comments: