Dependency Injection

What is Dependency Injection?

This post will help you understand what DI (Dependency Injection) is, and how easy you can adopt the design patterns to create flexible and testable code. For a definition take a look at this Wikipedia article. From the three types of Dependency Injection constructor injection setter injection interface injection this post covers the interface type. The example will deal with a SharePoint list. This list can either be the posts list of a blog, or the comments list.