On Dec 7, 2010, at 4:13 PM, Cédric Beust ♔ wrote: > > > On Tue, Dec 7, 2010 at 4:07 PM, Ralph Goers <[email protected]> wrote: > > On Dec 7, 2010, at 3:52 PM, Kevin Wright wrote: > >> Both Spring and reflection are hacks around the type system anyway, seems >> very sensible to ban them. >> > What?? > > Before Spring there was PicoContainer and Avalon and then Guice came along > after, all of which has fed into injection into Java EE 5. Reflection is > used in lots of places including Digester, JAXB, and Tomcat's ClassLoader and > even Log4J. > > Again, nobody said that reflection was useless, just that banning its use by > default is probably a good rule of thumb to write applicative type Java code. > > Reflection is obviously mandatory for more "fundamental" frameworks such as > Guice or TestNG, but people writing such Java code are in a very tiny > minority.
I guess I must be one of them. Virtually every Apache project I commit on uses it. As for Spring, I fail to see the distinction between it and Guice. They both support a similar set of annotations but Guice requires you write Java to perform the injection while Spring allows XML. That is just a philosophical argument. Ralph -- You received this message because you are subscribed to the Google Groups "The Java Posse" 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/javaposse?hl=en.
