承接 escapework/cache 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

escapework/cache

最新稳定版本:0.1.2

Composer 安装命令:

composer require escapework/cache

包简介

Library pra controle de cache

README 文档

README

Em construção.

Exemplos

use EscapeWork\Cache\Facade as Cache;

# setting 
Cache::set('key', 'value', 'namespace'); # namespace é opcional 

# getting
# if the value don't exists in cache, the closure is called
Cache::get('key', function() {
    return 'your function to get data';
}, 'namespace');

# deleting 
Cache::delete('key');

# flush namespace 
Cache::flushNamespace('namespace');

# flush all cache 
Cache::flush();

Tipos de cache disponíveis

  • Memcached
  • APC
  • File
  • Array (Para testes unitários)

Configuração

use EscapeWork\Cache\Facade as Cache;

Cache::driver(array(
    'driver' => 'memcached', 
    'memcached' => array(
        array('host' => 'your-host', 'port' => 11211) # server settings 
    ), 
));

Cache::driver(array(
    'driver' => 'file', 
    'path'   => '/path/to/your/cache/dir/', 
));

Instalação

A instalação está disponível via Composer. Autoload compátivel com a PSR-0.

{
    "require": {
        "escapework/cache": "0.1.*"
    }
}

统计信息

  • 总下载量: 68
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 2
  • Watchers: 7
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2013-02-21