[ Index ]

PHP Cross Reference of MediaWiki-1.24.0

title

Body

[close]

/includes/search/ -> SearchOracle.php (summary)

Oracle search engine Copyright © 2004 Brion Vibber <[email protected]> https://www.mediawiki.org/

File Size: 273 lines (7 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

SearchOracle:: (13 methods):
  searchText()
  searchTitle()
  queryNamespaces()
  queryLimit()
  queryRanking()
  getQuery()
  getIndexField()
  queryMain()
  parseQuery()
  escapeTerm()
  update()
  updateTitle()
  legalSearchChars()


Class: SearchOracle  - X-Ref

Search engine hook base class for Oracle (ConText).

searchText( $term )   X-Ref
Perform a full text search query and return a result set.

param: string $term Raw search term
return: SqlSearchResultSet

searchTitle( $term )   X-Ref
Perform a title-only search query and return a result set.

param: string $term Raw search term
return: SqlSearchResultSet

queryNamespaces()   X-Ref
Return a partial WHERE clause to limit the search to the given namespaces

return: string

queryLimit( $sql )   X-Ref
Return a LIMIT clause to limit results on the query.

param: string $sql
return: string

queryRanking( $filteredTerm, $fulltext )   X-Ref
Does not do anything for generic search engine
subclasses may define this though

param: string $filteredTerm
param: bool $fulltext
return: string

getQuery( $filteredTerm, $fulltext )   X-Ref
Construct the full SQL query to do the search.
The guts shoulds be constructed in queryMain()

param: string $filteredTerm
param: bool $fulltext
return: string

getIndexField( $fulltext )   X-Ref
Picks which field to index on, depending on what type of query.

param: bool $fulltext
return: string

queryMain( $filteredTerm, $fulltext )   X-Ref
Get the base part of the search query.

param: string $filteredTerm
param: bool $fulltext
return: string

parseQuery( $filteredText, $fulltext )   X-Ref
Parse a user input search string, and return an SQL fragment to be used
as part of a WHERE clause

param: string $filteredText
param: bool $fulltext
return: string

escapeTerm( $t )   X-Ref
No description

update( $id, $title, $text )   X-Ref
Create or update the search index record for the given page.
Title and text should be pre-processed.

param: int $id
param: string $title
param: string $text

updateTitle( $id, $title )   X-Ref
Update a search index record's title only.
Title should be pre-processed.

param: int $id
param: string $title

legalSearchChars()   X-Ref
No description



Generated: Fri Nov 28 14:03:12 2014 Cross-referenced by PHPXref 0.7.1