Handle a string range.
More...
#include <queryparser.h>
|
Xapian::valueno | valno |
| The value slot to process.
|
|
bool | prefix |
| Whether to look for str as a prefix or suffix.
|
|
std::string | str |
| The prefix (or suffix if prefix==false) string to look for.
|
|
Handle a string range.
The end points can be any strings.
- Deprecated:
- Use Xapian::RangeProcessor instead (added in 1.3.6).
◆ StringValueRangeProcessor() [1/2]
Xapian::StringValueRangeProcessor::StringValueRangeProcessor |
( |
Xapian::valueno |
slot_ | ) |
|
|
inlineexplicit |
Constructor.
- Parameters
-
slot_ | The value number to return from operator(). |
◆ StringValueRangeProcessor() [2/2]
Xapian::StringValueRangeProcessor::StringValueRangeProcessor |
( |
Xapian::valueno |
slot_, |
|
|
const std::string & |
str_, |
|
|
bool |
prefix_ = true |
|
) |
| |
|
inline |
Constructor.
- Parameters
-
slot_ | The value number to return from operator(). |
str_ | A string to look for to recognise values as belonging to this range. |
prefix_ | Flag specifying whether to check for str_ as a prefix or a suffix. |
◆ operator()()
Xapian::valueno Xapian::StringValueRangeProcessor::operator() |
( |
std::string & |
begin, |
|
|
std::string & |
end |
|
) |
| |
|
virtual |
Check for a valid string range.
- Parameters
-
[in,out] | begin | The start of the range as specified in the query string by the user. This parameter is a non-const reference so the ValueRangeProcessor can modify it to return the value to start the range with. |
[in,out] | end | The end of the range. This is also a non-const reference so it can be modified. |
- Returns
- A StringValueRangeProcessor always accepts a range it is offered, and returns the value of slot_ passed at construction time. It doesn't modify begin or end.
Implements Xapian::ValueRangeProcessor.
The documentation for this class was generated from the following file: