| 1 | <?php |
||
| 17 | class JobExceptionOccurredEvent extends Event |
||
| 18 | { |
||
| 19 | /** |
||
| 20 | * The connection name. |
||
| 21 | * |
||
| 22 | * @var string |
||
| 23 | */ |
||
| 24 | protected $connectionName; |
||
| 25 | |||
| 26 | /** |
||
| 27 | * The job instance. |
||
| 28 | * |
||
| 29 | * @var JobContractInterface |
||
| 30 | */ |
||
| 31 | protected $job; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * The exception instance. |
||
| 35 | * |
||
| 36 | * @var \Exception |
||
| 37 | */ |
||
| 38 | protected $exception; |
||
| 39 | |||
| 40 | /** |
||
| 41 | * Create a new event instance. |
||
| 42 | * |
||
| 43 | * @param string $connectionName |
||
| 44 | * @param JobContractInterface $job |
||
| 45 | * @param Exception $exception |
||
| 46 | */ |
||
| 47 | public function __construct(string $connectionName, JobContractInterface $job, Exception $exception) |
||
| 53 | |||
| 54 | /** |
||
| 55 | * @return string |
||
| 56 | */ |
||
| 57 | public function getConnectionName(): string |
||
| 61 | |||
| 62 | /** |
||
| 63 | * @return JobContractInterface |
||
| 64 | */ |
||
| 65 | public function getJob(): JobContractInterface |
||
| 69 | |||
| 70 | /** |
||
| 71 | * @return Exception |
||
| 72 | */ |
||
| 73 | public function getException(): Exception |
||
| 77 | } |
||
| 78 |