Chapter 5. Doing More with Extensions
While the core library of Ninject is kept clean and simple, Ninject is a highly extensible DI container and it is possible to extend its power using extension plugins. We have already used some of them in the previous chapter. In this chapter, we will see how interception is a solution for cross-cutting concerns and how to use Mocking Kernel as a test asset. We will also look at how Ninject can be extended:
- Interception
- Mocking Kernel
- Extending Ninject
By the end of this chapter, the user will be able to make use of Interception and Mocking Kernel extensions.
Interception
There are cases where we need to do some operations before or after calling a single method or a number of methods. For example, we may need to ...
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.