IJob

interface OCP\BackgroundJob\IJob
Interface IJob
Implemented by:OCP\BackgroundJob\Job OC\BackgroundJob\Job
Source:lib/public/BackgroundJob/IJob.php#37

Methods

public OCP\BackgroundJob\IJob::execute($jobList, $logger=null)
Run the background job with the registered argument
Source:

lib/public/BackgroundJob/IJob.php#45

Parameters:
Since:

7.0.0

public OCP\BackgroundJob\IJob::setId($id)
Source:lib/public/BackgroundJob/IJob.php#50
Since:7.0.0
public OCP\BackgroundJob\IJob::setLastRun($lastRun)
Source:lib/public/BackgroundJob/IJob.php#55
Since:7.0.0
public OCP\BackgroundJob\IJob::setArgument($argument)
Source:

lib/public/BackgroundJob/IJob.php#61

Parameters:
  • $argument (mixed)
Since:

7.0.0

public OCP\BackgroundJob\IJob::getId()
Get the id of the background job
This id is determined by the job list when a job is added to the list
Source:lib/public/BackgroundJob/IJob.php#70
Returns:int
Since:7.0.0
public OCP\BackgroundJob\IJob::getLastRun()
Get the last time this job was run as unix timestamp
Source:lib/public/BackgroundJob/IJob.php#78
Returns:int
Since:7.0.0
public OCP\BackgroundJob\IJob::getArgument()
Get the argument associated with the background job
This is the argument that will be passed to the background job
Source:lib/public/BackgroundJob/IJob.php#87
Returns:mixed
Since:7.0.0