- Openclerk\Jobs\Job
interface Openclerk\Jobs \ Job
- All known implementing classes:
- GenericOpenclerkJob
Represents a single Job that needs to be run.
Method Summary
Name | Description |
---|---|
failed(Exception $e, Connection $db, Logger $logger) | Callback function for when the job failed. Can do nothing. |
passed(Connection $db, Logger $logger) | Callback function for when the job passed. Can do nothing. |
run(Connection $db, Logger $logger) | Run this job. If this job throws an exception, the job will be considered failed. If this job does not, the job will be considered passed. |
public function failed(Exception $e, Connection $db, Logger $logger)
Callback function for when the job failed. Can do nothing.
public function passed(Connection $db, Logger $logger)
Callback function for when the job passed. Can do nothing.
public function run(Connection $db, Logger $logger)
Run this job. If this job throws an exception, the job will be considered failed. If this job does not, the job will be considered passed.
- Throws:
Exception - if the job failed