tdt/cache

A wrapper around caching systems.

Maintainers

Package info

github.com/tdt/cache

Homepage

pkg:composer/tdt/cache

Statistics

Installs: 850

Dependents: 0

Suggesters: 0

Stars: 0

Open Issues: 1

v1.0 2013-02-06 19:46 UTC

This package is not auto-updated.

Last update: 2026-03-14 20:56:51 UTC


README

Build Status

This repository holds a wrapper around a caching system. You can use NoCache if no caching system is installed, or MemCache. This allows the user to provide caching in his code, and switch to other caching systems later on if necessary.

Usage

$c = Cache::getInstance( array("system" => "Memcache", "host" => "localhost", "port" => 11211 ) );
$c->set("key", $objectToCache, $TTL); // TTL is optional

$cachedObject = $c->get("key");
// delete the cachedObject
$c->delete("key");