CWIS Developer Documentation

- Home
- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Static Public Member Functions | List of all members
SPTSearchEngine Class Reference
Inheritance diagram for SPTSearchEngine:
[legend]
Collaboration diagram for SPTSearchEngine:
[legend]

## Public Member Functions
| SPTSearchEngine ()
| GetFieldContent ($ItemId, $FieldName)
| SearchFieldForPhrases ($FieldName, $Phrase)
| SearchFieldsForComparisonMatches ($FieldNames, $Operators, $Values)
| UpdateForResource ($ItemId)
Public Member Functions inherited from SearchEngine
| SearchEngine (&$DB, $ItemTableName, $ItemIdFieldName)
| AddField ($FieldName, $DBFieldName, $FieldType, $Weight, $UsedInKeywordSearch)
| ItemTableName ()
| ItemIdFieldName ()
| DBFieldName ($FieldName)
| FieldType ($FieldName)
| FieldWeight ($FieldName)
| FieldInKeywordSearch ($FieldName)
| DebugLevel ($Setting)
| Search ($SearchString, $StartingResult=0, $NumberOfResults=10, $SortByField=NULL, $SortDescending=TRUE)
| FieldedSearch ($SearchStrings, $StartingResult=0, $NumberOfResults=10, $SortByField=NULL, $SortDescending=TRUE)
| GroupedSearch ($SearchGroups, $StartingResult=0, $NumberOfResults=10, $SortByField=NULL, $SortDescending=TRUE)
| AddResultFilterFunction ($FunctionName)
| DefaultSearchLogic ($NewSetting=NULL)
| SearchTermsRequiredByDefault ($NewSetting=TRUE)
| NumberOfResults ()
| SearchTerms ()
| SearchTime ()
| FieldedSearchWeightScale ($SearchStrings)
| UpdateForItem ($ItemId)
| UpdateForItems ($StartingItemId, $NumberOfItems)
| DropItem ($ItemId)
| DropField ($FieldName)
| SearchTermCount ()
| ItemCount ()
| AddSynonyms ($Word, $Synonyms)
| Add synonyms.
| RemoveSynonyms ($Word, $Synonyms=NULL)
| RemoveAllSynonyms ()
| GetSynonyms ($Word)
| GetAllSynonyms ()
| SetAllSynonyms ($SynonymList)
| LoadSynonymsFromFile ($FileName)
| Load synonyms from a file.
| SuggestAlternateSearches ($SearchString)

## Static Public Member Functions
static | GetItemIdsSortedByField ($FieldName, $SortDescending)
static | QueueUpdateForItem ($ItemId, $Priority=ApplicationFramework::PRIORITY_LOW)
static | RunUpdateForItem ($ItemId)

## Additional Inherited Members
Public Attributes inherited from SearchEngine
const | LOGIC_AND = 1
const | LOGIC_OR = 2
const | FIELDTYPE_TEXT = 1
const | FIELDTYPE_NUMERIC = 2
const | FIELDTYPE_DATE = 3
const | FIELDTYPE_DATERANGE = 4
const | STEM_ID_OFFSET = 1000000
const | SEARCHLOGIC_AND = 1
const | SEARCHLOGIC_OR = 2
Protected Member Functions inherited from SearchEngine
| GetFieldId ($FieldName)
| SearchFieldForPhrases ($FieldName, $Phrase)
| FilterOnSuppliedFunctions ($Scores)
| GetFieldContent ($ItemId, $FieldName)
| DMsg ($Level, $Msg)
Protected Attributes inherited from SearchEngine
| $DB
| $DebugLevel
| $ItemTableName
| $ItemIdFieldName
| $NumberOfResultsAvailable
| $LastSearchTime
| $FilterFuncs
| $DefaultSearchLogic = self::LOGIC_AND
| $StemmingEnabled = TRUE
| $SynonymsEnabled = TRUE

## Detailed Description

Definition at line 10 of file SPTSearchEngine.php.

## Member Function Documentation

SPTSearchEngine::GetFieldContent | ( |  | $ItemId,
|  |  | $FieldName
| ) |  |

