AutomatedCron
class AutomatedCron implements EventSubscriberInterface (View source)
A subscriber running cron after a response is sent.
Properties
| protected CronInterface | $cron | The cron service. |
|
| protected Config | $config | The cron configuration. |
|
| protected StateInterface | $state | The state key value store. |
Methods
__construct(CronInterface $cron, ConfigFactoryInterface $config_factory, StateInterface $state)
Constructs a new automated cron runner.
onTerminate(TerminateEvent $event)
Run the automated cron if enabled.
static array
getSubscribedEvents()
Registers the methods in this class that should be listeners.
Details
__construct(CronInterface $cron, ConfigFactoryInterface $config_factory, StateInterface $state)
Constructs a new automated cron runner.
onTerminate(TerminateEvent $event)
Run the automated cron if enabled.
static array
getSubscribedEvents()
Registers the methods in this class that should be listeners.