1 | <?php |
||
23 | class CacheService implements SingletonInterface |
||
24 | { |
||
25 | use ExtendedFacadeInstanceTrait; |
||
26 | |||
27 | const CACHE_IDENTIFIER = 'cache_formz'; |
||
28 | |||
29 | /** |
||
30 | * @var TypoScriptService |
||
31 | */ |
||
32 | protected $typoScriptService; |
||
33 | |||
34 | /** |
||
35 | * @var FrontendInterface |
||
36 | */ |
||
37 | protected $cacheInstance; |
||
38 | |||
39 | /** |
||
40 | * Returns the type of backend cache defined in TypoScript at the path: |
||
41 | * `settings.defaultBackendCache`. |
||
42 | * |
||
43 | * @return string |
||
44 | * @throws \Exception |
||
45 | */ |
||
46 | public function getBackendCache() |
||
61 | |||
62 | /** |
||
63 | * Returns the cache instance for this extension. |
||
64 | * |
||
65 | * @return FrontendInterface |
||
66 | */ |
||
67 | public function getCacheInstance() |
||
80 | |||
81 | /** |
||
82 | * @param FrontendInterface $cacheInstance |
||
83 | */ |
||
84 | public function setCacheInstance(FrontendInterface $cacheInstance) |
||
88 | |||
89 | /** |
||
90 | * Generic cache identifier creation for usages in the extension. |
||
91 | * |
||
92 | * @param string $string |
||
93 | * @param string $formClassName |
||
94 | * @param int $maxLength |
||
95 | * @return string |
||
96 | */ |
||
97 | public function getCacheIdentifier($string, $formClassName, $maxLength = 55) |
||
110 | |||
111 | /** |
||
112 | * @param TypoScriptService $typoScriptService |
||
113 | */ |
||
114 | public function injectTypoScriptService(TypoScriptService $typoScriptService) |
||
118 | } |
||
119 |