Manning Early
Access Program
Dependency Injection
EARLY ACCESS EDITION
With examples in Java, Ruby, and C#
Dhanji R. Prasanna

MEAP Release: February 2008
Softbound print: October 2008 (est.) | 375 pages
ISBN: 193398855X

Start Reading Dependency Injection today through the Manning Early Access Program
MEAP OPTIONS*
  MEAP + Ebook only - $29.99
  MEAP + Print book + Ebook Combo - $54.99
  Print book only - $49.99 (Not yet available for order)
* Download early chapters in PDF format! For more information, please see the MEAP FAQs page.
  About MEAP Release Date Estimates    

Table of Contents, MEAP Chapters & Resources

Table of Contents         Resources 
  • Chapter 1: Dependency Injection: What's all the hype? - FREE
  • Chapter 2: Inject me already! - AVAILABLE
  • Chapter 3: Investigating Dependency Injection - AVAILABLE
  • Chapter 4: Building modular applications - AVAILABLE
  • Chapter 5: Scope: objects and their state - AVAILABLE
  • Chapter 6: Advanced scoping and pitfalls - AVAILABLE
  • Chapter 7: From birth to death: object lifecycle
  • Chapter 8: Managing your object’s behavior
  • Chapter 9: Designing enterprise applications with Dependency Injection
  • Chapter 10: Designing managed objects
  • Chapter 11: DI integration with other frameworks
  • Chapter 12: Choose your poison: comparing DI frameworks
  • Appendix A: A list and comparison of open-source DI frameworks
  • Appendix B: References
  • Author Forum
      Go here to discuss this title with the author
 

DESCRIPTION

Have you ever used the new keyword to create objects? Well, Dependency Injection is the new new!

In a traditional object-oriented application, a primary program controls secondary pieces of code, such as classes in a module, library, or framework. Dependency Injection (DI) is a technique that inverts this control, using an external mechanism to insert—or inject—a reference to an implementation of a service into an object. This allows you to build complex OO applications in a more testable, maintainable, and business-focused manner.

With DI, your code doesn't require expensive factories and repetitive boilerplate, making for robust, scalable architecture. As a developer, you can focus on your core application logic and move infrastructure and architecture concerns where they belong—out of your code and into the framework's domain.

Dependency Injection is a thorough examination of this core concept for building applications in any object-oriented language or framework. This book explores Dependency Injection, sometimes called Inversion of Control, in fine detail with numerous practical examples. In it, you'll learn to apply various techniques, focusing on their strengths and limitations, with a particular emphasis on pitfalls, corner-cases, and best practices. This book covers the full range of architectural idioms as they relate to DI: from Injection, Scope, and Lifecycle to Loose Coupling and AOP Interception.

This book is written for developers and architects who want to understand Dependency Injection and successfully leverage popular DI technologies such as Spring, Google Guice, PicoContainer, and many others. This book requires a working knowledge of object-oriented programming in Java, Ruby, or C#.

About the Author

Dhanji R. Prasanna is an Enterprise Java consultant for technologies such as EJB3, JBI, JSF, Guice, Spring, HiveMind, and PicoContainer. He is a co-author of the Bean Validation (JSR-303), JAX-RS (JSR-311), Servlet 3.0 (JSR-315), and JavaServerFaces 2.0 (JSR-314) specifications. He is also co-author of the Java EE 6.0 (JSR-316) platform specification, which is the next edition of J2EE.

About the Early Access Version

This Early Access version of Dependency Injection enables you to receive new chapters as they are being written. You can also interact with the authors to ask questions, provide feedback and errata, and help shape the final manuscript on the Author Forum

Want to learn More?

Sign up to read more content when it is released and to receive news about this book.