Definition at line 73 of file SPTSearchEngine.php.

static SPTSearchEngine::GetItemIdsSortedByField | ( |  | $FieldName,
|  |  | $SortDescending
| ) |  |
| static

Definition at line 506 of file SPTSearchEngine.php.

static SPTSearchEngine::QueueUpdateForItem | ( |  | $ItemId,
|  |  | $Priority = `ApplicationFramework::PRIORITY_LOW`
| ) |  |
| static

Definition at line 512 of file SPTSearchEngine.php.

static SPTSearchEngine::RunUpdateForItem | ( |  | $ItemId | ) |
| static

Definition at line 520 of file SPTSearchEngine.php.

References SPTSearchEngine().

SPTSearchEngine::SearchFieldForPhrases | ( |  | $FieldName,
|  |  | $Phrase
| ) |  |

Definition at line 83 of file SPTSearchEngine.php.

References SearchEngine\DebugLevel(), SearchEngine\DMsg(), MetadataSchema\MDFTYPE_CONTROLLEDNAME, MetadataSchema\MDFTYPE_DATE, MetadataSchema\MDFTYPE_FILE, MetadataSchema\MDFTYPE_FLAG, MetadataSchema\MDFTYPE_IMAGE, MetadataSchema\MDFTYPE_NUMBER, MetadataSchema\MDFTYPE_OPTION, MetadataSchema\MDFTYPE_PARAGRAPH, MetadataSchema\MDFTYPE_TEXT, MetadataSchema\MDFTYPE_TIMESTAMP, MetadataSchema\MDFTYPE_TREE, MetadataSchema\MDFTYPE_URL, and MetadataSchema\MDFTYPE_USER.

SPTSearchEngine::SearchFieldsForComparisonMatches | ( |  | $FieldNames,
|  |  | $Operators,
|  |  | $Values
| ) |  |

Definition at line 212 of file SPTSearchEngine.php.

References SearchEngine\DefaultSearchLogic(), SearchEngine\DMsg(), MetadataSchema\MDFTYPE_CONTROLLEDNAME, MetadataSchema\MDFTYPE_DATE, MetadataSchema\MDFTYPE_FILE, MetadataSchema\MDFTYPE_FLAG, MetadataSchema\MDFTYPE_IMAGE, MetadataSchema\MDFTYPE_NUMBER, MetadataSchema\MDFTYPE_OPTION, MetadataSchema\MDFTYPE_PARAGRAPH, MetadataSchema\MDFTYPE_TEXT, MetadataSchema\MDFTYPE_TIMESTAMP, MetadataSchema\MDFTYPE_TREE, MetadataSchema\MDFTYPE_URL, and MetadataSchema\MDFTYPE_USER.

SPTSearchEngine::SPTSearchEngine | ( |  | ) |

Definition at line 12 of file SPTSearchEngine.php.

References SearchEngine\$DB, SearchEngine\AddField(), MetadataSchema\MDFTYPE_CONTROLLEDNAME, MetadataSchema\MDFTYPE_DATE, MetadataSchema\MDFTYPE_FILE, MetadataSchema\MDFTYPE_FLAG, MetadataSchema\MDFTYPE_IMAGE, MetadataSchema\MDFTYPE_NUMBER, MetadataSchema\MDFTYPE_OPTION, MetadataSchema\MDFTYPE_PARAGRAPH, MetadataSchema\MDFTYPE_POINT, MetadataSchema\MDFTYPE_TEXT, MetadataSchema\MDFTYPE_TIMESTAMP, MetadataSchema\MDFTYPE_TREE, MetadataSchema\MDFTYPE_URL, MetadataSchema\MDFTYPE_USER, and SearchEngine\SearchEngine().

Referenced by RunUpdateForItem().

Here is the caller graph for this function:

SPTSearchEngine::UpdateForResource | ( |  | $ItemId | ) |

Definition at line 534 of file SPTSearchEngine.php.

References SearchEngine\UpdateForItem().

The documentation for this class was generated from the following file:

- objects/SPTSearchEngine.php