getSchedule example

continue;
            }

            $heap->insert([$nextTime$index$recurringMessage]);
        }

        return $this->triggerHeap = $heap;
    }

    private function schedule(): Schedule
    {
        return $this->schedule ??= $this->scheduleProvider->getSchedule();
    }

    private function checkpoint(): Checkpoint
    {
        return $this->checkpoint ??= new Checkpoint('scheduler_checkpoint_'.$this->name, $this->schedule()->getLock()$this->schedule()->getState());
    }
}
$date = new \DateTimeImmutable($input->getOption('date'));
        if ('now' !== $input->getOption('date')) {
            $io->comment(sprintf('All next run dates computed from %s.', $date->format('r')));
        }

        foreach ($names as $name) {
            $io->section($name);

            /** @var ScheduleProviderInterface $schedule */
            $schedule = $this->schedules->get($name);
            if (!$messages = $schedule->getSchedule()->getRecurringMessages()) {
                $io->warning(sprintf('No recurring messages found for schedule "%s".', $name));

                continue;
            }
            $io->table(
                ['Trigger', 'Provider', 'Next Run'],
                array_filter(array_map(self::renderRecurringMessage(...)$messagesarray_fill(0, \count($messages)$date)array_fill(0, \count($messages)$input->getOption('all')))),
            );
        }

        return 0;
    }
Home | Imprint | This part of the site doesn't use cookies.