abstract class vB_FastDS

Traits

Constants

TYPE_DATASTORE

TYPE_PHRASES

TYPE_TEMPLATES

Properties

static protected $enabled
static protected $fastInstance
protected $phrasesCached
protected $phRebuilt
protected $dsCached
protected $dsRebuilt
protected $templatesCached
protected $tmRebuilt
protected $prefix
protected $rebuilt
protected $language
protected $styleid
static protected $building
protected $skipDSCache

Methods

__sleep()

No description

__wakeup()

No description

static mixed
instance()

Returns a reference to the current fastDS object, or false

a
__construct($config)

standard constructor

restoreSettings($settings)

Restores the settings from APC

saveSettings()

No description

buildFastDS()

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

integer
buildPhrases(integer $maxSize)

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

integer
buildDatastore(integer $maxSize)

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

integer
buildTemplates(integer $maxSize)

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

mixed
getValue($prefix, $keys)

gets a value

bool
setValue($key, $value)

sets a value

bool
clearValue(mixed $key)

sets a value

mixed
getDS($dsKeys)

gets a datastore value

bool
setDS($dsKey, $value)

sets a datastore value

string
getPhrases($varnames, $languageid)

gets a phrase, or set of phrases, from the default language

bool
setPhrase($varname, $value)

sets a default language phrase

string-
getTemplates($templateNames, $styleid)

gets a template from the default style

bool
setTemplate($title, $value)

sets a template value

setDsChanged($title)

No description

Details

in vB_Trait_NoSerialize at line 15
__sleep()

in vB_Trait_NoSerialize at line 20
__wakeup()

at line 62
static mixed instance()

Returns a reference to the current fastDS object, or false

Return Value

mixed either a fastDS instance or false

at line 114
protected a __construct($config)

standard constructor

@param mixed The config object from vB::getConfig()

Parameters

$config

Return Value

a fastDS object

at line 155
protected restoreSettings($settings)

Restores the settings from APC

@param mixed the cached summary read from APC

Parameters

$settings

at line 218
protected saveSettings()

at line 232
buildFastDS()

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

at line 279
protected integer buildPhrases(integer $maxSize)

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

Parameters

integer $maxSize the maximum space allowed for caching this data.

Return Value

integer estimate of the space used. Note that we can't be exact.

at line 361
protected integer buildDatastore(integer $maxSize)

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

Parameters

integer $maxSize the maximum space allowed for caching this data.

Return Value

integer estimate of the space used. Note that we can't be exact.

at line 421
protected integer buildTemplates(integer $maxSize)

reBuilds the fastDS data. This is called if the cached value is lost, or after upgrade.

Parameters

integer $maxSize the maximum space allowed for caching this data.

Return Value

integer estimate of the space used. Note that we can't be exact.

at line 481
abstract protected mixed getValue($prefix, $keys)

gets a value

@param string

Parameters

$prefix
$keys

Return Value

mixed the value from fastDS

at line 490
abstract protected bool setValue($key, $value)

sets a value

@param string key

Parameters

$key
$value

Return Value

bool true if it succeeded, otherwise false

at line 499
abstract protected bool clearValue(mixed $key)

sets a value

@param string key

Parameters

mixed $key value to be stored

Return Value

bool true if it succeeded, otherwise false

at line 507
mixed getDS($dsKeys)

gets a datastore value

@param mixed string or array of string

Parameters

$dsKeys

Return Value

mixed the datastore value

at line 558
bool setDS($dsKey, $value)

sets a datastore value

@param string key

Parameters

$dsKey
$value

Return Value

bool true if it succeeded, otherwise false

at line 574
string getPhrases($varnames, $languageid)

gets a phrase, or set of phrases, from the default language

@param mixed string or array of strings

Parameters

$varnames
$languageid

Return Value

string

at line 603
protected bool setPhrase($varname, $value)

sets a default language phrase

@param string key

Parameters

$varname
$value

Return Value

bool true if it succeeded, otherwise false

at line 619
string- getTemplates($templateNames, $styleid)

gets a template from the default style

@param mixed string or array of string

Parameters

$templateNames
$styleid

Return Value

string- the template contents

at line 650
protected bool setTemplate($title, $value)

sets a template value

@param string key

Parameters

$title
$value

Return Value

bool true if it succeeded, otherwise false

at line 662
setDsChanged($title)

Parameters

$title