\Pop\Cache\AdapterApc

APC cache adapter class

Summary

Methods
Properties
Constants
__construct()
setTtl()
getTtl()
getItemTtl()
saveItem()
getItem()
hasItem()
deleteItem()
clear()
destroy()
getInfo()
No public properties found
No constants found
No protected methods found
$ttl
$apcu
N/A
No private methods found
No private properties found
N/A

Properties

$ttl

$ttl : integer

Global time-to-live

Type

integer

$apcu

$apcu : boolean

Flag for APCu

Type

boolean

Methods

__construct()

__construct(integer  $ttl) 

Constructor

Instantiate the APC cache object

Parameters

integer $ttl

Throws

\Pop\Cache\Adapter\Exception

setTtl()

setTtl(integer  $ttl) : \Pop\Cache\Adapter\AbstractAdapter

Set the global time-to-live for the cache adapter

Parameters

integer $ttl

Returns

\Pop\Cache\Adapter\AbstractAdapter

getTtl()

getTtl() : integer

Get the global time-to-live for the cache object

Returns

integer

getItemTtl()

getItemTtl(string  $id) : integer

Get the time-to-live for an item in cache

Parameters

string $id

Returns

integer

saveItem()

saveItem(string  $id, mixed  $value, integer  $ttl = null) : \Pop\Cache\Adapter\Apc

Save an item to cache

Parameters

string $id
mixed $value
integer $ttl

Returns

\Pop\Cache\Adapter\Apc

getItem()

getItem(string  $id) : mixed

Get an item from cache

Parameters

string $id

Returns

mixed

hasItem()

hasItem(string  $id) : boolean

Determine if the item exist in cache

Parameters

string $id

Returns

boolean

deleteItem()

deleteItem(string  $id) : \Pop\Cache\Adapter\Apc

Delete a value in cache

Parameters

string $id

Returns

\Pop\Cache\Adapter\Apc

getInfo()

getInfo() : array

Method to get the current APC info.

Returns

array