Chapter 3: From Journeyman to Bob

Now that you're familiar with the Guice basics, you're ready to go become a Guice master: scope like no one has scoped before; the world is at your Injector; the annotations lay at your feet, and so on—unless, of course, you skipped the previous chapter, you rascal.

Seriously, although you have a good understanding of what Guice is about, you still need that little bit of extra know-how to get going. Not everything you code against will implement an interface or will have a DI-style design, and you need to be prepared to deal with that. Also, Guice has some handy shortcuts when it comes to, for example, handling constant values or injecting configuration from a properties file. In this chapter, I'll stick all ...

Get Google Guice: Agile Lightweight Dependency Injection Framework now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.