Class PrimitiveComparator<T>

java.lang.Object
org.apache.parquet.schema.PrimitiveComparator<T>
All Implemented Interfaces:
Serializable, Comparator<T>

public abstract class PrimitiveComparator<T> extends Object implements Comparator<T>, Serializable
Comparator implementation that also supports the comparison of the related primitive type to avoid the performance penalty of boxing/unboxing. The compare methods for the not supported primitive types throw UnsupportedOperationException. Serializable implementation that may be a UserDefinedPredicate defined this Comparator is their member variable.
See Also:
  • Field Details

    • UNSIGNED_LEXICOGRAPHICAL_BINARY_COMPARATOR

      public static final PrimitiveComparator<Binary> UNSIGNED_LEXICOGRAPHICAL_BINARY_COMPARATOR
  • Constructor Details

    • PrimitiveComparator

      public PrimitiveComparator()
  • Method Details

    • compare

      public int compare(boolean b1, boolean b2)
    • compare

      public int compare(int i1, int i2)
    • compare

      public int compare(long l1, long l2)
    • compare

      public int compare(float f1, float f2)
    • compare

      public int compare(double d1, double d2)
    • compare

      public final int compare(T o1, T o2)
      Specified by:
      compare in interface Comparator<T>