| 1 | <?php |
||
| 10 | class GenericEvent implements EventInterface |
||
| 11 | { |
||
| 12 | /** @var DateTime */ |
||
| 13 | private $emittedAt; |
||
| 14 | |||
| 15 | /** @var string */ |
||
| 16 | private $name; |
||
| 17 | |||
| 18 | /** @var string */ |
||
| 19 | private $source; |
||
| 20 | |||
| 21 | /** @var array|object */ |
||
| 22 | private $subject; |
||
| 23 | |||
| 24 | /** |
||
| 25 | * Event constructor. |
||
| 26 | * |
||
| 27 | * @param DateTime $emittedAt |
||
| 28 | * @param string $name |
||
| 29 | * @param string $source |
||
| 30 | * @param array|object $subject |
||
| 31 | */ |
||
| 32 | public function __construct(DateTime $emittedAt, $name, $source, $subject) |
||
| 39 | |||
| 40 | /** @return DateTime */ |
||
| 41 | public function emittedAt() |
||
| 45 | |||
| 46 | /** @return string */ |
||
| 47 | public function name() |
||
| 51 | |||
| 52 | /** @return string */ |
||
| 53 | public function source() |
||
| 57 | |||
| 58 | /** @return array|object */ |
||
| 59 | public function subject() |
||
| 63 | } |
||
| 64 |