master

laravel/framework

Last updated at: 29/12/2023 09:21

ScheduledTaskFinished.php

TLDR

This file defines a class ScheduledTaskFinished in the Illuminate\Console\Events namespace. It has two properties $task and $runtime, and a constructor to initialize these properties.

Classes

ScheduledTaskFinished

This class represents a finished scheduled task event. It has the following properties:

  • $task: Represents the scheduled event that ran.
  • $runtime: Represents the runtime of the scheduled event.

It has a constructor that takes in a Event object and the runtime as arguments and initializes the $task and $runtime properties.

<?php

namespace Illuminate\Console\Events;

use Illuminate\Console\Scheduling\Event;

class ScheduledTaskFinished
{
    /**
     * The scheduled event that ran.
     *
     * @var \Illuminate\Console\Scheduling\Event
     */
    public $task;

    /**
     * The runtime of the scheduled event.
     *
     * @var float
     */
    public $runtime;

    /**
     * Create a new event instance.
     *
     * @param  \Illuminate\Console\Scheduling\Event  $task
     * @param  float  $runtime
     * @return void
     */
    public function __construct(Event $task, $runtime)
    {
        $this->task = $task;
        $this->runtime = $runtime;
    }
}