1 | <?php |
||
11 | class JobEndedEvent extends Event |
||
12 | { |
||
13 | /** |
||
14 | * Events triggered by eventmanager |
||
15 | */ |
||
16 | const EVENT_JOB_ENDED = 'cronjob-ended'; |
||
17 | |||
18 | /** |
||
19 | * @var JobReport |
||
20 | */ |
||
21 | private $report; |
||
22 | |||
23 | /** |
||
24 | * @var ShellJob |
||
25 | */ |
||
26 | private $job; |
||
27 | |||
28 | /** |
||
29 | * Constructor |
||
30 | * |
||
31 | * Accept a target and its parameters. |
||
32 | * |
||
33 | * @param string $name Event name |
||
34 | * @param string|object $target |
||
35 | * @param array|\ArrayAccess $params |
||
36 | */ |
||
37 | public function __construct($name = null, $target = null, $params = null) |
||
41 | |||
42 | /** |
||
43 | * @param JobReport $report |
||
44 | * @return $this |
||
45 | */ |
||
46 | public function setReport(JobReport $report) |
||
51 | |||
52 | /** |
||
53 | * @return JobReport |
||
54 | */ |
||
55 | public function getReport() |
||
59 | |||
60 | /** |
||
61 | * @return ShellJob |
||
62 | */ |
||
63 | public function getJob() |
||
67 | |||
68 | /** |
||
69 | * @param ShellJob $job |
||
70 | * @return $this |
||
71 | */ |
||
72 | public function setJob($job) |
||
77 | } |
||
78 |