1 | <?php |
||
16 | class FlySystemManager implements ContainerInterface |
||
17 | { |
||
18 | /** @var MainConfig */ |
||
19 | protected $config; |
||
20 | |||
21 | /** @var ContainerInterface */ |
||
22 | protected $adaptorManager; |
||
23 | |||
24 | /** @var ContainerInterface */ |
||
25 | protected $cacheManager; |
||
26 | |||
27 | /** @var Filesystem[]|MountManager[] */ |
||
28 | protected $systems = []; |
||
29 | |||
30 | /** @var ContainerInterface */ |
||
31 | protected $container; |
||
32 | |||
33 | /** |
||
34 | * Manager constructor. |
||
35 | * @param MainConfig $config |
||
36 | * @param ContainerInterface $adaptorManager |
||
37 | * @param ContainerInterface $cacheManager |
||
38 | * @param ContainerInterface $container |
||
39 | */ |
||
40 | 12 | public function __construct( |
|
51 | |||
52 | /** |
||
53 | * @param string $id |
||
54 | * |
||
55 | * @return Filesystem|MountManager |
||
56 | */ |
||
57 | 6 | public function get($id) |
|
90 | |||
91 | /** |
||
92 | * @param $id |
||
93 | * @param FileSystemConfig $fileSystemConfig |
||
94 | * @return Filesystem |
||
95 | */ |
||
96 | 5 | protected function getFileSystem($id, FileSystemConfig $fileSystemConfig) |
|
110 | |||
111 | /** |
||
112 | * @param FilesystemInterface|MountManager $filesystem |
||
113 | * @param array $plugins |
||
114 | */ |
||
115 | 4 | protected function setPlugins($filesystem, array $plugins = []) |
|
121 | |||
122 | /** |
||
123 | * @param FilesystemInterface|MountManager $filesystem |
||
124 | * @param string $pluginName |
||
125 | */ |
||
126 | 4 | protected function addPlugin($filesystem, string $pluginName) |
|
136 | |||
137 | 2 | public function has($id) |
|
141 | |||
142 | /** |
||
143 | * Get the Adaptor manager |
||
144 | * |
||
145 | * @return ContainerInterface |
||
146 | */ |
||
147 | 1 | public function getAdaptorManager() |
|
151 | |||
152 | /** |
||
153 | * Get the Cache Manager |
||
154 | * |
||
155 | * @return mixed |
||
156 | */ |
||
157 | 1 | public function getCacheManager() |
|
161 | } |
||
162 |