home *** CD-ROM | disk | FTP | other *** search
/ Cricao de Sites - 650 Layouts Prontos / WebMasters.iso / Servidores / xampp-win32-1.6.7-installer.exe / php / PEAR / Services / YouTube / Exception.php
Encoding:
PHP Script  |  2008-07-02  |  1.3 KB  |  53 lines

  1. <?php
  2. /* vim: set expandtab tabstop=4 shiftwidth=4 softtabstop=4: */
  3.  
  4. /**
  5.  * Exception Class for Services_YouTube
  6.  *
  7.  * PHP versions 5
  8.  *
  9.  * LICENSE: This source file is subject to version 3.0 of the PHP license
  10.  * that is available through the world-wide-web at the following URI:
  11.  * http://www.php.net/license/3_0.txt.  If you did not receive a copy of
  12.  * the PHP License and are unable to obtain it through the web, please
  13.  * send a note to license@php.net so we can mail you a copy immediately.
  14.  *
  15.  */
  16.  
  17. /**
  18.  * uses PEAR_Exception
  19.  */
  20. require_once 'PEAR/Exception.php';
  21.  
  22. /**
  23.  * Services_YouTube_Exception
  24.  *
  25.  * This class is used in all place in the package where Exceptions
  26.  * are raised.
  27.  *
  28.  * @package Services_YouTube
  29.  * @author Shin OHNO <ganchiku@gmail.com>
  30.  */
  31. class Services_YouTube_Exception extends PEAR_Exception
  32. {
  33.     /**
  34.      * errorHandlerCallback
  35.      *
  36.      * @param int $code
  37.      * @param string $string
  38.      * @param string $file
  39.      * @param int $line
  40.      * @param array $context
  41.      * @static
  42.      * @access public
  43.      * throw Services_YouTube_Exception
  44.      */
  45.     public static function errorHandlerCallback($code, $string, $file, $line, $context) {
  46.         $e = new self($string, $code);
  47.         $e->line = $line;
  48.         $e->file = $file;
  49.         throw $e;
  50.     }
  51. }
  52. ?>
  53.