Method
LruCache::__construct
Creates an empty cache.
Description#
public LruCache::__construct(
int $maxEntries = PHP_INT_MAX,
int $maxBytes = PHP_INT_MAX
)Parameters#
- $maxEntries int = PHP_INT_MAX
- The most entries held; the least recently used go first
- $maxBytes int = PHP_INT_MAX
- The most bytes held, counting keys and string values
Errors / Exceptions#
| Exception | When |
|---|---|
InvalidArgumentException | When either is below 1 |