public function registerPlugin(SupervisorInterface $supervisor) { try { $this->register($supervisor); $this->registered = true; } catch (Error $ex) { $this->throwException($ex); } catch (Exception $ex) { $this->throwException($ex); } return $this; }