summaryrefslogtreecommitdiff
path: root/vendor/doctrine/orm/src/Cache/RegionsConfiguration.php
diff options
context:
space:
mode:
authorpolo <ordipolo@gmx.fr>2026-10-18 00:08:23 +0200
committerpolo <ordipolo@gmx.fr>2026-10-18 00:10:03 +0200
commit05e38eadbeb3de19e5b26003c2b401e00bb71df4 (patch)
treecf48350b69cfce92de6f3a0e03eb0876931c7077 /vendor/doctrine/orm/src/Cache/RegionsConfiguration.php
parent32843e50aa981f190bdb4fbc9adbeacc06fdf775 (diff)
downloadAppliGestionPHP-05e38eadbeb3de19e5b26003c2b401e00bb71df4.tar.gz
AppliGestionPHP-05e38eadbeb3de19e5b26003c2b401e00bb71df4.tar.bz2
AppliGestionPHP-05e38eadbeb3de19e5b26003c2b401e00bb71df4.zip
sortie de vendor du dépôt, oubli dans config-template.ini
Diffstat (limited to 'vendor/doctrine/orm/src/Cache/RegionsConfiguration.php')
-rw-r--r--vendor/doctrine/orm/src/Cache/RegionsConfiguration.php63
1 files changed, 0 insertions, 63 deletions
diff --git a/vendor/doctrine/orm/src/Cache/RegionsConfiguration.php b/vendor/doctrine/orm/src/Cache/RegionsConfiguration.php
deleted file mode 100644
index a852831..0000000
--- a/vendor/doctrine/orm/src/Cache/RegionsConfiguration.php
+++ /dev/null
@@ -1,63 +0,0 @@
1<?php
2
3declare(strict_types=1);
4
5namespace Doctrine\ORM\Cache;
6
7/**
8 * Cache regions configuration
9 */
10class RegionsConfiguration
11{
12 /** @var array<string,int> */
13 private array $lifetimes = [];
14
15 /** @var array<string,int> */
16 private array $lockLifetimes = [];
17
18 public function __construct(
19 private int $defaultLifetime = 3600,
20 private int $defaultLockLifetime = 60,
21 ) {
22 }
23
24 public function getDefaultLifetime(): int
25 {
26 return $this->defaultLifetime;
27 }
28
29 public function setDefaultLifetime(int $defaultLifetime): void
30 {
31 $this->defaultLifetime = $defaultLifetime;
32 }
33
34 public function getDefaultLockLifetime(): int
35 {
36 return $this->defaultLockLifetime;
37 }
38
39 public function setDefaultLockLifetime(int $defaultLockLifetime): void
40 {
41 $this->defaultLockLifetime = $defaultLockLifetime;
42 }
43
44 public function getLifetime(string $regionName): int
45 {
46 return $this->lifetimes[$regionName] ?? $this->defaultLifetime;
47 }
48
49 public function setLifetime(string $name, int $lifetime): void
50 {
51 $this->lifetimes[$name] = $lifetime;
52 }
53
54 public function getLockLifetime(string $regionName): int
55 {
56 return $this->lockLifetimes[$regionName] ?? $this->defaultLockLifetime;
57 }
58
59 public function setLockLifetime(string $name, int $lifetime): void
60 {
61 $this->lockLifetimes[$name] = $lifetime;
62 }
63}