On Tue, Oct 14, 2008 at 5:25 PM, Gili Tzabari <[EMAIL PROTECTED]>wrote:

>    I believe this ties into Joshua Bloch's "good APIs have good
> defaults" paradigm (I remember him saying this at some point). In other
> words, don't make the user do anything that you can reasonably do for
> him automatically. I don't know whether it applies in this context but I
> suspect it does. I don't think there is any danger that the lack of
> @Inject will somehow reduce the readability of the code. It is pretty
> clear that if there is only one constructor and Guice somehow constructs
> an instance of that class than it must obviously be using that constructor.


Ah, but when you're looking for callers in a non-Guice-aware IDE (or just
plain reading the code), the @Inject makes it obvious that this class is
injected by Guice. That wouldn't be immediately obvious otherwise.

FWIW, I'm pretty sure Josh would agree with me here.

Bob

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"google-guice" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/google-guice?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to