Tuesday, May 29, 2012

Mixin vs. Inheritance

Abstract classes have been criticized not being examples of specialization -- allegedly the purpose of OO inheritance -- but rather of extension.

Well, to redeem the value of the abstract class, we simply call it a "mixin" and all is good and valid.


Mixins are synonymous with abstract base classes. Inheriting from a mixin is not a form of specialization but is rather a means of collecting functionality. A class or object may "inherit" most or all of its functionality from one or more mixins, therefore mixins can be thought of as a mechanism of multiple inheritance.
 http://en.wikipedia.org/wiki/Mixin

Sunday, May 20, 2012

In Memory Storage - Use static keyword

Use the static keyword in a controller class level field (e.g. a List<string>) for IMDB (in-memory database)

Wednesday, May 2, 2012

Fluent Interface

A fluent interface is normally implemented by using method chaining to relay the instruction context of a subsequent call (but a fluent interface entails more than just method chaining
 http://en.wikipedia.org/wiki/Fluent_interface