getContainer(); /* @var IEventDispatcher $eventDispatcher */ $dispatcher = $container->query(IEventDispatcher::class); $dispatcher->addServiceListener(RoomCreatedEvent::class, RoomListener::class); $dispatcher->addServiceListener(RoomDeletedEvent::class, RoomListener::class); $container->registerMiddleWare(JoinMiddleware::class); $config = $container->query(IConfig::class); if ($config->getAppValue(self::ID, 'app.navigation') === 'true') { $this->registerAsNavigationEntry(); } else { $this->registerAsPersonalSetting(); } } private function registerAsPersonalSetting() { $settingsManager = $this->getContainer()->getServer()->getSettingsManager(); $settingsManager->registerSetting(ISettingsManager::KEY_PERSONAL_SETTINGS, \OCA\BigBlueButton\Settings\Personal::class); } private function registerAsNavigationEntry() { $server = $this->getContainer()->getServer(); $server->getNavigationManager()->add(function () use ($server) { return [ 'id' => self::ID, 'order' => 80, 'href' => $server->getURLGenerator()->linkToRoute('bbb.page.index'), 'icon' => $server->getURLGenerator()->imagePath('bbb', 'app.svg'), 'name' => 'BigBlueButton', ]; }); } }