Class Utils

java.lang.Object
org.apache.nifi.jms.cf.Utils

public final class Utils extends Object
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private static final org.slf4j.Logger
     
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static Method
    findMethod(String name, Class<?> targetClass)
    Finds a method by name on the target class.
    static Method[]
    findMethods(String name, Class<?> targetClass)
    Finds a method by name on the target class.
    (package private) static <T> T
    Creates new instance of the class specified by 'className' by first loading it using thread context class loader and then executing default constructor.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • logger

      private static final org.slf4j.Logger logger
  • Constructor Details

    • Utils

      public Utils()
  • Method Details

    • newDefaultInstance

      static <T> T newDefaultInstance(String className)
      Creates new instance of the class specified by 'className' by first loading it using thread context class loader and then executing default constructor.
    • findMethod

      public static Method findMethod(String name, Class<?> targetClass)
      Finds a method by name on the target class. If more then one method present it will return the first one encountered.
      Parameters:
      name - method name
      targetClass - instance of target class
      Returns:
      instance of Method
    • findMethods

      public static Method[] findMethods(String name, Class<?> targetClass)
      Finds a method by name on the target class. If more then one method present it will return the first one encountered.
      Parameters:
      name - method name
      targetClass - instance of target class
      Returns:
      Array of Method