class
Illuminate
/
Console
/
Scheduling
/
Schedule
You are viewing an older version of the documentation. For the latest, please visit master documentation.
Schedule
Uses
Constants
public
SUNDAY
public
MONDAY
Default: 1
public
TUESDAY
Default: 2
public
WEDNESDAY
Default: 3
public
THURSDAY
Default: 4
public
FRIDAY
Default: 5
public
SATURDAY
Default: 6
Properties
protected
$events Illuminate\...\Event[]
All of the events on the schedule.
Default: []
protected
$timezone DateTimeZone |string
The timezone the date should be evaluated on.
Default: null
Methods
public
__construct ( $timezone ) : void
Create a new schedule instance.
Parameters
- $timezone DateTimeZone |string|null
public
call ( $callback , array $parameters ) : CallbackEvent
Add a new callback event to the schedule.
Parameters
- $callback string|callable
- $parameters array
public
command ( $command , array $parameters ) : Event
Add a new Artisan command event to the schedule.
Parameters
- $command string
- $parameters array
public
job ( $job , $queue , $connection ) : CallbackEvent
Add a new job callback event to the schedule.
Parameters
- $job object|string
- $queue string|null
- $connection string|null
protected
dispatchToQueue ( $job , $queue , $connection ) : void
Dispatch the given job to the queue.
Parameters
- $job object
- $queue string|null
- $connection string|null
protected
dispatchUniqueJobToQueue ( $job , $queue , $connection ) : void
Dispatch the given unique job to the queue.
Parameters
- $job object
- $queue string|null
- $connection string|null
protected
dispatchNow ( $job ) : void
Dispatch the given job right now.
Parameters
- $job object
public
exec ( $command , array $parameters ) : Event
Add a new command event to the schedule.
Parameters
- $command string
- $parameters array
protected
compileParameters ( array $parameters ) : string
Compile parameters for a command.
Parameters
- $parameters array
public
compileArrayInput ( $key , $value ) : string
Compile array input for a command.
Parameters
- $key string|int
- $value array
public
serverShouldRun ( Event $event , DateTimeInterface $time ) : bool
Determine if the server is allowed to run this event.
Parameters
- $event Event
- $time DateTimeInterface
public
dueEvents ( $app ) : Collection
Get all of the events on the schedule that are due.
Parameters
- $app Application
public
events ( ) : Illuminate\...\Event[]
Get all of the events on the schedule.
public
useCache ( $store ) : $this
Specify the cache store that should be used to store mutexes.
Parameters
- $store string