Class TypeRef<T>

java.lang.Object
com.jayway.jsonpath.TypeRef<T>
Type Parameters:
T -
All Implemented Interfaces:
Comparable<TypeRef<T>>

public abstract class TypeRef<T> extends Object implements Comparable<TypeRef<T>>
Used to specify generic type information in ReadContext TypeRef ref = new TypeRefinvalid input: '<'List>() { };
  • Field Details

    • type

      protected final Type type
  • Constructor Details

    • TypeRef

      protected TypeRef()
  • Method Details

    • getType

      public Type getType()
    • compareTo

      public int compareTo(TypeRef<T> o)
      The only reason we define this method (and require implementation of Comparable) is to prevent constructing a reference without type information.
      Specified by:
      compareTo in interface Comparable<T>