Yaffs site version 1.1
[yaffs-website] / web / modules / contrib / advagg / src / State / Aggregates.php
1 <?php
2
3 namespace Drupal\advagg\State;
4
5 use Drupal\Core\Cache\CacheBackendInterface;
6 use Drupal\Core\KeyValueStore\KeyValueFactoryInterface;
7 use Drupal\Core\Lock\LockBackendInterface;
8 use Drupal\Core\State\StateInterface;
9
10 /**
11  * Provides AdvAgg with saved aggregrate information using a key value store.
12  */
13 class Aggregates extends State implements StateInterface {
14
15   /**
16    * Constructs the State object.
17    *
18    * @param \Drupal\Core\KeyValueStore\KeyValueFactoryInterface $key_value_factory
19    *   The key value store to use.
20    * @param \Drupal\Core\Cache\CacheBackendInterface $cache
21    *   The cache object to use.
22    * @param \Drupal\Core\Lock\LockBackendInterface $lock
23    *   The lock object to use.
24    */
25   public function __construct(KeyValueFactoryInterface $key_value_factory, CacheBackendInterface $cache, LockBackendInterface $lock) {
26     parent::__construct($key_value_factory, $cache, $lock);
27     $this->keyValueStore = $key_value_factory->get('advagg_aggregates');
28     $this->pathColumn = 'uri';
29   }
30
31 }