Class CachedMethod

    • Constructor Detail

      • CachedMethod

        public CachedMethod​(Method method)
    • Method Detail

      • getName

        public String getName()
        Description copied from class: MetaMethod
        Returns the name of the method represented by this class
        Specified by:
        getName in class MetaMethod
        Returns:
        name of this method
      • getDescriptor

        public String getDescriptor()
        Description copied from class: MetaMethod
        Return a descriptor of this method based on the return type and parameters of this method.
        Overrides:
        getDescriptor in class MetaMethod
      • invoke

        public final Object invoke​(Object object,
                                   Object[] arguments)
        Description copied from class: MetaMethod
        Invoke this method
        Specified by:
        invoke in class MetaMethod
        Parameters:
        object - The object this method should be invoked on
        arguments - The arguments for the method if applicable
        Returns:
        The return value of the invocation
      • getReturnType

        public Class getReturnType()
        Description copied from class: MetaMethod
        Access the return type for this method
        Specified by:
        getReturnType in class MetaMethod
        Returns:
        the return type of this method
      • getParamsCount

        public int getParamsCount()
      • getModifiers

        public int getModifiers()
        Description copied from class: MetaMethod
        Returns the modifiers for this method
        Specified by:
        getModifiers in class MetaMethod
        Returns:
        modifiers as an int.
      • getSignature

        public String getSignature()
        Description copied from class: MetaMethod
        Returns the signature of this method
        Overrides:
        getSignature in class MetaMethod
        Returns:
        The signature of this method
      • setAccessible

        public final Method setAccessible()
      • isStatic

        public boolean isStatic()
        Description copied from class: MetaMethod
        Returns whether or not this method is static.
        Overrides:
        isStatic in class MetaMethod
        Returns:
        true if this method is static
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object
      • getCachedMethod

        public Method getCachedMethod()