类 ValueType<T>

java.lang.Object
cc.carm.lib.configuration.adapter.ValueType<T>

public abstract class ValueType<T> extends Object
Used to get the generic type.
  • 字段详细资料

  • 构造器详细资料

    • ValueType

      protected ValueType()
  • 方法详细资料

    • of

      public static <T> ValueType<T> of(@NotNull T value)
    • of

      public static <T> ValueType<T> of(Type type)
    • of

      public static <T> ValueType<T> of(@NotNull @NotNull Class<T> clazz)
    • ofList

      public static <T> ValueType<List<T>> ofList(@NotNull @NotNull Class<T> paramType)
    • of

      public static <T> ValueType<T> of(Class<?> rawType, Type... types)
      Get the generic type of the complex type.
      类型参数:
      T - The type
      参数:
      rawType - The raw type
      types - The type arguments
      返回:
      The ValueType
    • getType

      public Type getType()
    • isSubtypeOf

      public boolean isSubtypeOf(Class<?> target)
    • isSubtypeOf

      public boolean isSubtypeOf(ValueType<?> target)
    • isInstance

      public boolean isInstance(Object obj)
    • getRawType

      public Class<?> getRawType()
      提取当前 ValueType 的原始类型(Class 对象)。
      返回:
      对应的 Class 对象
      抛出:
      IllegalStateException - 如果无法提取出原始类型
    • cast

      public T cast(Object obj)
    • toString

      public String toString()
      覆盖:
      toString 在类中 Object
    • equals

      public boolean equals(Object obj)
      覆盖:
      equals 在类中 Object
    • hashCode

      public int hashCode()
      覆盖:
      hashCode 在类中 Object