Source for file Exception.class.php

Documentation is available at Exception.class.php

  1. <?php
  2. /**
  3.  * Gumbo Library Framework
  4.  *
  5.  * LICENSE
  6.  * This library is being released under the terms of the New BSD License.  A
  7.  * copy of the license is packaged with the software (LICENSE.txt).  If no
  8.  * copy is found, a copy of the license template can be found at:
  9.  * http://www.opensource.org/licenses/bsd-license.php
  10.  * 
  11.  * @category Gumbo
  12.  * @package Error
  13.  * @copyright Copyright (c) 2007, iBayou, Michael Luster
  14.  * @license http://www.opensource.org/licenses/bsd-license.php New BSD License
  15.  * @author Michael Luster <mluster79@yahoo.com>
  16.  * @link http://sourceforge.net/projects/phpgumbo
  17.  * @version 0.0.1
  18.  */
  19.  
  20. /**
  21.  * Exception Interface
  22.  * 
  23.  * The Interface adds a few extra methods to the pre-defined Exception class
  24.  * in PHP5.
  25.  *
  26.  * @category Gumbo
  27.  * @package Error
  28.  * @copyright Copyright (c) 2007, iBayou, Michael Luster
  29.  * @license http://www.opensource.org/licenses/bsd-license.php New BSD License
  30.  * @author Michael Luster <mluster79@yahoo.com>
  31.  * @link http://sourceforge.net/projects/phpgumbo
  32.  * @desc Exception Interface
  33.  * @version 0.0.1
  34.  */
  35.  
  36.     
  37.     /** ACTION METHODS **/
  38.     /**
  39.      * Displays the error title from __toString()
  40.      * @param bool $val 
  41.      */
  42.     public static function displayTitle ($val);
  43.     
  44.     /**
  45.      * Displays the function information from __toString()
  46.      * @param bool $val 
  47.      */
  48.     public static function displayFile ($val);
  49.     
  50.     /**
  51.      * Displays the file information from __toString()
  52.      * @param bool $val 
  53.      */
  54.     public static function displayFunction ($val);
  55.     
  56.     /**
  57.      * Displays the error trace information from __toString()
  58.      * @param bool $val 
  59.      */
  60.     public static function displayTrace ($val);
  61.     
  62.     
  63.     
  64.     /** MUTATOR METHODS **/
  65.     /**
  66.      * Sets the Message text
  67.      * @param string $mess 
  68.      */
  69.     public function setMessage ($mess);
  70.     
  71.     /**
  72.      * Sets the error level code
  73.      * @param int $code 
  74.      */
  75.     public function setCode ($code);
  76.     
  77.     /**
  78.      * Sets the file name where error occured (__FILE__)
  79.      * @param string $file 
  80.      */
  81.     public function setFile ($file);
  82.     
  83.     /**
  84.      * Sets the line number where error occured (__LINE__)
  85.      * @param int $line 
  86.      */
  87.     public function setLine ($line);
  88.     
  89.     /**
  90.      * Sets the function or class method (__METHOD__) or (__FUNCTION__)
  91.      * @param string $func function/method name
  92.      */
  93.     public function setFunction ($func);
  94.     
  95.     
  96.     
  97.     /** ACCESSOR METHOD **/
  98.     /**
  99.      * Returns the function / class method name
  100.      * @return string 
  101.      */
  102.     public function getFunction ();
  103.     
  104. }
  105.  
  106. ?>