46 static const int32_t PRECISION_STEP_DEFAULT;
71 static int32_t longToPrefixCoded(int64_t val, int32_t shift, CharArray buffer);
77 static String longToPrefixCoded(int64_t val, int32_t shift);
82 static String longToPrefixCoded(int64_t val);
90 static int32_t intToPrefixCoded(int32_t val, int32_t shift, CharArray buffer);
96 static String intToPrefixCoded(int32_t val, int32_t shift);
101 static String intToPrefixCoded(int32_t val);
106 static int64_t prefixCodedToLong(
const String& prefixCoded);
111 static int32_t prefixCodedToInt(
const String& prefixCoded);
117 static int64_t doubleToSortableLong(
double val);
120 static String doubleToPrefixCoded(
double val);
124 static double sortableLongToDouble(int64_t val);
127 static double prefixCodedToDouble(
const String& val);
132 static void splitLongRange(
const LongRangeBuilderPtr& builder, int32_t precisionStep, int64_t minBound, int64_t maxBound);
137 static void splitIntRange(
const IntRangeBuilderPtr& builder, int32_t precisionStep, int32_t minBound, int32_t maxBound);
140 static void splitRange(
const LuceneObjectPtr& builder, int32_t valSize, int32_t precisionStep, int64_t minBound, int64_t maxBound);
143 static void addRange(
const LuceneObjectPtr& builder, int32_t valSize, int64_t minBound, int64_t maxBound, int32_t shift);
155 virtual void addRange(
const String& minPrefixCoded,
const String& maxPrefixCoded);
159 virtual void addRange(int64_t min, int64_t max, int32_t shift);
169 virtual void addRange(
const String& minPrefixCoded,
const String& maxPrefixCoded);
173 virtual void addRange(int32_t min, int32_t max, int32_t shift);
boost::shared_ptr< LuceneObject > LuceneObjectPtr
Definition: LuceneTypes.h:539
Definition: NumericUtils.h:162
Callback for splitLongRange. You need to overwrite only one of the methods. NOTE: This is a very low-...
Definition: NumericUtils.h:148
This is a helper class to generate prefix-encoded representations for numerical values and supplies c...
Definition: NumericUtils.h:37
static const wchar_t SHIFT_START_INT
Integers are stored at lower precision by shifting off lower bits. The shift count is stored as SHIFT...
Definition: NumericUtils.h:58
static const int32_t BUF_SIZE_LONG
The maximum term length (used for char[] buffer size) for encoding long values.
Definition: NumericUtils.h:54
static const wchar_t SHIFT_START_LONG
Longs are stored at lower precision by shifting off lower bits. The shift count is stored as SHIFT_ST...
Definition: NumericUtils.h:50
boost::shared_ptr< LongRangeBuilder > LongRangeBuilderPtr
Definition: LuceneTypes.h:538
Base class for all Lucene classes.
Definition: LuceneObject.h:31
#define LUCENE_CLASS(Name)
Definition: LuceneObject.h:24
Definition: AbstractAllTermDocs.h:12
boost::shared_ptr< IntRangeBuilder > IntRangeBuilderPtr
Definition: LuceneTypes.h:537
static const int32_t BUF_SIZE_INT
The maximum term length (used for char[] buffer size) for encoding int values.
Definition: NumericUtils.h:62