Class DimRange

java.lang.Object
org.apache.lucene.facet.facetset.DimRange

public class DimRange extends Object
Defines a single range in a FacetSet dimension.
WARNING: This API is experimental and might change in incompatible ways in the next release.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    final long
    Inclusive max
    final long
    Inclusive min
  • Constructor Summary

    Constructors
    Constructor
    Description
    DimRange(long min, long max)
    Creates a LongRange.
  • Method Summary

    Modifier and Type
    Method
    Description
    static DimRange
    fromDoubles(double min, boolean minInclusive, double max, boolean maxInclusive)
    Creates a DimRange for the given min and max double values.
    static DimRange
    fromFloats(float min, boolean minInclusive, float max, boolean maxInclusive)
    Creates a DimRange for the given min and max float values.
    static DimRange
    fromLongs(long min, boolean minInclusive, long max, boolean maxInclusive)
    Creates a DimRange for the given min and max long values.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • min

      public final long min
      Inclusive min
    • max

      public final long max
      Inclusive max
  • Constructor Details

    • DimRange

      public DimRange(long min, long max)
      Creates a LongRange.
      Parameters:
      min - inclusive min value in range
      max - inclusive max value in range
  • Method Details

    • fromLongs

      public static DimRange fromLongs(long min, boolean minInclusive, long max, boolean maxInclusive)
      Creates a DimRange for the given min and max long values. This method is also suitable for int values.
    • fromDoubles

      public static DimRange fromDoubles(double min, boolean minInclusive, double max, boolean maxInclusive)
      Creates a DimRange for the given min and max double values.
    • fromFloats

      public static DimRange fromFloats(float min, boolean minInclusive, float max, boolean maxInclusive)
      Creates a DimRange for the given min and max float values.