Class RtMethod

java.lang.Object
spoon.support.visitor.java.reflect.RtMethod

public class RtMethod extends Object
  • Constructor Details

  • Method Details

    • getDeclaringClass

      public Class<?> getDeclaringClass()
    • getMethod

      public Method getMethod()
    • getName

      public String getName()
    • getReturnType

      public Class<?> getReturnType()
    • getTypeParameters

      public TypeVariable<Method>[] getTypeParameters()
    • getParameterTypes

      public Class<?>[] getParameterTypes()
    • getExceptionTypes

      public Class<?>[] getExceptionTypes()
    • getModifiers

      public int getModifiers()
    • getDeclaredAnnotations

      public Annotation[] getDeclaredAnnotations()
    • getParameterAnnotations

      public Annotation[][] getParameterAnnotations()
    • isVarArgs

      public boolean isVarArgs()
    • isDefault

      public boolean isDefault()
    • getGenericReturnType

      public Type getGenericReturnType()
    • getGenericParameterTypes

      public Type[] getGenericParameterTypes()
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

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

      public static RtMethod create(Method method)
      Parameters:
      method - is the Method which is to be wrapped in a RtMethod
      Returns:
      a wrapper around the passed method
    • methodsOf

      public static <T> RtMethod[] methodsOf(Class<T> clazz)
    • sameMethodsWithDifferentTypeOf

      public static <T> RtMethod[] sameMethodsWithDifferentTypeOf(Class<T> klass, List<RtMethod> comparedMethods)
      Returns the methods of `klass` that have the same signature (according to runtime reflection) but a different return type of at least one of the methods in `comparedMethods` given as parameter.