Mastering ninject for dependency Injection learn how ninject facilitates the implementation of dependency injection to solve common design problems of real-life applications
For .NET developers and architects, this is the ultimate guide to the principles of Dependency Injection and how to use the automating features of Ninject in the most effective way. Packed with examples, diagrams, and illustrations. Create loosely coupled applications by implementing dependency inje...
Autor principal: | |
---|---|
Otros Autores: | |
Formato: | Libro electrónico |
Idioma: | Inglés |
Publicado: |
Birmingham, England :
Packt Publishing
2013.
|
Edición: | 1st edition |
Colección: | Community experience distilled
|
Materias: | |
Ver en Biblioteca Universitat Ramon Llull: | https://discovery.url.edu/permalink/34CSUC_URL/1im36ta/alma991009627791406719 |
Tabla de Contenidos:
- Intro
- Mastering Ninject for Dependency Injection
- Table of Contents
- Mastering Ninject for Dependency Injection
- Credits
- About the Author
- About the Reviewers
- www.PacktPub.com
- Support files, eBooks, discount offers and more
- Why Subscribe?
- Free Access for Packt account holders
- Preface
- What this book covers
- What you need for this book
- Who this book is for
- Conventions
- Reader feedback
- Customer support
- Downloading the example code
- Errata
- Piracy
- Questions
- 1. Understanding Dependency Injection
- What is Dependency Injection?
- DI or Inversion of Control (IoC)
- How can DI help?
- My First DI Application
- DI Containers
- Why use Ninject?
- Summary
- 2. Getting Started with Ninject
- Hello Ninject!
- It's all about Binding
- Object Lifetime
- Transient scope
- Singleton scope
- Thread scope
- Request scope
- Custom scope
- Ninject modules
- XML configuration
- How to use XML configuration
- Convention over configuration
- Selecting the assemblies
- Selecting the components
- Filtering the selected components
- Explicit inclusion and exclusion
- Selecting service types
- Configuring the Bindings
- Summary
- 3. Meeting Real-world Requirements
- DI patterns and antipatterns
- Constructor Injection
- Initializer methods and properties
- Service Locator
- Multi binding and contextual binding
- Implementing the plugin model
- Contextual binding
- Named binding
- Resolving metadata
- Attribute-based binding
- Target-based conditions
- Generic helper
- Custom providers
- Activation context
- Factory Methods
- Dynamic factories
- The Shape Factory example
- Using convention
- Selecting service types
- Defining Binding Generator
- Telecom Switch example
- Custom Instance Providers
- Func
- Lazy
- Summary
- 4. Ninject in Action.
- Windows Forms applications
- WPF and Silverlight applications
- ASP.NET MVC applications
- Validator injection
- Filter injection
- Conditional filtering (When)
- Contextual arguments (With)
- WCF applications
- ASP.NET Web Forms applications
- Summary
- 5. Doing More with Extensions
- Interception
- Setup Interception
- Member Interception
- Type Interception
- Multiple Interceptors
- Intercept Attribute
- Mocking Kernel
- Extending Ninject
- Summary
- Index.