You are here

public function CacheItemBackend::set in Flysystem 3.x

Same name and namespace in other branches
  1. 8 src/Flysystem/Adapter/CacheItemBackend.php \Drupal\flysystem\Flysystem\Adapter\CacheItemBackend::set()
  2. 2.0.x src/Flysystem/Adapter/CacheItemBackend.php \Drupal\flysystem\Flysystem\Adapter\CacheItemBackend::set()
  3. 3.0.x src/Flysystem/Adapter/CacheItemBackend.php \Drupal\flysystem\Flysystem\Adapter\CacheItemBackend::set()

Sets a cache item in the backend.

Parameters

string $path: The file path.

\Drupal\flysystem\Flysystem\Adapter\CacheItem $item: The item to set.

File

src/Flysystem/Adapter/CacheItemBackend.php, line 86

Class

CacheItemBackend
Storage backend for cache items.

Namespace

Drupal\flysystem\Flysystem\Adapter

Code

public function set($path, CacheItem $item) {
  $this->cacheBackend
    ->set($this
    ->getCacheKey($path), $item);
}