Tag Archives: design patterns

Your constructor smells

A code like the following looks as a “code smell” definitely: public ProductProvider( IProductDataProvider dataProvider = null, IProductDecorator decorator = null, IProductSearchCriteriaParser parser = null, IProductInventoryDataProvider inventoryProvider = null, IProductSessionDataProvider sessionProvider = null, IContentProvider contentProvider = null, IProductQueueProvider queueProvider = … Continue reading

Posted in Programming | Tagged | 1 Comment

“Black Hole” software anti-pattern

During digging into eCommerce5 codebase and discussing ongoing impressions with my colleague,¬† I just discovered a software design anti-pattern I called “Black Hole”. As a workaround I declare a rule: Any variables passed into constructor then should be available¬†through a … Continue reading

Posted in Programming | Tagged | 2 Comments