API > eden > apc.php
View Source

class Eden_Apc

This class objectifies APC and easily makes APC functionality available. APC does not offer having multiple instances so no model class was defined in Eve. Alternative PHP Cache (APC) Allows you to cache data in memory for the duration of the active server or an expire time has been reached. We cache when computing the same data is expensive on memory or time. Once the actual data is stored in memory, it can be used in the future by accessing the cached copy rather than recomputing the original data.

Public Methods

public function clear()

Flushes the cache

Returns this

public function get($key)

Gets a data cache


  1. string|array the key to the data
  2. int MemCache flag

Returns variable

public function remove($key)

deletes data of a cache


  1. string the key to the data

Returns this

public function set($key, $data, $expire = NULL)

Sets a data cache


  1. string the key to the data
  2. variable the data to be cached
  3. int expire

Returns bool

class Eden_Apc_Error

APC Errors


  • NOT_INSTALLED: APC is not installed.

© 2012 Openovate Labs. All rights reserved.