1 | <?php |
||
16 | class Event implements FromArrayInterface |
||
17 | { |
||
18 | /** @var string */ |
||
19 | private $title; |
||
20 | |||
21 | /** @var string */ |
||
22 | private $message; |
||
23 | |||
24 | /** @var array */ |
||
25 | private $trackers; |
||
26 | |||
27 | /** |
||
28 | * @param string $title |
||
29 | * @param string $message |
||
30 | * @param array $trackers |
||
31 | */ |
||
32 | public function __construct(string $title, string $message, array $trackers) |
||
39 | |||
40 | /** |
||
41 | * @return string |
||
42 | */ |
||
43 | public function getTitle() |
||
47 | |||
48 | /** |
||
49 | * @param string $title |
||
50 | * |
||
51 | * @return $this |
||
52 | */ |
||
53 | public function setTitle(string $title) |
||
59 | |||
60 | /** |
||
61 | * @return string |
||
62 | */ |
||
63 | public function getMessage() |
||
67 | |||
68 | /** |
||
69 | * @param string $message |
||
70 | * |
||
71 | * @return $this |
||
72 | */ |
||
73 | public function setMessage(string $message) |
||
79 | |||
80 | /** |
||
81 | * @return array |
||
82 | */ |
||
83 | public function getTrackers() |
||
87 | |||
88 | /** |
||
89 | * @param array $trackers |
||
90 | * |
||
91 | * @return $this |
||
92 | */ |
||
93 | public function setTrackers(array $trackers) |
||
99 | |||
100 | /** |
||
101 | * {@inheritdoc} |
||
102 | */ |
||
103 | public static function fromArray(array $data) |
||
107 | |||
108 | /** |
||
109 | * @return array |
||
110 | */ |
||
111 | public function toArray() |
||
119 | } |
||
120 |