|
a/src/rcldb/rcldb.h |
|
b/src/rcldb/rcldb.h |
|
... |
|
... |
104 |
string getReason() const {return m_reason;}
|
104 |
string getReason() const {return m_reason;}
|
105 |
|
105 |
|
106 |
/** List possible stemmer names */
|
106 |
/** List possible stemmer names */
|
107 |
static list<string> getStemmerNames();
|
107 |
static list<string> getStemmerNames();
|
108 |
|
108 |
|
|
|
109 |
/** Test word for spelling correction candidate: not too long, no
|
|
|
110 |
special chars... */
|
|
|
111 |
static bool isSpellingCandidate(const string& term)
|
|
|
112 |
{
|
|
|
113 |
if (term.empty() || term.length() > 50)
|
|
|
114 |
return false;
|
|
|
115 |
if (term.find_first_of(" !\"#$%&()*+,-./0123456789:;<=>?@[\\]^_`{|}~")
|
|
|
116 |
!= string::npos)
|
|
|
117 |
return false;
|
|
|
118 |
return true;
|
|
|
119 |
}
|
|
|
120 |
|
109 |
/** List existing stemming databases */
|
121 |
/** List existing stemming databases */
|
110 |
std::list<std::string> getStemLangs();
|
122 |
std::list<std::string> getStemLangs();
|
|
|
123 |
|
|
|
124 |
#ifdef TESTING_XAPIAN_SPELL
|
|
|
125 |
/** Return spelling suggestion */
|
|
|
126 |
string getSpellingSuggestion(const string& word);
|
|
|
127 |
#endif
|
111 |
|
128 |
|
112 |
/* The next two, only for searchdata, should be somehow hidden */
|
129 |
/* The next two, only for searchdata, should be somehow hidden */
|
113 |
/* Return list of configured stop words */
|
130 |
/* Return list of configured stop words */
|
114 |
const StopList& getStopList() const {return m_stops;}
|
131 |
const StopList& getStopList() const {return m_stops;}
|
115 |
/* Field name to prefix translation (ie: author -> 'A') */
|
132 |
/* Field name to prefix translation (ie: author -> 'A') */
|