Represents field values as different types. Normally created via a ValueSuorce for a particular field and reader.
More...
#include <DocValues.h>
Represents field values as different types. Normally created via a ValueSuorce for a particular field and reader.
DocValues is distinct from ValueSource because there needs to be an object created at query evaluation time that is not referenced by the query itself because:
- Query objects should be MT safe
- For caching, Query objects are often used as keys... you don't want the Query carrying around big objects
Lucene::DocValues::DocValues |
( |
| ) |
|
virtual Lucene::DocValues::~DocValues |
( |
| ) |
|
|
virtual |
static String Lucene::DocValues::_getClassName |
( |
| ) |
|
|
inlinestatic |
void Lucene::DocValues::compute |
( |
| ) |
|
|
protected |
virtual double Lucene::DocValues::doubleVal |
( |
int32_t |
doc | ) |
|
|
pure virtual |
Return doc value as a double. Mandatory: every DocValues implementation must implement at least this method.
- Parameters
-
doc | document whose double value is requested. |
Implemented in Lucene::DoubleDocValues.
Explain the scoring value for the input doc.
virtual double Lucene::DocValues::getAverageValue |
( |
| ) |
|
|
virtual |
Returns the average of all values or NaN if this DocValues instance does not contain any value. This operation is optional.
- Returns
- the average of all values or NaN if this DocValues instance does not contain any value.
virtual String Lucene::DocValues::getClassName |
( |
| ) |
|
|
inlinevirtual |
virtual CollectionValue Lucene::DocValues::getInnerArray |
( |
| ) |
|
|
virtual |
For test purposes only, return the inner array of values, or null if not applicable.
Allows tests to verify that loaded values are:
-
indeed cached/reused.
-
stored in the expected size/type (byte/short/int/float).
Note: implementations of DocValues must override this method for these test elements to be tested, Otherwise the test would not fail, just print a warning.
Reimplemented in Lucene::DoubleDocValues.
virtual double Lucene::DocValues::getMaxValue |
( |
| ) |
|
|
virtual |
Returns the maximum of all values or NaN if this DocValues instance does not contain any value. This operation is optional.
- Returns
- the maximum of all values or NaN if this DocValues instance does not contain any value.
virtual double Lucene::DocValues::getMinValue |
( |
| ) |
|
|
virtual |
Returns the minimum of all values or NaN if this DocValues instance does not contain any value. This operation is optional.
- Returns
- the minimum of all values or NaN if this DocValues instance does not contain any value.
virtual int32_t Lucene::DocValues::intVal |
( |
int32_t |
doc | ) |
|
|
virtual |
Return doc value as an int. Optional: DocValues implementation can (but don't have to) override this method.
- Parameters
-
doc | document whose int value is requested. |
virtual int64_t Lucene::DocValues::longVal |
( |
int32_t |
doc | ) |
|
|
virtual |
Return doc value as a long. Optional: DocValues implementation can (but don't have to) override this method.
- Parameters
-
doc | document whose long value is requested. |
boost::shared_ptr< DocValues > Lucene::DocValues::shared_from_this |
( |
| ) |
|
|
inline |
virtual String Lucene::DocValues::strVal |
( |
int32_t |
doc | ) |
|
|
virtual |
Return doc value as a string. Optional: DocValues implementation can (but don't have to) override this method.
- Parameters
-
doc | document whose string value is requested. |
virtual String Lucene::DocValues::toString |
( |
int32_t |
doc | ) |
|
|
pure virtual |
Return a string representation of a doc value, as required for Explanations.
Implemented in Lucene::DoubleDocValues.
double Lucene::DocValues::avgVal |
|
protected |
bool Lucene::DocValues::computed |
|
protected |
double Lucene::DocValues::maxVal |
|
protected |
double Lucene::DocValues::minVal |
|
protected |
The documentation for this class was generated from the following file: