abstract class vB_Search_Core

Traits

Constants

OP_EQ

OP_NEQ

OP_LT

OP_GT

TYPE_COMMON

Methods

__sleep()

No description

__wakeup()

No description

static 
instance()

No description

getResults(vB_Search_Criteria $criteria)

No description

indexText($node, $title, $text, $skip_prev_index = false)

No description

delete($nodeid, $node = false)

No description

indexTrending($lookback, $minimum)

No description

getTwoPassResults(vB_Search_Criteria $criteria)

No description

index(int $node_id, boolean $propagate = true)

Index a node

reIndexAll()

No description

attributeChanged(int|array $nodeid)

this function should be called whenever an attribute changes in the node table

emptyIndex()

No description

indexChildAttachment($node_id, $parentTitle, $parentText)

No description

getNodeToIndex($node)

No description

getParentNodeId($nodeid)

No description

getTitleAndText($node, $propagate = true)

No description

purgeCacheForUser($userid, $from = false)

No description

clean()

No description

mixed
cacheResults($nodeIds, $criteria, $searchtime = 0, $searchType = 0)

Caches the results

getFromCache(vB_Search_Criteria $criteria, $search_json)

No description

removeNodeFromResult($nodeid, $result, $perpage, $pagenumber, $getStarterInfo)

No description

getCache($resultId)

No description

floodCheck()

No description

generateHash($json)

No description

static 
saveSecondPassResults($results, $cacheKey, $parentid = false)

No description

static string
getTwoPassCacheKey(vB_Search_Criteria $criteria)

Generate a cache key for the first pass of getSearchResults. Build key based on: usergroupids, infractiongroupids, search json, search sort order, search sort by, moderated channels

Details

in vB_Trait_NoSerialize at line 15
__sleep()

in vB_Trait_NoSerialize at line 20
__wakeup()

at line 23
static instance()

at line 39
abstract getResults(vB_Search_Criteria $criteria)

Parameters

vB_Search_Criteria $criteria

at line 41
abstract indexText($node, $title, $text, $skip_prev_index = false)

Parameters

$node
$title
$text
$skip_prev_index

at line 43
abstract delete($nodeid, $node = false)

Parameters

$nodeid
$node

at line 45
abstract indexTrending($lookback, $minimum)

Parameters

$lookback
$minimum

at line 47
getTwoPassResults(vB_Search_Criteria $criteria)

Parameters

vB_Search_Criteria $criteria

at line 77
index(int $node_id, boolean $propagate = true)

Index a node

Parameters

int $node_id to index
boolean $propagate flag to propagate the indexing to the nodes parents

at line 146
abstract reIndexAll()

at line 153
attributeChanged(int|array $nodeid)

this function should be called whenever an attribute changes in the node table

Parameters

int|array $nodeid

at line 158
emptyIndex()

at line 168
protected indexChildAttachment($node_id, $parentTitle, $parentText)

Parameters

$node_id
$parentTitle
$parentText

at line 188
protected getNodeToIndex($node)

Parameters

$node

at line 207
protected getParentNodeId($nodeid)

Parameters

$nodeid

at line 221
protected getTitleAndText($node, $propagate = true)

Parameters

$node
$propagate

at line 247
purgeCacheForUser($userid, $from = false)

Parameters

$userid
$from

at line 270
clean()

at line 287
mixed cacheResults($nodeIds, $criteria, $searchtime = 0, $searchType = 0)

Caches the results

Parameters

$nodeIds
$criteria
$searchtime
$searchType

Return Value

mixed array of strings and integers- see details below.

at line 306
getFromCache(vB_Search_Criteria $criteria, $search_json)

Parameters

vB_Search_Criteria $criteria
$search_json

at line 416
removeNodeFromResult($nodeid, $result, $perpage, $pagenumber, $getStarterInfo)

Parameters

$nodeid
$result
$perpage
$pagenumber
$getStarterInfo

at line 432
getCache($resultId)

Parameters

$resultId

at line 440
floodCheck()

at line 488
protected generateHash($json)

Parameters

$json

at line 501
static saveSecondPassResults($results, $cacheKey, $parentid = false)

Parameters

$results
$cacheKey
$parentid

at line 555
static string getTwoPassCacheKey(vB_Search_Criteria $criteria)

Generate a cache key for the first pass of getSearchResults. Build key based on: usergroupids, infractiongroupids, search json, search sort order, search sort by, moderated channels

Parameters

vB_Search_Criteria $criteria

Return Value

string