Class ReflectUtils

java.lang.Object
org.eclipse.jetty.websocket.common.util.ReflectUtils

public class ReflectUtils extends Object
  • Constructor Details

    • ReflectUtils

      public ReflectUtils()
  • Method Details

    • appendTypeName

      private static StringBuilder appendTypeName(StringBuilder sb, Type type, boolean ellipses)
    • findGenericClassFor

      public static Class<?> findGenericClassFor(Class<?> baseClass, Class<?> ifaceClass)
      Given a Base (concrete) Class, find the interface specified, and return its concrete Generic class declaration.
      Parameters:
      baseClass - the base (concrete) class to look in
      ifaceClass - the interface of interest
      Returns:
      the (concrete) generic class that the interface exposes
    • findTypeParameterIndex

      private static int findTypeParameterIndex(Class<?> clazz, TypeVariable<?> needVar)
    • isDefaultConstructable

      public static boolean isDefaultConstructable(Class<?> clazz)
    • resolveGenericRef

      private static boolean resolveGenericRef(ReflectUtils.GenericRef ref, Class<?> clazz, Type type)
    • resolveGenericRef

      private static boolean resolveGenericRef(ReflectUtils.GenericRef ref, Type type)
    • toShortName

      public static String toShortName(Type type)
    • toString

      public static String toString(Class<?> pojo, Method method)
    • trimClassName

      public static String trimClassName(String name)