DatabaseBackend

Defines a default cache implementation.

This is Drupal's default cache implementation. It uses the database to store cached data. Each cache bin corresponds to a database table by the same name.

Hierarchy

Related topics

Cache API
Information about the Drupal Cache API

File

core/lib/Drupal/Core/Cache/DatabaseBackend.php, line 17

Namespace

Drupal\Core\Cache

Members

Name Modifiers Type Description
CacheBackendInterface::CACHE_PERMANENT constant Indicates that the item should never be removed unless explicitly deleted.
DatabaseBackend::$bin protected property
DatabaseBackend::$checksumProvider protected property The cache tags checksum provider.
DatabaseBackend::$connection protected property The database connection.
DatabaseBackend::catchException protected function Act on an exception when cache might be stale.
DatabaseBackend::delete public function Deletes an item from the cache. Overrides CacheBackendInterface::delete
DatabaseBackend::deleteAll public function Deletes all cache items in a bin. Overrides CacheBackendInterface::deleteAll
DatabaseBackend::deleteMultiple public function Deletes multiple items from the cache. Overrides CacheBackendInterface::deleteMultiple
DatabaseBackend::doSetMultiple protected function Stores multiple items in the persistent cache.
DatabaseBackend::ensureBinExists protected function Check if the cache bin exists and create it if not.
DatabaseBackend::garbageCollection public function Performs garbage collection on a cache bin. Overrides CacheBackendInterface::garbageCollection
DatabaseBackend::get public function Returns data from the persistent cache. Overrides CacheBackendInterface::get
DatabaseBackend::getMultiple public function Returns data from the persistent cache when given an array of cache IDs. Overrides CacheBackendInterface::getMultiple
DatabaseBackend::invalidate public function Marks a cache item as invalid. Overrides CacheBackendInterface::invalidate
DatabaseBackend::invalidateAll public function Marks all cache items as invalid. Overrides CacheBackendInterface::invalidateAll
DatabaseBackend::invalidateMultiple public function Marks cache items as invalid. Overrides CacheBackendInterface::invalidateMultiple
DatabaseBackend::normalizeCid protected function Normalizes a cache ID in order to comply with database limitations.
DatabaseBackend::prepareItem protected function Prepares a cached item.
DatabaseBackend::removeBin public function Remove a cache bin. Overrides CacheBackendInterface::removeBin
DatabaseBackend::schemaDefinition public function Defines the schema for the {cache_*} bin tables.
DatabaseBackend::set public function Stores data in the persistent cache. Overrides CacheBackendInterface::set
DatabaseBackend::setMultiple public function Store multiple items in the persistent cache. Overrides CacheBackendInterface::setMultiple
DatabaseBackend::__construct public function Constructs a DatabaseBackend object.
doc_Drupal
2016-10-29 08:59:34
Comments
Leave a Comment

Please login to continue.