Summary

Interception extension creates on the fly proxy wrappers around injected objects and allows us to intercept invocation of the wrapped service members and is one of the best practices to address cross-cutting concerns.

Mocking is another Ninject's handy extension which automates injection of mock objects. It has a built-in support for popular mocking frameworks such as RhinoMocks, Moq, and NSubstitute.

Ninject is a collection of independent components that are wired together and we can extend Ninject's functionality by adding new components or substituting the existing ones.

Get Mastering Ninject for Dependency Injection now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.