Package
java.dyn has been renamed java.lang.invoke.
Although I donβt think you can create an invokedynamic command from Java, the instruction exists for other dynamic languages.
In Java, you can use "java.lang.invoke.MethodHandle" as a faster alternative to reflection, examples are available in the javadoc of the MethodHandle class. Note that the invokedynamic instruction itself relies on the MethodHandle to dynamically link methods. (You can read more detailed information at http://java.sun.com/developer/technicalArticles/DynTypeLang/index.html )
source share