Wednesday, March 28, 2012

Behind Factory Pattern

Hi All,

I just realized that below are advantage and principal behind the Factory Pattern.

1) OCP principal will be satisfied for business object for extension without modifying the client code.
2) Client no need to aware of complex construction of business object
3) Make decision on run time based on user input or environment value.
4) Minimal code is change is applicable in future need some change in construction process as creation is done on central location.

Please add comments for missing advantages/principals