1 | <?php |
||
20 | class ConfigCache extends BaseConfigCache implements ConfigCacheInterface |
||
21 | { |
||
22 | const TAG_LOCALE = 'config_cache.locale'; |
||
23 | |||
24 | // for createing cache |
||
25 | protected $referableLocales = array(); |
||
26 | // for getting cache |
||
27 | protected $defaultLocale; |
||
28 | protected $currentLocale; |
||
29 | |||
30 | /** |
||
31 | * {@inheritdoc} |
||
32 | */ |
||
33 | 14 | public function setReferableLocales(array $locales) |
|
39 | |||
40 | /** |
||
41 | * {@inheritdoc} |
||
42 | */ |
||
43 | 14 | public function setDefaultLocale($locale) |
|
49 | |||
50 | /** |
||
51 | * {@inheritdoc} |
||
52 | */ |
||
53 | 4 | public function setCurrentLocale($currentLocale) |
|
59 | |||
60 | /** |
||
61 | * {@inheritdoc} |
||
62 | */ |
||
63 | 6 | public function create() |
|
80 | |||
81 | /** |
||
82 | * {@inheritdoc} |
||
83 | */ |
||
84 | 2 | public function save() |
|
90 | |||
91 | /** |
||
92 | * {@inheritdoc} |
||
93 | */ |
||
94 | 1 | public function restore() |
|
100 | |||
101 | /** |
||
102 | * Creates PHP cache file internal processing. |
||
103 | * |
||
104 | * this method has a $locale argument for executing findAll() but no cache. |
||
105 | * |
||
106 | * @param string $locale |
||
107 | * |
||
108 | * @return array |
||
109 | */ |
||
110 | 7 | protected function createInternal($locale = null) |
|
117 | |||
118 | /** |
||
119 | * Finds a doctrine cache ID with locale. |
||
120 | * |
||
121 | * $locale argument has the potential to become null when findAll(). |
||
122 | * |
||
123 | * @param string $locale |
||
124 | * |
||
125 | * @return string |
||
126 | */ |
||
127 | 10 | protected function findId($locale = null) |
|
141 | |||
142 | /** |
||
143 | * Gets a locale. |
||
144 | * |
||
145 | * @return string |
||
146 | */ |
||
147 | 5 | protected function getLocale() |
|
151 | } |
||
152 |