dmBridge PHP API
DMPDOException.php
00001 <?php
00002 #
00003 # dmBridge: a data access framework for CONTENTdm(R)
00004 # Copyright © 2009, 2010 Board of Regents of the Nevada System of Higher
00005 # Education, on behalf of the University of Nevada, Las Vegas
00006 #
00007 
00012 class DMPDOException extends DMDataStoreException {
00013 
00018    public function __construct(PDOException $e) {
00019       // check the error code to make sure it's not a string, which it
00020       // sometimes is, which causes Exception to choke
00021       $code = is_int($e->getCode()) ? $e->getCode() : null;
00022       parent::__construct('PDO: ' . $e->getMessage(), $code);
00023    }
00024 
00025 }
 All Data Structures Functions Variables