battis/simplecache 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

battis/simplecache

最新稳定版本:v1.2.2

Composer 安装命令:

composer require battis/simplecache

包简介

Manage a simple cache backed by a MySQL database

README 文档

README

Latest Version Scrutinizer Code Quality Code Coverage Build Status

Manage a simple cache backed by a MySQL database

Install

In your composer.json add:

"require": {
  "battis/simplecache": "1.*"
}

Use

Create a cache:

$mysqli = new mysqli('localhost', 'bob', 's00pers3kr3t', 'app-db'); // or whatever your credentials are
$cache = new \Battis\SimpleCache($mysqli);

Basic workflow using cached data (check the cache and used cached data if there, otherwise build data and cache it for next time):

$data = $cache->getCache('foo');
if ($data === false) {

  // ... lots and lots of work to create $data from scratch

  $cache->setCache('foo', $data); // cache for next use
}

Full API documentation is available in /docs.

统计信息

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

GitHub 信息

  • Stars: 0
  • Watchers: 3
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: LGPL-3.0
  • 更新时间: 2015-06-22