include/SugarSearchEngine/Interface.php
\SugarSearchEngineInterface
Generic interface all sublcasses must implement in order to be pluggable with FTS.
- Children
- \SugarSearchEngine
- \SugarSearchEngineAbstractBase
- Api
Methods
bulkInsert(
$docs
)
:
void
Perform bulk inserts on serveral documents to mitigate performance issues.
Name | Type | Description |
---|---|---|
$docs |
- Abstract
createIndex(
boolean $recreate
=
false
)
:
void
Create the index
Name | Type | Description |
---|---|---|
$recreate | boolean | OPTIONAL Deletes index first if already exists (default = false) |
- Abstract
createIndexDocument(
\SugarBean}stdClass $bean, array | null $searchFields
=
null
)
:
void
Create the index document that will be sent to the IR System.
Name | Type | Description |
---|---|---|
$bean | \SugarBean}stdClass | |
$searchFields | array | null |
- Abstract
delete(
$bean
)
:
void
Delete a bean from the Full Text Search Engine
Name | Type | Description |
---|---|---|
$bean |
- Abstract
getServerStatus(
)
:
array
Return info about the server status.
Type | Description |
---|---|
array | valid: indicates if the connection was successful. status: text to display to the end user |
- Abstract
indexBean(
$bean, $batched
=
TRUE
)
:
void
Pass in a bean and go through the list of fields to pass to the engine
Name | Type | Description |
---|---|---|
$bean | ||
$batched |
- Abstract
\SugarSearchEngineResult
Interface for a single FTS result.
- Children
- \SugarSearchEngineAbstractResult
Methods
__toString(
)
:
void
Never called within the view but helpful for debugging purposes.
- Abstract
getHighlightedHitText(
)
:
void
Return the highlighted text of a hit with the field name as the key
- Abstract
getId(
)
:
String
Get the id of the result
Type | Description |
---|---|
String | The id of the result, typically a SugarBean id. |
- Abstract
getModule(
)
:
String
Get the module name of the result
Type | Description |
---|---|
String |
- Abstract
getModuleName(
)
:
String
Get the translated module name of the result
Type | Description |
---|---|
String |
- Abstract
\SugarSearchEngineResultSet
Interface to access results from a FTS search. Is composed of zero or more SugarSearchEngineResult objects.
- Parent(s)
- \Iterator
- Children
- \SugarSeachEngineElasticResultSet