PHP Class BxDolCacheFile, dolphin.pro

Inheritance: extends BxDolCache
Afficher le fichier Open project: boonex/dolphin.pro Class Usage Examples

Méthodes publiques

Свойство Type Description
$sPath

Méthodes publiques

Méthode Description
__construct ( ) constructor
_removeFileIfTtlExpired ( string $sFile, integer $iTTL ) : true remove file from dist if TTL expored
delData ( string $sKey ) : result Delete cache file.
getData ( string $sKey, integer $iTTL = false ) : the Get all data from the cache file.
getSizeByPrefix ( $s ) get size of cached data by name prefix
removeAllByPrefix ( $s ) : true remove all data from cache by key prefix
setData ( string $sKey, mixed $mixedData, integer $iTTL = false ) : boolean Save all data in cache file.

Method Details

__construct() public méthode

constructor
public __construct ( )

_removeFileIfTtlExpired() public méthode

remove file from dist if TTL expored
public _removeFileIfTtlExpired ( string $sFile, integer $iTTL ) : true
$sFile string - full path to filename
$iTTL integer - time to live in seconds
Résultat true if TTL is expired and file is deleted or false otherwise

delData() public méthode

Delete cache file.
public delData ( string $sKey ) : result
$sKey string - file name
Résultat result of the operation

getData() public méthode

Get all data from the cache file.
public getData ( string $sKey, integer $iTTL = false ) : the
$sKey string - file name
$iTTL integer - time to live
Résultat the data is got from cache.

getSizeByPrefix() public méthode

get size of cached data by name prefix
public getSizeByPrefix ( $s )

removeAllByPrefix() public méthode

remove all data from cache by key prefix
public removeAllByPrefix ( $s ) : true
Résultat true on success

setData() public méthode

Save all data in cache file.
public setData ( string $sKey, mixed $mixedData, integer $iTTL = false ) : boolean
$sKey string - file name
$mixedData mixed - the data to be cached in the file
$iTTL integer - time to live
Résultat boolean result of operation.

Property Details

$sPath public_oe property

public $sPath