Class DimensionComparisonUtils

java.lang.Object
org.apache.druid.query.DimensionComparisonUtils

public class DimensionComparisonUtils extends Object
Utility class to compare dimensions
  • Constructor Details

    • DimensionComparisonUtils

      public DimensionComparisonUtils()
  • Method Details

    • isNaturalComparator

      public static boolean isNaturalComparator(ValueType type, StringComparator comparator)
      Checks if the comparator is the natural comparator for the given type. Natural comparator for a type is the comparator that will yield the same results as a.compareTo(b) for objects a, b belonging to that valueType. In such cases, it'll be faster to directly use the comparison methods provided by Java or the library, as using the StringComparator would be slow. MSQ only supports natural comparators