On this page
public function DrupalCacheArray::__construct
public DrupalCacheArray::__construct($cid, $bin)
Constructs a DrupalCacheArray object.
Parameters
$cid: The cid for the array being cached.
$bin: The bin to cache the array.
File
- includes/bootstrap.inc, line 345
- Functions that need to be loaded on every Drupal request.
Class
- DrupalCacheArray
- Provides a caching wrapper to be used in place of large array structures.
Code
public function __construct($cid, $bin) {
$this->cid = $cid;
$this->bin = $bin;
if ($cached = cache_get($this->cid, $this->bin)) {
$this->storage = $cached->data;
}
}
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/includes!bootstrap.inc/function/DrupalCacheArray::__construct/7.x