JobExceptionOccurred.php 779 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445
  1. <?php
  2. namespace think\queue\event;
  3. use Exception;
  4. use think\queue\Job;
  5. class JobExceptionOccurred
  6. {
  7. /**
  8. * The connection name.
  9. *
  10. * @var string
  11. */
  12. public $connectionName;
  13. /**
  14. * The job instance.
  15. *
  16. * @var Job
  17. */
  18. public $job;
  19. /**
  20. * The exception instance.
  21. *
  22. * @var Exception
  23. */
  24. public $exception;
  25. /**
  26. * Create a new event instance.
  27. *
  28. * @param string $connectionName
  29. * @param Job $job
  30. * @param Exception $exception
  31. * @return void
  32. */
  33. public function __construct($connectionName, $job, $exception)
  34. {
  35. $this->job = $job;
  36. $this->exception = $exception;
  37. $this->connectionName = $connectionName;
  38. }
  39. }