package Default
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter

 Methods

Constructor

__construct(null|array|\Traversable|\Zend\Cache\Storage\Adapter\AdapterOptions $options = null
Inherited

Parameters

$options

nullarray\Traversable\Zend\Cache\Storage\Adapter\AdapterOptions

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Destructor

__destruct() : void
Inherited

detach all registered plugins to free event handles of event manager

Add an item.

addItem(string $key, mixed $value) : boolean
triggers addItem.pre(PreEvent)
triggers addItem.post(PostEvent)
triggers addItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::addItem()

Parameters

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Add an item.

addItem(string $key, mixed $value) : boolean
Inherited
triggers addItem.pre(PreEvent)
triggers addItem.post(PostEvent)
triggers addItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::addItem()

Parameters

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Add multiple items.

addItems(array $keyValuePairs) : boolean
triggers addItems.pre(PreEvent)
triggers addItems.post(PostEvent)
triggers addItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::addItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Add multiple items.

addItems(array $keyValuePairs) : array
Inherited
triggers addItems.pre(PreEvent)
triggers addItems.post(PostEvent)
triggers addItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::addItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Register a plugin

addPlugin(\Zend\Cache\Storage\Plugin\PluginInterface $plugin, integer $priority = 1) : \Zend\Cache\Storage\Adapter\AbstractAdapter
Inherited

Parameters

$plugin

\Zend\Cache\Storage\Plugin\PluginInterface

$priority

integer

Exceptions

\Zend\Cache\Exception\LogicException

Returns

\Zend\Cache\Storage\Adapter\AbstractAdapterFluent interface

Set an item only if token matches

checkAndSetItem(mixed $token, string $key, mixed $value) : boolean

It uses the token received from getItem() to check if the item has changed before overwriting it.

see
see
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::checkAndSetItem()

Parameters

$token

mixed

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Set an item only if token matches

checkAndSetItem(mixed $token, string $key, mixed $value) : boolean
Inherited

It uses the token received from getItem() to check if the item has changed before overwriting it.

see
see
inherited_from \Zend\Cache\Storage\StorageInterface::checkAndSetItem()

Parameters

$token

mixed

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Remove items by given namespace

clearByNamespace(string $namespace) : boolean
inherited_from \Zend\Cache\Storage\ClearByNamespaceInterface::clearByNamespace()

Parameters

$namespace

string

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

boolean

Remove items matching given prefix

clearByPrefix(string $prefix) : boolean
inherited_from \Zend\Cache\Storage\ClearByPrefixInterface::clearByPrefix()

Parameters

$prefix

string

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

boolean

Remove items matching given tags.

clearByTags(array<mixed,string> $tags, boolean $disjunction = false) : boolean

If $disjunction only one of the given tags must match else all given tags must match.

inherited_from \Zend\Cache\Storage\TaggableInterface::clearByTags()

Parameters

$tags

array<mixed,string>

$disjunction

boolean

Returns

boolean

Remove expired items

clearExpired() : boolean
triggers clearExpired.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\ClearExpiredInterface::clearExpired()

Returns

boolean

Decrement an item.

decrementItem(string $key, integer $value) : integer | boolean
Inherited
triggers decrementItem.pre(PreEvent)
triggers decrementItem.post(PostEvent)
triggers decrementItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::decrementItem()

Parameters

$key

string

$value

integer

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

integerbooleanThe new value on success, false on failure

Decrement multiple items.

decrementItems(array $keyValuePairs) : array
Inherited
triggers incrementItems.pre(PreEvent)
triggers incrementItems.post(PostEvent)
triggers incrementItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::decrementItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and new values

Flush the whole storage

flush() : boolean
inherited_from \Zend\Cache\Storage\FlushableInterface::flush()

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

boolean

Get available space in bytes

getAvailableSpace() : float
inherited_from \Zend\Cache\Storage\AvailableSpaceCapableInterface::getAvailableSpace()

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

float

Get caching enabled.

getCaching() : boolean
Inherited

Alias of getWritable and getReadable.

see
see

Returns

boolean

Get capabilities of this adapter

getCapabilities() : \Zend\Cache\Storage\Capabilities
Inherited
triggers getCapabilities.pre(PreEvent)
triggers getCapabilities.post(PostEvent)
triggers getCapabilities.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::getCapabilities()

Returns

\Zend\Cache\Storage\Capabilities

Get the event manager

getEventManager() : \Zend\EventManager\EventManagerInterface
Inherited

Lazy-loads an EventManager instance if none registered.

inherited_from \Zend\EventManager\EventsCapableInterface::getEventManager()

Returns

\Zend\EventManager\EventManagerInterface

Get an item.

getItem(string $key, boolean $success = null, mixed $casToken = null) : mixed
triggers getItem.pre(PreEvent)
triggers getItem.post(PostEvent)
triggers getItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::getItem()

Parameters

$key

string

$success

boolean

$casToken

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

mixedData on success, null on failure

Get an item.

getItem(string $key, boolean $success = null, mixed $casToken = null) : mixed
Inherited
triggers getItem.pre(PreEvent)
triggers getItem.post(PostEvent)
triggers getItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::getItem()

Parameters

$key

string

$success

boolean

$casToken

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

mixedData on success, null on failure

Get multiple items.

getItems(array $keys) : array
triggers getItems.pre(PreEvent)
triggers getItems.post(PostEvent)
triggers getItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::getItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and values

Get multiple items.

getItems(array $keys) : array
Inherited
triggers getItems.pre(PreEvent)
triggers getItems.post(PostEvent)
triggers getItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::getItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and values

Get the storage iterator

getIterator() : \Zend\Cache\Storage\Adapter\FilesystemIterator

Returns

\Zend\Cache\Storage\Adapter\FilesystemIterator

Get metadatas

getMetadatas(array $keys, array $options = array()) : array
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::getMetadatas()

Parameters

$keys

array

$options

array

Returns

arrayAssociative array of keys and metadata

Get multiple metadata

getMetadatas(array $keys) : array
Inherited
triggers getMetadatas.pre(PreEvent)
triggers getMetadatas.post(PostEvent)
triggers getMetadatas.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::getMetadatas()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and metadata

Get options.

getOptions() : \Zend\Cache\Storage\Adapter\FilesystemOptions
see
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::getOptions()

Returns

\Zend\Cache\Storage\Adapter\FilesystemOptions

Get options.

getOptions() : \Zend\Cache\Storage\Adapter\AdapterOptions
Inherited
see
inherited_from \Zend\Cache\Storage\StorageInterface::getOptions()

Returns

\Zend\Cache\Storage\Adapter\AdapterOptions

Return registry of plugins

getPluginRegistry() : \SplObjectStorage
Inherited

Returns

\SplObjectStorage

Get tags of an item by given key

getTags(string $key) : array<mixed,string> | FALSE
inherited_from \Zend\Cache\Storage\TaggableInterface::getTags()

Parameters

$key

string

Returns

array<mixed,string>FALSE

Get total space in bytes

getTotalSpace() : integer | float
inherited_from \Zend\Cache\Storage\TotalSpaceCapableInterface::getTotalSpace()

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

integerfloat

Test if an item exists.

hasItem(string $key) : boolean
triggers hasItem.pre(PreEvent)
triggers hasItem.post(PostEvent)
triggers hasItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::hasItem()

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Test if an item exists.

hasItem(string $key) : boolean
Inherited
triggers hasItem.pre(PreEvent)
triggers hasItem.post(PostEvent)
triggers hasItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::hasItem()

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Test multiple items.

hasItems(array $keys) : array
triggers hasItems.pre(PreEvent)
triggers hasItems.post(PostEvent)
triggers hasItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::hasItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of found keys

Test multiple items.

hasItems(array $keys) : array
Inherited
triggers hasItems.pre(PreEvent)
triggers hasItems.post(PostEvent)
triggers hasItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::hasItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of found keys

Check if a plugin is registered

hasPlugin(\Zend\Cache\Storage\Plugin\PluginInterface $plugin) : boolean
Inherited

Parameters

$plugin

\Zend\Cache\Storage\Plugin\PluginInterface

Returns

boolean

Increment an item.

incrementItem(string $key, integer $value) : integer | boolean
Inherited
triggers incrementItem.pre(PreEvent)
triggers incrementItem.post(PostEvent)
triggers incrementItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::incrementItem()

Parameters

$key

string

$value

integer

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

integerbooleanThe new value on success, false on failure

Increment multiple items.

incrementItems(array $keyValuePairs) : array
Inherited
triggers incrementItems.pre(PreEvent)
triggers incrementItems.post(PostEvent)
triggers incrementItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::incrementItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and new values

Optimize the storage

optimize() : boolean: \Zend\Cache\Exception\RuntimeException
inherited_from \Zend\Cache\Storage\OptimizableInterface::optimize()

Returns

boolean
\Zend\Cache\Exception\RuntimeException

Remove an item.

removeItem(string $key) : boolean
triggers removeItem.pre(PreEvent)
triggers removeItem.post(PostEvent)
triggers removeItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::removeItem()

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Remove an item.

removeItem(string $key) : boolean
Inherited
triggers removeItem.pre(PreEvent)
triggers removeItem.post(PostEvent)
triggers removeItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::removeItem()

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Remove multiple items.

removeItems(array $keys) : array
triggers removeItems.pre(PreEvent)
triggers removeItems.post(PostEvent)
triggers removeItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::removeItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not removed keys

Remove multiple items.

removeItems(array $keys) : array
Inherited
triggers removeItems.pre(PreEvent)
triggers removeItems.post(PostEvent)
triggers removeItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::removeItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not removed keys

Unregister an already registered plugin

removePlugin(\Zend\Cache\Storage\Plugin\PluginInterface $plugin) : \Zend\Cache\Storage\Adapter\AbstractAdapter
Inherited

Parameters

$plugin

\Zend\Cache\Storage\Plugin\PluginInterface

Exceptions

\Zend\Cache\Exception\LogicException

Returns

\Zend\Cache\Storage\Adapter\AbstractAdapterFluent interface

Replace an existing item.

replaceItem(string $key, mixed $value) : boolean
triggers replaceItem.pre(PreEvent)
triggers replaceItem.post(PostEvent)
triggers replaceItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::replaceItem()

Parameters

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Replace an existing item.

replaceItem(string $key, mixed $value) : boolean
Inherited
triggers replaceItem.pre(PreEvent)
triggers replaceItem.post(PostEvent)
triggers replaceItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::replaceItem()

Parameters

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Replace multiple existing items.

replaceItems(array $keyValuePairs) : boolean
triggers replaceItems.pre(PreEvent)
triggers replaceItems.post(PostEvent)
triggers replaceItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::replaceItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Replace multiple existing items.

replaceItems(array $keyValuePairs) : array
Inherited
triggers replaceItems.pre(PreEvent)
triggers replaceItems.post(PostEvent)
triggers replaceItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::replaceItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Enable/Disable caching.

setCaching(boolean $flag) : \Zend\Cache\Storage\Adapter\AbstractAdapter
Inherited

Alias of setWritable and setReadable.

see
see

Parameters

$flag

boolean

Returns

\Zend\Cache\Storage\Adapter\AbstractAdapter

Store an item.

setItem(string $key, mixed $value) : boolean
triggers setItem.pre(PreEvent)
triggers setItem.post(PostEvent)
triggers setItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::setItem()

Parameters

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Store an item.

setItem(string $key, mixed $value) : boolean
Inherited
triggers setItem.pre(PreEvent)
triggers setItem.post(PostEvent)
triggers setItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::setItem()

Parameters

$key

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Store multiple items.

setItems(array $keyValuePairs) : array
triggers setItems.pre(PreEvent)
triggers setItems.post(PostEvent)
triggers setItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::setItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Store multiple items.

setItems(array $keyValuePairs) : array
Inherited
triggers setItems.pre(PreEvent)
triggers setItems.post(PostEvent)
triggers setItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::setItems()

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Set options.

setOptions(array|\Traversable|\Zend\Cache\Storage\Adapter\FilesystemOptions $options) : \Zend\Cache\Storage\Adapter\Filesystem
see
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::setOptions()

Parameters

$options

array\Traversable\Zend\Cache\Storage\Adapter\FilesystemOptions

Returns

\Zend\Cache\Storage\Adapter\Filesystem

Set options.

setOptions(array|\Traversable|\Zend\Cache\Storage\Adapter\AdapterOptions $options) : \Zend\Cache\Storage\Adapter\AbstractAdapter
Inherited
see
inherited_from \Zend\Cache\Storage\StorageInterface::setOptions()

Parameters

$options

array\Traversable\Zend\Cache\Storage\Adapter\AdapterOptions

Returns

\Zend\Cache\Storage\Adapter\AbstractAdapter

Set tags to an item by given key.

setTags(string $key, array<mixed,string> $tags) : boolean

An empty array will remove all tags.

inherited_from \Zend\Cache\Storage\TaggableInterface::setTags()

Parameters

$key

string

$tags

array<mixed,string>

Returns

boolean

Reset lifetime of an item

touchItem(string $key) : boolean
triggers touchItem.pre(PreEvent)
triggers touchItem.post(PostEvent)
triggers touchItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::touchItem()

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Reset lifetime of an item

touchItem(string $key) : boolean
Inherited
triggers touchItem.pre(PreEvent)
triggers touchItem.post(PostEvent)
triggers touchItem.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::touchItem()

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Reset lifetime of multiple items.

touchItems(array $keys) : array
triggers touchItems.pre(PreEvent)
triggers touchItems.post(PostEvent)
triggers touchItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::touchItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not updated keys

Reset lifetime of multiple items.

touchItems(array $keys) : array
Inherited
triggers touchItems.pre(PreEvent)
triggers touchItems.post(PostEvent)
triggers touchItems.exception(ExceptionEvent)
inherited_from \Zend\Cache\Storage\StorageInterface::touchItems()

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not updated keys

Read a complete file

getFileContent(string $file, boolean $nonBlocking = false, boolean $wouldblock = null) : string

Parameters

$file

string

File complete path

$nonBlocking

boolean

Don't block script if file is locked

$wouldblock

boolean

The optional argument is set to TRUE if the lock would block

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

string

Get file spec of the given key and namespace

getFileSpec(string $normalizedKey) : string

Parameters

$normalizedKey

string

Returns

string

Internal method to add an item.

internalAddItem(string $normalizedKey, mixed $value) : boolean
Inherited

Parameters

$normalizedKey

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to add multiple items.

internalAddItems(array $normalizedKeyValuePairs) : array
Inherited

Parameters

$normalizedKeyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Internal method to set an item only if token matches

internalCheckAndSetItem(mixed $token, string $normalizedKey, mixed $value) : boolean
see
see
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalCheckAndSetItem()

Parameters

$token

mixed

$normalizedKey

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to set an item only if token matches

internalCheckAndSetItem(mixed $token, string $normalizedKey, mixed $value) : boolean
Inherited
see
see

Parameters

$token

mixed

$normalizedKey

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to decrement an item.

internalDecrementItem(string $normalizedKey, integer $value) : integer | boolean
Inherited

Parameters

$normalizedKey

string

$value

integer

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

integerbooleanThe new value on success, false on failure

Internal method to decrement multiple items.

internalDecrementItems(array $normalizedKeyValuePairs) : array
Inherited

Parameters

$normalizedKeyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and new values

Internal method to get capabilities of this adapter

internalGetCapabilities() : \Zend\Cache\Storage\Capabilities
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalGetCapabilities()

Returns

\Zend\Cache\Storage\Capabilities

Internal method to get capabilities of this adapter

internalGetCapabilities() : \Zend\Cache\Storage\Capabilities
Inherited

Returns

\Zend\Cache\Storage\Capabilities

Internal method to get an item.

internalGetItem(string $normalizedKey, boolean $success = null, mixed $casToken = null) : null | mixed
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalGetItem()

Parameters

$normalizedKey

string

$success

boolean

$casToken

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface
\Exception

Returns

nullmixedData on success, null on failure

Internal method to get an item.

internalGetItem(string $normalizedKey, boolean $success = null, mixed $casToken = null) : mixed
Inherited

Parameters

$normalizedKey

string

$success

boolean

$casToken

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

mixedData on success, null on failure

Internal method to get multiple items.

internalGetItems(array $normalizedKeys) : array
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalGetItems()

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and values

Internal method to get multiple items.

internalGetItems(array $normalizedKeys) : array
Inherited

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and values

Internal method to get multiple metadata

internalGetMetadatas(array $normalizedKeys) : array
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalGetMetadatas()

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and metadata

Internal method to get multiple metadata

internalGetMetadatas(array $normalizedKeys) : array
Inherited

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and metadata

Internal method to test if an item exists.

internalHasItem(string $normalizedKey) : boolean
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalHasItem()

Parameters

$normalizedKey

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to test if an item exists.

internalHasItem(string $normalizedKey) : boolean
Inherited

Parameters

$normalizedKey

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to test multiple items.

internalHasItems(array $normalizedKeys) : array
Inherited

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of found keys

Internal method to increment an item.

internalIncrementItem(string $normalizedKey, integer $value) : integer | boolean
Inherited

Parameters

$normalizedKey

string

$value

integer

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

integerbooleanThe new value on success, false on failure

Internal method to increment multiple items.

internalIncrementItems(array $normalizedKeyValuePairs) : array
Inherited

Parameters

$normalizedKeyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayAssociative array of keys and new values

Internal method to remove an item.

internalRemoveItem(string $normalizedKey) : boolean
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalRemoveItem()

Parameters

$normalizedKey

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to remove an item.

internalRemoveItem(string $normalizedKey) : boolean
Inherited

Parameters

$normalizedKey

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to remove multiple items.

internalRemoveItems(array $normalizedKeys) : array
Inherited

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not removed keys

Internal method to replace an existing item.

internalReplaceItem(string $normalizedKey, mixed $value) : boolean
Inherited

Parameters

$normalizedKey

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to replace multiple existing items.

internalReplaceItems(array $normalizedKeyValuePairs) : array
Inherited

Parameters

$normalizedKeyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Internal method to store an item.

internalSetItem(string $normalizedKey, mixed $value) : boolean
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalSetItem()

Parameters

$normalizedKey

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to store an item.

internalSetItem(string $normalizedKey, mixed $value) : boolean
Inherited

Parameters

$normalizedKey

string

$value

mixed

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to store multiple items.

internalSetItems(array $normalizedKeyValuePairs) : array
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalSetItems()

Parameters

$normalizedKeyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Internal method to store multiple items.

internalSetItems(array $normalizedKeyValuePairs) : array
Inherited

Parameters

$normalizedKeyValuePairs

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not stored keys

Internal method to reset lifetime of an item

internalTouchItem(string $normalizedKey) : boolean
inherited_from \Zend\Cache\Storage\Adapter\AbstractAdapter::internalTouchItem()

Parameters

$normalizedKey

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to reset lifetime of an item

internalTouchItem(string $normalizedKey) : boolean
Inherited

Parameters

$normalizedKey

string

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

boolean

Internal method to reset lifetime of multiple items.

internalTouchItems(array $normalizedKeys) : array
Inherited

Parameters

$normalizedKeys

array

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

arrayArray of not updated keys

Validates and normalizes a key

normalizeKey(string $key) : void
Inherited

Parameters

$key

string

Exceptions

\Zend\Cache\Exception\InvalidArgumentException On an invalid key

Validates and normalizes an array of key-value pairs

normalizeKeyValuePairs(array $keyValuePairs) : void
Inherited

Parameters

$keyValuePairs

array

Exceptions

\Zend\Cache\Exception\InvalidArgumentException On an invalid key

Validates and normalizes multiple keys

normalizeKeys(array $keys) : void
Inherited

Parameters

$keys

array

Exceptions

\Zend\Cache\Exception\InvalidArgumentException On an invalid key

Prepares a directory structure for the given file(spec) using the configured directory level.

prepareDirectoryStructure(string $file) : void

Parameters

$file

string

Exceptions

\Zend\Cache\Exception\RuntimeException

Write content to a file

putFileContent(string $file, string $data, boolean $nonBlocking = false, boolean $wouldblock = null) : void

Parameters

$file

string

File complete path

$data

string

Data to write

$nonBlocking

boolean

Don't block script if file is locked

$wouldblock

boolean

The optional argument is set to TRUE if the lock would block

Exceptions

\Zend\Cache\Exception\RuntimeException

Read info file

readInfoFile(string $file, boolean $nonBlocking = false, boolean $wouldblock = null) : array | boolean

Parameters

$file

string

$nonBlocking

boolean

Don't block script if file is locked

$wouldblock

boolean

The optional argument is set to TRUE if the lock would block

Exceptions

\Zend\Cache\Exception\RuntimeException

Returns

arraybooleanThe info array or false if file wasn't found

Removes directories recursive by namespace

rmDir(string $dir, string $prefix) : boolean

Parameters

$dir

string

Directory to delete

$prefix

string

Namespace + Separator

Returns

boolean

Trigger an exception event

triggerException(string $eventName, \ArrayObject $args, mixed $result, \Exception $exception) : mixed
Inherited

If the ExceptionEvent has the flag "throwException" enabled throw the exception after trigger else return the result.

Parameters

$eventName

string

$args

\ArrayObject

$result

mixed

$exception

\Exception

Exceptions

\Zend\Cache\Exception\ExceptionInterface

Returns

mixed

Triggers the PostEvent and return the result value.

triggerPost(string $eventName, \ArrayObject $args, mixed $result) : mixed
Inherited

Parameters

$eventName

string

$args

\ArrayObject

$result

mixed

Returns

mixed

Trigger a pre event and return the event response collection

triggerPre(string $eventName, \ArrayObject $args) : \Zend\EventManager\ResponseCollection
Inherited

Parameters

$eventName

string

$args

\ArrayObject

Returns

\Zend\EventManager\ResponseCollectionAll handler return values

 Properties

 

Capabilities of this adapter

$capabilities : null | \Zend\Cache\Storage\Capabilities

Default

null
 

Marker to change capabilities

$capabilityMarker : null | object

Default

 

Event handles of this adapter

$eventHandles : array

Default

array()
 

The used EventManager if any

$events : null | \Zend\EventManager\EventManagerInterface

Default

null
 

The last used filespec

$lastFileSpec : string

Default

''
 

An identity for the last filespec (cache directory + namespace prefix + key + directory level)

$lastFileSpecId : string

Default

''
 

options

$options : mixed

Default

 

The plugin registry

$pluginRegistry : \SplObjectStorage

Default

 

Buffered total space in bytes

$totalSpace : null | integer | float

Default