PHPackages                             chh/cache-service-provider - 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. chh/cache-service-provider

ActiveLibrary[Caching](/categories/caching)

chh/cache-service-provider
==========================

Provides easy to use caching for Silex applications, built on top of the doctrine/cache package

v2.0.2(9y ago)23163.0k↓31.3%3[3 issues](https://github.com/CHH/cache-service-provider/issues)1MITPHPPHP &gt;=5.5.0

Since Jan 15Pushed 9y ago2 watchersCompare

[ Source](https://github.com/CHH/cache-service-provider)[ Packagist](https://packagist.org/packages/chh/cache-service-provider)[ RSS](/packages/chh-cache-service-provider/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (3)Versions (7)Used By (1)

Silex Cache Service Provider
============================

[](#silex-cache-service-provider)

This service provider for Silex uses the Doctrine Cache library to provide a `cache` service to a Silex application as well as to other service providers.

Install
-------

[](#install)

Install with [composer](https://getcomposer.org):

```
% composer require chh/cache-service-provider

```

Usage
-----

[](#usage)

### Configuration

[](#configuration)

For an application wide cache use the default cache by setting the `default` key in `cache.options` with the cache definition.

The cache definition is an array of options, with `driver` being the only mandatory one. All other options in the array, are treated as constructor arguments to the driver class.

The cache named `default` is the cache available through the container's `cache` service.

```
