Stores information about how to sort documents by terms in an individual field. Fields must be indexed in order to sort by them.
More...
|
| SortField (const String &field, int32_t type, bool reverse=false) |
| Creates a sort by terms in the given field with the type of term values explicitly given. More...
|
|
| SortField (const String &field, const ParserPtr &parser, bool reverse=false) |
| Creates a sort, possibly in reverse, by terms in the given field, parsed to numeric values using a custom Parser . More...
|
|
| SortField (const String &field, const std::locale &locale, bool reverse=false) |
| Creates a sort, possibly in reverse, by terms in the given field sorted according to the given locale. More...
|
|
| SortField (const String &field, const FieldComparatorSourcePtr &comparator, bool reverse=false) |
| Creates a sort, possibly in reverse, with a custom comparison function. More...
|
|
virtual | ~SortField () |
|
virtual String | getClassName () |
|
boost::shared_ptr< SortField > | shared_from_this () |
|
String | getField () |
| Returns the name of the field. Could return null if the sort is by SCORE or DOC. More...
|
|
int32_t | getType () |
| Returns the type of contents in the field. More...
|
|
localePtr | getLocale () |
| Returns the Locale by which term values are interpreted. More...
|
|
ParserPtr | getParser () |
| Returns the instance of a FieldCache parser that fits to the given sort type. May return null if no parser was specified. Sorting is using the default parser then. More...
|
|
bool | getReverse () |
| Returns whether the sort should be reversed. More...
|
|
FieldComparatorSourcePtr | getComparatorSource () |
| Returns the FieldComparatorSource used for custom sorting. More...
|
|
virtual String | toString () |
| Returns a string representation of the object. More...
|
|
virtual bool | equals (const LuceneObjectPtr &other) |
| Returns true if other is equal to this. If a FieldComparatorSource or Parser was provided, it must properly implement equals (unless a singleton is always used). More...
|
|
virtual int32_t | hashCode () |
| Return hash code for this object. More...
|
|
FieldComparatorPtr | getComparator (int32_t numHits, int32_t sortPos) |
| Returns the FieldComparator to use for sorting. More...
|
|
virtual | ~LuceneObject () |
|
virtual void | initialize () |
| Called directly after instantiation to create objects that depend on this object being fully constructed. More...
|
|
virtual LuceneObjectPtr | clone (const LuceneObjectPtr &other=LuceneObjectPtr()) |
| Return clone of this object. More...
|
|
virtual int32_t | hashCode () |
| Return hash code for this object. More...
|
|
virtual bool | equals (const LuceneObjectPtr &other) |
| Return whether two objects are equal. More...
|
|
virtual int32_t | compareTo (const LuceneObjectPtr &other) |
| Compare two objects. More...
|
|
virtual String | toString () |
| Returns a string representation of the object. More...
|
|
virtual | ~LuceneSync () |
|
virtual SynchronizePtr | getSync () |
| Return this object synchronize lock. More...
|
|
virtual LuceneSignalPtr | getSignal () |
| Return this object signal. More...
|
|
virtual void | lock (int32_t timeout=0) |
| Lock this object using an optional timeout. More...
|
|
virtual void | unlock () |
| Unlock this object. More...
|
|
virtual bool | holdsLock () |
| Returns true if this object is currently locked by current thread. More...
|
|
virtual void | wait (int32_t timeout=0) |
| Wait for signal using an optional timeout. More...
|
|
virtual void | notifyAll () |
| Notify all threads waiting for signal. More...
|
|
|
static const int32_t | SCORE |
| Sort by document score (relevancy). Sort values are Double and higher values are at the front. More...
|
|
static const int32_t | DOC |
| Sort by document number (index order). Sort values are Integer and lower values are at the front. More...
|
|
static const int32_t | STRING |
| Sort using term values as Strings. Sort values are String and lower values are at the front. More...
|
|
static const int32_t | INT |
| Sort using term values as Integers. Sort values are Integer and lower values are at the front. More...
|
|
static const int32_t | FLOAT |
| Sort using term values as Floats. Sort values are Float and lower values are at the front. More...
|
|
static const int32_t | LONG |
| Sort using term values as Longs. Sort values are Long and lower values are at the front. More...
|
|
static const int32_t | DOUBLE |
| Sort using term values as Doubles. Sort values are Double and lower values are at the front. More...
|
|
static const int32_t | SHORT |
| Sort using term values as Shorts. Sort values are Short and lower values are at the front. More...
|
|
static const int32_t | CUSTOM |
| Sort using a custom Comparator. Sort values are any ComparableValue and sorting is done according to natural order. More...
|
|
static const int32_t | BYTE |
| Sort using term values as Bytes. Sort values are Byte and lower values are at the front. More...
|
|
static const int32_t | STRING_VAL |
| Sort using term values as Strings, but comparing by value (using String::compare) for all comparisons. This is typically slower than STRING , which uses ordinals to do the sorting. More...
|
|
Stores information about how to sort documents by terms in an individual field. Fields must be indexed in order to sort by them.