定制 gemblue/tiny-cache 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

gemblue/tiny-cache

Composer 安装命令:

composer require gemblue/tiny-cache

包简介

Simple Cache Adapter for PHP Projects, PSR-16 Comply

README 文档

README

Modern cache adapter for PHP Projects.

  • PHP ^7.0 Syntax
  • PSR-4
  • PSR-16
  • Factory and Adapter Pattern
  • Exception

Supported Framework

This library is PSR-4 comply. You can use it on every framework that support composer.

  • CodeIgniter 3/4
  • Laravel
  • Yii
  • Your framework?
  • Native PHP

Supported Drivers

  • Redis
  • Memcached
  • File
  • MongoDB

Next plan : ApacheIgnite

Installation

composer require gemblue/tiny-cache

Usage

use Gemblue\TinyCache\CacheFactory;

$cacheFactory = new CacheFactory;
$cache = $cacheFactory->getInstance([
  'driver' => 'Memcached',
  'host' => 'localhost',
  'post' => 11211,
  'persistence' => true
]);

For full example, browse example folder.

API

Method Desc
set Set a key
get Get a key
delete Delete a key
clear Wipe all key
has Check key existance
setMultiple Set multiple key
getMultiple Get multiple key
deleteMultiple Delete multiple key

Delete by Prefix

To delete caches with any prefix, just call like this:

$cache->delete('prefix_*');

Developed By

  • @gemblue
  • @yllumi

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2020-04-21

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固