prowebcraft/yii2-lazy-cache 问题修复 & 功能扩展

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

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

prowebcraft/yii2-lazy-cache

Composer 安装命令:

composer require prowebcraft/yii2-lazy-cache

包简介

Lazy cache functions

README 文档

README

Lazy cache functions

Usage

Attach Lazy trait to your class

<?php

class HeavyJob {
    
    use \prowebcraft\yii2lazycache\Lazy;

}

Wrap heavy data in lazy function

$rocketToMarsTrajectory = $this->lazyWithCache('mars.trajectory', function() {
    // this function will be called once a day
    $trajectory = null;
    // heavy calculation here
    return $trajectory;
});

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: BSD-4-Clause
  • 更新时间: 2022-05-04