# Class Opencart\System\Library\Cache

Class Cache

Located at system\library\cache.php

Methods
`public` | `__construct(string $adaptor, int $expire = 3600)` Constructor Constructor #### Parameters
$adaptor | the type of storage for the cache
$expire | Optional parameters
| #
`public` | `get(string $key): mixed` Get Gets a cache by key name. Get Gets a cache by key name. #### Parameters
$key | The cache key name
| #
`public` | `set(string $key, mixed $value, int $expire = 0): void` Set Sets a cache by key value. Set Sets a cache by key value. #### Parameters
$key | The cache key
$value | The cache value
$expire | The cache expiry
| #
`public` | `delete(string $key): void` Delete Deletes a cache by key name. Delete Deletes a cache by key name. #### Parameters
$key | The cache key
| #

OpenCart API API documentation generated by ApiGen dev-master