ILIAS  release_9 Revision v9.13-25-g2c18ec4c24f
Config.php
Go to the documentation of this file.
1 <?php
2 
19 declare(strict_types=1);
20 
21 namespace ILIAS\Cache;
22 
26 
30 class Config
31 {
32  public const ALL = '*';
33  public const APCU = 'apc';
34  public const PHPSTATIC = 'static';
35  public const MEMCACHED = 'memcached';
36  protected int $default_ttl = 300;
37 
38  public function __construct(
39  protected string $adaptor_name,
40  protected bool $activated = false,
41  protected array $container_keys = [],
42  protected ?NodeRepository $nodes = null
43  ) {
44  if ($this->nodes === null) {
45  $this->nodes = new NullNodeRepository();
46  }
47  }
48 
49  public function getAdaptorName(): string
50  {
51  return $this->adaptor_name;
52  }
53 
54  public function getNodes(): array
55  {
56  return $this->nodes->getNodes();
57  }
58 
59  public function getActivatedContainerKeys(): array
60  {
61  return $this->container_keys;
62  }
63 
64  public function getDefaultTTL(): int
65  {
66  return $this->default_ttl;
67  }
68 
69  public function isActivated(): bool
70  {
71  return $this->activated;
72  }
73 }
__construct(protected string $adaptor_name, protected bool $activated=false, protected array $container_keys=[], protected ?NodeRepository $nodes=null)
Definition: Config.php:38
getActivatedContainerKeys()
Definition: Config.php:59
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...