2017 © Pedro PelĂĄez
 

library cache-interface

Generic cache interfaces

image

graphstory/cache-interface

Generic cache interfaces

  • Friday, November 20, 2015
  • by graphstory
  • Repository
  • 5 Watchers
  • 1 Stars
  • 9 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 5 Versions
  • 0 % Grown

The README.md

Graph Story Cache Interface

Simple cache adapters and interface based on Anthony Ferrara's blog post A Followup To An Open Letter To PHP-FIG., (*1)

Build Status, (*2)

Installation

Using Composer

Use Composer to install the cache-interface library:, (*3)

$ composer require graphstory/cache-interface, (*4)

Usage

``` php // Example using Daniel GonzĂĄlez's Cache library, (*5)

use Desarrolla2\Cache\Cache; use Desarrolla2\Cache\Adapter\File; use GraphStory\Console\Cache\DesarrollaAdapter;, (*6)

$cacheDir = '/tmp'; $adapter = new File($cacheDir); $adapter->setOption('ttl', 3600); $desarrolla2 = new Cache($adapter); $cache = DesarrollaAdapter($desarrolla2);, (*7)

$cache->set('key', 'myKeyValue', 3600);, (*8)

// later ..., (*9)

echo $cache->get('key'); ```, (*10)

(The above example was mostly cribbed from the desarrolla2/Cache documentation.), (*11)

BYOA (bring your own adapter)

You can write your own adapter by creating a class that implements the CacheAdapter interface. Use the other adapters as a reference and you should be good to go!, (*12)

The Versions

20/11 2015

dev-master

9999999-dev

Generic cache interfaces

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

by Graph Story

cache adapter interface

20/11 2015

0.0.3

0.0.3.0

Generic cache interfaces

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

by Graph Story

cache adapter interface

20/11 2015

dev-develop

dev-develop

Generic cache interfaces

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

by Graph Story

cache adapter interface

20/11 2015

0.0.2

0.0.2.0

Generic cache interfaces

  Sources   Download

MIT

The Requires

  • php >=5.4

 

The Development Requires

by Graph Story

26/08 2015

0.0.1

0.0.1.0

Generic cache interface

  Sources   Download

proprietary

by Graph Story