|
MediaWiki
REL1_19
|
Search engine hook base class for IBM DB2. More...


Public Member Functions | |
| __construct ($db) | |
| Creates an instance of this class. | |
| getIndexField ($fulltext) | |
| Picks which field to index on, depending on what type of query. | |
| getQuery ($filteredTerm, $fulltext) | |
| Construct the full SQL query to do the search. | |
| parseQuery ($filteredText, $fulltext) | |
| queryLimit ($sql) | |
| Return a LIMIT clause to limit results on the query. | |
| queryMain ($filteredTerm, $fulltext) | |
| Get the base part of the search query. | |
| queryNamespaces () | |
| Return a partial WHERE clause to limit the search to the given namespaces. | |
| queryRanking ($filteredTerm, $fulltext) | |
| Does not do anything for generic search engine subclasses may define this though. | |
| queryRedirect () | |
| Return a partial WHERE clause to exclude redirects, if so set. | |
| searchText ($term) | |
| Perform a full text search query and return a result set. | |
| searchTitle ($term) | |
| Perform a title-only search query and return a result set. | |
| update ($id, $title, $text) | |
| Create or update the search index record for the given page. | |
| updateTitle ($id, $title) | |
| Update a search index record's title only. | |
Search engine hook base class for IBM DB2.
Definition at line 31 of file SearchIBM_DB2.php.
| SearchIBM_DB2::__construct | ( | $ | db | ) |
Creates an instance of this class.
| $db | DatabaseIbm_db2: database object |
Reimplemented from SearchEngine.
Definition at line 37 of file SearchIBM_DB2.php.
References SearchEngine\$db.
| SearchIBM_DB2::getIndexField | ( | $ | fulltext | ) |
Picks which field to index on, depending on what type of query.
| $fulltext | Boolean |
Definition at line 128 of file SearchIBM_DB2.php.
Referenced by parseQuery().

| SearchIBM_DB2::getQuery | ( | $ | filteredTerm, |
| $ | fulltext | ||
| ) |
Construct the full SQL query to do the search.
The guts shoulds be constructed in queryMain()
| $filteredTerm | String |
| $fulltext | Boolean |
Definition at line 115 of file SearchIBM_DB2.php.
References queryLimit(), queryMain(), queryNamespaces(), queryRanking(), and queryRedirect().

| SearchIBM_DB2::parseQuery | ( | $ | filteredText, |
| $ | fulltext | ||
| ) |
Definition at line 149 of file SearchIBM_DB2.php.
References $t, $wgContLang, getIndexField(), and SearchEngine\legalSearchChars().
Referenced by queryMain().


| SearchIBM_DB2::queryLimit | ( | $ | sql | ) |
Return a LIMIT clause to limit results on the query.
Definition at line 94 of file SearchIBM_DB2.php.
Referenced by getQuery().

| SearchIBM_DB2::queryMain | ( | $ | filteredTerm, |
| $ | fulltext | ||
| ) |
Get the base part of the search query.
| $filteredTerm | String |
| $fulltext | Boolean |
Definition at line 139 of file SearchIBM_DB2.php.
References $page, and parseQuery().
Referenced by getQuery().


Return a partial WHERE clause to limit the search to the given namespaces.
Definition at line 80 of file SearchIBM_DB2.php.
References SearchEngine\$namespaces.
Referenced by getQuery().

| SearchIBM_DB2::queryRanking | ( | $ | filteredTerm, |
| $ | fulltext | ||
| ) |
Does not do anything for generic search engine subclasses may define this though.
Definition at line 103 of file SearchIBM_DB2.php.
Referenced by getQuery().

Return a partial WHERE clause to exclude redirects, if so set.
Definition at line 68 of file SearchIBM_DB2.php.
Referenced by getQuery().

| SearchIBM_DB2::searchText | ( | $ | term | ) |
Perform a full text search query and return a result set.
| $term | String: raw search term |
Reimplemented from SearchEngine.
Definition at line 47 of file SearchIBM_DB2.php.
| SearchIBM_DB2::searchTitle | ( | $ | term | ) |
Perform a title-only search query and return a result set.
| $term | String: taw search term |
Reimplemented from SearchEngine.
Definition at line 58 of file SearchIBM_DB2.php.
| SearchIBM_DB2::update | ( | $ | id, |
| $ | title, | ||
| $ | text | ||
| ) |
Create or update the search index record for the given page.
Title and text should be pre-processed.
| $id | Integer |
| $title | String |
| $text | String |
Reimplemented from SearchEngine.
Definition at line 201 of file SearchIBM_DB2.php.
References $title, and wfGetDB().

| SearchIBM_DB2::updateTitle | ( | $ | id, |
| $ | title | ||
| ) |
Update a search index record's title only.
Title should be pre-processed.
| $id | Integer |
| $title | String |
Reimplemented from SearchEngine.
Definition at line 222 of file SearchIBM_DB2.php.
References $title, and wfGetDB().
