java.lang.Object
com.github.retrooper.packetevents.util.reflection.Reflection

public final class Reflection extends Object
  • Constructor Details

    • Reflection

      public Reflection()
  • Method Details

    • getFields

      public static Field[] getFields(Class<?> cls)
    • getField

      public static Field getField(Class<?> cls, String name)
    • getField

      public static Field getField(Class<?> cls, Class<?> dataType, int index)
    • getField

      public static Field getField(Class<?> cls, Class<?> dataType, int index, boolean ignoreStatic)
    • getField

      public static Field getField(Class<?> cls, int index)
    • getMethod

      public static Method getMethod(Class<?> cls, String name, Class<?>... params)
    • getMethod

      public static Method getMethod(Class<?> cls, int index, Class<?>... params)
    • getMethod

      public static Method getMethod(Class<?> cls, Class<?> returning, int index, Class<?>... params)
    • getMethodExact

      public static Method getMethodExact(Class<?> cls, String name, Class<?> returning, Class<?>... params)
    • getMethod

      public static Method getMethod(Class<?> cls, String name, int index)
    • getMethod

      public static Method getMethod(Class<?> cls, Class<?> returning, int index)
    • getMethodCheckContainsString

      public static Method getMethodCheckContainsString(Class<?> cls, String nameContainsThisStr, Class<?> returning)
    • getMethods

      public static List<Method> getMethods(Class<?> cls, String name, Class<?> returning)
    • getClassByNameWithoutException

      @Nullable public static @Nullable Class<?> getClassByNameWithoutException(String name)
    • getConstructor

      public static Constructor<?> getConstructor(Class<?> cls, int index)
    • getConstructor

      public static Constructor<?> getConstructor(Class<?> cls, Class<?>... params)