there's an order of magnitude performance cost when using reflection instead of JVM-supported invokedynamic.
Reflection is fine for occasional use (such as loading plugins), but it isn't something you want to use heavily. invokedynamic is of limited use for Java, and is intended for better support of dynamically-typed languages, where EVERY call might be dynamic and the cost of using reflection would be crippling. On 9 September 2010 09:56, Wildam Martin <mwil...@gmail.com> wrote: > Again, a discussion that leads to Java vs Scala... - it starts to get > annoying. > > At http://blogs.sun.com/mr/entry/rethinking_jdk7 in the comments many > complain that they wait for invokedynamic. > > I wonder, because I use dynamic class loading and dynamic calling of > methods already for a while in Java 6. As it seems that many don't > know how to do it, I have put together a post on my blog (for the case > you are interested): > > http://it-tactics.blogspot.com/2010/09/dynamic-method-invocation-in-java-6.html > > -- > Martin Wildam > > http://www.google.com/profiles/mwildam > > -- > You received this message because you are subscribed to the Google Groups > "The Java Posse" group. > To post to this group, send email to javapo...@googlegroups.com. > To unsubscribe from this group, send email to > javaposse+unsubscr...@googlegroups.com<javaposse%2bunsubscr...@googlegroups.com> > . > For more options, visit this group at > http://groups.google.com/group/javaposse?hl=en. > > -- Kevin Wright mail / gtalk / msn : kev.lee.wri...@gmail.com pulse / skype: kev.lee.wright twitter: @thecoda -- You received this message because you are subscribed to the Google Groups "The Java Posse" group. To post to this group, send email to javapo...@googlegroups.com. To unsubscribe from this group, send email to javaposse+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/javaposse?hl=en.