diff --git a/kiri-engine/Abstracts/Component.php b/kiri-engine/Abstracts/Component.php index 4d1699e4..b38f5a04 100644 --- a/kiri-engine/Abstracts/Component.php +++ b/kiri-engine/Abstracts/Component.php @@ -23,9 +23,6 @@ use Psr\Container\NotFoundExceptionInterface; /** * Class Component * @package Kiri\Base - * @property ContainerInterface|Container $container - * @property EventProvider $eventProvider - * @property EventDispatch $eventDispatch */ class Component implements Configure { @@ -67,6 +64,8 @@ class Component implements Configure /** * @return EventDispatch + * @throws ContainerExceptionInterface + * @throws NotFoundExceptionInterface */ protected function getEventDispatch(): EventDispatch { @@ -89,38 +88,6 @@ class Component implements Configure return static::class; } - /** - * @param $name - * @param $value - * - * @throws Exception - */ - public function __set($name, $value) - { - $method = 'set' . ucfirst($name); - if (method_exists($this, $method)) { - $this->{$method}($value); - } else { - throw new Exception('The set name ' . $name . ' not find in class ' . static::class); - } - } - - /** - * @param $name - * - * @return mixed - * @throws Exception - */ - public function __get($name): mixed - { - $method = 'get' . ucfirst($name); - if (method_exists($this, $method)) { - return $this->$method(); - } else { - throw new Exception('The get name ' . $name . ' not find in class ' . static::class); - } - } - /** * @param $message