public static MethodHandle ofSpecial(MethodDescription.InDefinedShape methodDescription, TypeDescription typeDescription) {
            if (!methodDescription.isSpecializableFor(typeDescription)) {
                throw new IllegalArgumentException("Cannot specialize " + methodDescription + " for " + typeDescription);
            }
            return new MethodHandle(HandleType.ofSpecial(methodDescription),
                    typeDescription,
                    methodDescription.getInternalName(),
                    methodDescription.getReturnType().asErasure(),
                    methodDescription.getParameters().asTypeList().asErasures());
        }
public static MethodHandle ofSpecial ( MethodDescription . InDefinedShape methodDescription , TypeDescription typeDescription ) { if ( ! methodDescription . isSpecializableFor ( typeDescription ) ) { throw new IllegalArgumentException ( "Cannot specialize " + methodDescription + " for " + typeDescription ) ; } return new MethodHandle ( HandleType . ofSpecial ( methodDescription ) , typeDescription , methodDescription . getInternalName ( ) , methodDescription . getReturnType ( ) . asErasure ( ) , methodDescription . getParameters ( ) . asTypeList ( ) . asErasures ( ) ) ; }
Creates a method handle representation of the given method for an explicit special method invocation of an otherwise virtual method.

@param methodDescription The method ro represent.
@param typeDescription   The type on which the method is to be invoked on as a special method invocation.
@return A method handle representing the given method as special method invocation.