mtoolkit / mtoolkit-cache
The cache module of MToolkit framework
Installs: 13
Dependents: 1
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
pkg:composer/mtoolkit/mtoolkit-cache
Requires
- php: >=5.3.0
- mtoolkit/mtoolkit-core: dev-master
Requires (Dev)
- phpunit/phpunit: 5.1.*
This package is not auto-updated.
Last update: 2025-09-28 00:29:15 UTC
README
The cache module of MToolkit framework.
Cache types
- MySQL
- File
- APC
Usages
Following, the examples of each type of supported cache.
MySQL
$cacheManager = MCacheFactoryImpl::getManager(new MCacheConfiguration( MCacheType::MYSQL, array( 'db' => new PDO(...), 'table' => 'mcache' ) ));
File
$cacheManager = MCacheFactoryImpl::getManager(new MCacheConfiguration( MCacheType::FILE, array( 'path' => '/temp/cache' ) ));
APC
$cacheManager = MCacheFactoryImpl::getManager(new MCacheConfiguration( MCacheType::APC, array() ));