interface LauncherInterface in Ultimate Cron 8.2
Defines a launcher method.
Hierarchy
- interface \Drupal\Component\Plugin\PluginInspectionInterface; interface \Drupal\Component\Plugin\ConfigurableInterface; interface \Drupal\Component\Plugin\DependentPluginInterface; interface \Drupal\Core\Plugin\PluginFormInterface
- interface \Drupal\ultimate_cron\Launcher\LauncherInterface
Expanded class hierarchy of LauncherInterface
All classes that implement LauncherInterface
File
- src/
Launcher/ LauncherInterface.php, line 14
Namespace
Drupal\ultimate_cron\LauncherView source
interface LauncherInterface extends PluginInspectionInterface, ConfigurableInterface, DependentPluginInterface, PluginFormInterface {
/**
* Default settings.
*
* @return array
* Returns array with default configuration of the object.
*/
public function defaultConfiguration();
/**
* Lock job.
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* The job to lock.
*
* @return string|FALSE
* Lock ID or FALSE.
*/
public function lock(CronJobInterface $job);
/**
* Unlock a lock.
*
* @param string $lock_id
* The lock id to unlock.
* @param bool $manual
* Whether this is a manual unlock or not.
*
* @return bool
* TRUE on successful unlock.
*/
public function unlock($lock_id, $manual = FALSE);
/**
* Check if a job is locked.
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* The job to check.
*
* @return string
* Lock ID of the locked job, FALSE if not locked.
*/
public function isLocked(CronJobInterface $job);
/**
* Launch job.
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* The job to launch.
*
* @return bool
* TRUE on successful launch.
*/
public function launch(CronJobInterface $job);
/**
* Fallback implementation of multiple lock check.
*
* Each launcher should implement an optimized version of this method
* if possible.
*
* @param \Drupal\ultimate_cron\CronJobInterface[] $jobs
* Array of UltimateCronJobs to check.
*
* @return array
* Array of lock ids, keyed by job name.
*/
public function isLockedMultiple(array $jobs);
/**
* Default implementation of jobs launcher.
*
* @param \Drupal\ultimate_cron\CronJobInterface[] $jobs
* Array of UltimateCronJobs to launch.
*/
public function launchJobs(array $jobs);
/**
* Format running state.
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* The running job to format.
*/
public function formatRunning(CronJobInterface $job);
/**
* Format unfinished state.
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* The running job to format.
*/
public function formatUnfinished(CronJobInterface $job);
/**
* Default implementation of formatProgress().
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* Job to format progress for.
* @param string $progress
* Progress value for the Job.
*/
public function formatProgress(CronJobInterface $job, $progress);
/**
* Default implementation of initializeProgress().
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* Job to initialize progress for.
*/
public function initializeProgress(CronJobInterface $job);
/**
* Default implementation of finishProgress().
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* Job to finish progress for.
*/
public function finishProgress(CronJobInterface $job);
/**
* Default implementation of getProgress().
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* Job to get progress for.
*
* @return float
* Progress for the job.
*/
public function getProgress(CronJobInterface $job);
/**
* Default implementation of getProgressMultiple().
*
* @param \Drupal\ultimate_cron\CronJobInterface[] $jobs
* Jobs to get progresses for, keyed by job name.
*
* @return array
* Progresses, keyed by job name.
*/
public function getProgressMultiple(array $jobs);
/**
* Default implementation of setProgress().
*
* @param \Drupal\ultimate_cron\CronJobInterface $job
* Job to set progress for.
* @param float $progress
* Progress (0-1).
*/
public function setProgress(CronJobInterface $job, $progress);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConfigurableInterface:: |
public | function | Gets this plugin's configuration. | 12 |
ConfigurableInterface:: |
public | function | Sets the configuration for this plugin instance. | 12 |
DependentPluginInterface:: |
public | function | Calculates dependencies for the configured plugin. | 19 |
LauncherInterface:: |
public | function |
Default settings. Overrides ConfigurableInterface:: |
|
LauncherInterface:: |
public | function | Default implementation of finishProgress(). | 1 |
LauncherInterface:: |
public | function | Default implementation of formatProgress(). | 1 |
LauncherInterface:: |
public | function | Format running state. | 1 |
LauncherInterface:: |
public | function | Format unfinished state. | 1 |
LauncherInterface:: |
public | function | Default implementation of getProgress(). | 1 |
LauncherInterface:: |
public | function | Default implementation of getProgressMultiple(). | 1 |
LauncherInterface:: |
public | function | Default implementation of initializeProgress(). | 1 |
LauncherInterface:: |
public | function | Check if a job is locked. | 1 |
LauncherInterface:: |
public | function | Fallback implementation of multiple lock check. | 1 |
LauncherInterface:: |
public | function | Launch job. | 1 |
LauncherInterface:: |
public | function | Default implementation of jobs launcher. | 1 |
LauncherInterface:: |
public | function | Lock job. | 1 |
LauncherInterface:: |
public | function | Default implementation of setProgress(). | 1 |
LauncherInterface:: |
public | function | Unlock a lock. | 1 |
PluginFormInterface:: |
public | function | Form constructor. | 36 |
PluginFormInterface:: |
public | function | Form submission handler. | 32 |
PluginFormInterface:: |
public | function | Form validation handler. | 18 |
PluginInspectionInterface:: |
public | function | Gets the definition of the plugin implementation. | 4 |
PluginInspectionInterface:: |
public | function | Gets the plugin_id of the plugin instance. | 2 |