ConnectionFailed.php 408 Bytes
Newer Older
1 2 3 4 5 6
<?php

declare(strict_types=1);

namespace Doctrine\DBAL\Driver\IBMDB2\Exception;

7
use Doctrine\DBAL\Driver\AbstractException;
8 9 10 11 12

use function db2_conn_error;
use function db2_conn_errormsg;

/**
13 14
 * @internal
 *
15 16
 * @psalm-immutable
 */
17
final class ConnectionFailed extends AbstractException
18 19 20 21 22 23
{
    public static function new(): self
    {
        return new self(db2_conn_errormsg(), db2_conn_error());
    }
}