PHPackages                             zebrains/file-cache - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Caching](/categories/caching)
4. /
5. zebrains/file-cache

ActiveLibrary[Caching](/categories/caching)

zebrains/file-cache
===================

0.0.2(5y ago)05MITPHPCI failing

Since Jun 30Pushed 5y ago1 watchersCompare

[ Source](https://github.com/zebrainsteam/filecache)[ Packagist](https://packagist.org/packages/zebrains/file-cache)[ RSS](/packages/zebrains-file-cache/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (3)Versions (3)Used By (0)

Filecache
=========

[](#filecache)

Библиотека для файлового кеша, поддерживающая работу с тегами и масками. Совместима с PSR-16.

Установка
---------

[](#установка)

`composer require zebrains/file-cache`

Пример
------

[](#пример)

Импортируем нужные классы и создаем экземпляр сервиса (менеджера)

```
use Zebrains\Filecache\Manager;
use Zebrains\Filecache\ImmediateInvalidator;
use Zebrains\Filecache\\Converter;
use Zebrains\Filecache\Formatters\RawFormatter;

$manager = new Manager($path, new Converter(), new RawFormatter(), new ImmediateInvalidator());

```

Менеджер реализует интерфейс `Psr\SimpleCache\CacheInterface`:

```
$key = '1:/catalog/product1';
$data = 'Hello worldHello world!';
$ttl = strtotime('now') + 60*60*24;

$manager->set($key, $data, $ttl);

var_dump($manager->get($key));

```

Есть поддержка тегов:

```
$tags = ['catalog', 'product1'];

$manager->setWithTags($key, $data, $tags, $ttl);

var_dump($manager->getByTag('catalog'));

```

Есть поддержка поиска по маске. В данный момент поддерживается только символ `*`.

Пример:

`$manager->getByMask('1:', '*'));` - будет произведен поиск на соответствие маске '1:\*'

`$manager->getByMask('1:', '*', '/product1'));` - будет произведен поиск на соответствие маске '1:\*/product1'

###  Health Score

21

—

LowBetter than 18% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity46

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

2

Last Release

2147d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/26834275?v=4)[Artem Prozorov](/maintainers/artem-prozorov)[@artem-prozorov](https://github.com/artem-prozorov)

---

Top Contributors

[![artprozorov](https://avatars.githubusercontent.com/u/188947463?v=4)](https://github.com/artprozorov "artprozorov (9 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/zebrains-file-cache/health.svg)

```
[![Health](https://phpackages.com/badges/zebrains-file-cache/health.svg)](https://phpackages.com/packages/zebrains-file-cache)
```

###  Alternatives

[laminas/laminas-cache

Caching implementation with a variety of storage options, as well as codified caching strategies for callbacks, classes, and output

1076.9M130](/packages/laminas-laminas-cache)[cache/adapter-common

Common classes for PSR-6 adapters

11124.4M38](/packages/cache-adapter-common)[cache/filesystem-adapter

A PSR-6 cache implementation using filesystem. This implementation supports tags

705.8M82](/packages/cache-filesystem-adapter)[cache/array-adapter

A PSR-6 cache implementation using a php array. This implementation supports tags

548.3M151](/packages/cache-array-adapter)[cache/redis-adapter

A PSR-6 cache implementation using Redis (PhpRedis). This implementation supports tags

523.9M27](/packages/cache-redis-adapter)[cache/simple-cache-bridge

A PSR-6 bridge to PSR-16. This will make any PSR-6 cache compatible with SimpleCache.

423.1M27](/packages/cache-simple-cache-bridge)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
