Class ConstantInvokeDynamic


  • public class ConstantInvokeDynamic
    extends java.lang.Object
    • Field Detail

      • bootstrapMethodIndex

        private final int bootstrapMethodIndex
    • Constructor Detail

      • ConstantInvokeDynamic

        ConstantInvokeDynamic​(int bootstrapMethodAttrIndex,
                              ConstantNameAndType nameAndType)
        Invoke dynamic info in the constant pool. https://docs.oracle.com/javase/specs/jvms/se9/html/jvms-4.html#jvms-4.4.10
        Parameters:
        bootstrapMethodAttrIndex - a valid index into the bootstrap_methods array of the bootstrap method table
        nameAndType - the name and type
    • Method Detail

      • getName

        public java.lang.String getName()
        The simple name of the generated method of the single function interface.
        Returns:
        the name
      • getType

        public java.lang.String getType()
        Get the signature of the factory method. For example "()Ljava.lang.Runnable;" for the lamba expression "Runnable run = () -> foo();"
        Returns:
        the type
      • getBootstrapMethodIndex

        public int getBootstrapMethodIndex()
        Get the index to the bootstrap methods.
        Returns:
        the index