123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103 |
- <?php
- namespace OCP\App;
- use OCP\EventDispatcher\Event;
- class ManagerEvent extends Event {
-
- public const EVENT_APP_ENABLE = 'OCP\App\IAppManager::enableApp';
-
- public const EVENT_APP_ENABLE_FOR_GROUPS = 'OCP\App\IAppManager::enableAppForGroups';
-
- public const EVENT_APP_DISABLE = 'OCP\App\IAppManager::disableApp';
-
- public const EVENT_APP_UPDATE = 'OCP\App\IAppManager::updateApp';
-
- protected $event;
-
- protected $appID;
-
- protected $groups;
-
- public function __construct($event, $appID, array $groups = null) {
- $this->event = $event;
- $this->appID = $appID;
- $this->groups = $groups;
- }
-
- public function getEvent() {
- return $this->event;
- }
-
- public function getAppID() {
- return $this->appID;
- }
-
- public function getGroups() {
- return array_map(function ($group) {
-
- return $group->getGID();
- }, $this->groups);
- }
- }
|