master

laravel/framework

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

DatabaseBusy.php

TLDR

This file defines a class DatabaseBusy in the Illuminate\Database\Events namespace. The class has two public properties $connectionName and $connections, and a constructor method.

Classes

DatabaseBusy

This class represents an event that is triggered when the database is busy. It has the following properties:

  • $connectionName (string): The name of the database connection.
  • $connections (int): The number of open connections.

The class has a constructor method that accepts the $connectionName and $connections as parameters and initializes the corresponding properties.

<?php

namespace Illuminate\Database\Events;

class DatabaseBusy
{
    /**
     * The database connection name.
     *
     * @var string
     */
    public $connectionName;

    /**
     * The number of open connections.
     *
     * @var int
     */
    public $connections;

    /**
     * Create a new event instance.
     *
     * @param  string  $connectionName
     * @param  int  $connections
     */
    public function __construct($connectionName, $connections)
    {
        $this->connectionName = $connectionName;
        $this->connections = $connections;
    }
}