*/ private array $folders = []; public function __construct(IRootFolder $rootFolder, SystemConfig $systemConfig) { $this->rootFolder = $rootFolder; $this->config = $systemConfig; } public function get(string $appId): IAppData { if (!isset($this->folders[$appId])) { $this->folders[$appId] = new AppData($this->rootFolder, $this->config, $appId); } return $this->folders[$appId]; } }