cacheFile
in
Cache file objekt
Table of Contents
EXTENSION_CACHE | '.cache' | |
---|---|---|
$path | fulle cache file path | string |
$module | Cache | |
$expires | Cache | |
__construct() | Konstruktor | mixed |
write() | Write content to cache file | bool |
read() | Read cache file content | mixed|null |
expires() | Fetch expiration time | mixed|null |
cleanup() | Cleanup cache file | bool |
initCacheName() | Initialize cache name | string |
initCacheModule() | Initialize cache module name | string |
getExt() | Return extension for cache file | string |
getType() | Return path type | string |
Constants
EXTENSION_CACHE
mixed
$EXTENSION_CACHE
= '.cache'
Properties
$path
fulle cache file path
private
string
$path
$module
private
Cache
$module
$expires
private
Cache
$expires
= null
Methods
__construct()
Konstruktor
public
__construct(
$cacheName :
string
)
: mixed
Parameters
- $cacheName : string
Return values
mixedwrite()
Write content to cache file
public
write(
$data :
mixed
, $expires :
int
)
: bool
Parameters
- $data : mixed
- $expires : int
Return values
boolread()
Read cache file content
public
read(
[ $raw :
bool
= false ]
)
: mixed|null
Parameters
- $raw : bool = false
Return values
mixed|nullexpires()
Fetch expiration time
public
expires(
)
: mixed|null
Return values
mixed|nullcleanup()
Cleanup cache file
public
cleanup(
)
: bool
Return values
boolinitCacheName()
Initialize cache name
protected
initCacheName(
$cacheName :
string
)
: string
Parameters
- $cacheName : string
Return values
stringinitCacheModule()
Initialize cache module name
protected
initCacheModule(
$module :
string
)
: string
Parameters
- $module : string
Tags
Return values
stringgetExt()
Return extension for cache file
protected
getExt(
)
: string
Return values
stringgetType()
Return path type
protected
getType(
)
: string