doctrine/cache's direct dependencies. Data on all dependencies, including transitive ones, is available via CSV download.
Doctrine/Cache is a component extracted from the Doctrine Common project. It is designed to offer a cache implementation layer for PHP projects. While it supports a multitude of different drivers such as Redis, Memcache, APC, MongoDB, and others, it's important to note that the library is deprecated and the Doctrine Project no longer provides bug fixes for it. It is recommended by the Doctrine Project to use a different cache library, preferably PSR-6 or PSR-16.
The Doctrine/Cache library is used within your PHP projects to handle caching data. Though deprecated, you can still use it by adding it to your composer.json file and running composer update. Here's a typical code usage in PHP:
use Doctrine\Common\Cache\FilesystemCache; $cache = new FilesystemCache('/path/to/dir'); $cache->save('my_data', 'Hello World!'); echo $cache->fetch('my_data'); // outputs: Hello World!
In this example, we initialize a Filesystem Cache and store some data (‘Hello World!’) identified by 'my_data'. We then fetch and output the data using the same identifier.
Again, with the library deprecated, you are strongly advised to use a PSR-6 or PSR-16 compliant library for new projects.
For the Doctrine/Cache library, the documentation can be found on the Doctrine Project's website via the following URL: https://www.doctrine-project.org/projects/doctrine-cache/en/current/index.html. Despite this, bear in mind that this library is deprecated and the Doctrine project encourages the use of a different caching library, with PSR-6 or PSR-16 being the preferred options.