Class ReflectionUtils

java.lang.Object
org.aksw.commons.beans.model.ReflectionUtils

public class ReflectionUtils extends Object
  • Constructor Details

    • ReflectionUtils

      public ReflectionUtils()
  • Method Details

    • findMethod

      public static Method findMethod(Class<?> clazz, String name, Class<?>... parameterTypes)
      Find a method or return null if none found. Never raises an exception.
    • makeAccessible

      public static void makeAccessible(Constructor<?> ctor)
    • findField

      public static Field findField(Class<?> clazz, String name, Class<?> type)
      Copy invalid input: '&' adapted from springframework 5.2.8.RELEASE Attempt to find a field on the supplied Class with the supplied name and/or type. Searches all superclasses up to Object.
      Parameters:
      clazz - the class to introspect
      name - the name of the field (may be null if type is specified)
      type - the type of the field (may be null if name is specified)
      Returns:
      the corresponding Field object, or null if not found