PHP Classes

File: src/Exception/ConstructorFailed.php

Recommend this page to a friend!
  Classes of Scott Arciszewski   EasyDB   src/Exception/ConstructorFailed.php   Download  
File: src/Exception/ConstructorFailed.php
Role: Class source
Content type: text/plain
Description: Exception
Class: EasyDB
Simple Database Abstraction Layer around PDO
Author: By
Last change: Refactoring

- Change exceptions to extend the same base class
- Update code style to avoid \\ prefixes (use imports instead)
Date: 1 year ago
Size: 519 bytes
 

Contents

Class file image Download
<?php
namespace ParagonIE\EasyDB\Exception;

use
ParagonIE\Corner\CornerTrait;
use
PDOException;

/**
 * ConstructorFailed.
 *
 * @package ParagonIE\EasyDB
 */
class ConstructorFailed extends EasyDBException
{
    use
CornerTrait;

    private ?
PDOException $realException = null;

    public function
setRealException(PDOException $ex): self
   
{
       
$this->realException = $ex;
        return
$this;
    }

    public function
getRealException(): ?PDOException
   
{
        return
$this->realException;
    }
}