public InvokeDynamicConstant addInvokeDynamicRef ( BootstrapMethodAttribute attr , String methodName , String methodType , String bootClass , String bootMethod , String bootType , ConstantPoolEntry [ ] cpEntries ) { NameAndTypeConstant methodEntry = addNameAndType ( methodName , methodType ) ; MethodRefConstant bootMethodRef = addMethodRef ( bootClass , bootMethod , bootType ) ; MethodHandleConstant bootMethodHandle = addMethodHandle ( MethodHandleType . INVOKE_STATIC , bootMethodRef ) ; int bootIndex = attr . addMethod ( bootMethodHandle . getIndex ( ) , cpEntries ) ; InvokeDynamicConstant invokedynamicRef = new InvokeDynamicConstant ( this , _entries . size ( ) , attr , bootIndex , methodEntry . getIndex ( ) ) ; addConstant ( invokedynamicRef ) ; return invokedynamicRef ; }
Adds an invokedynamic constant .