Source for file Error.class.php

Documentation is available at Error.class.php

  1. <?php
  2.  
  3. require_once(HARMONI."errorHandler/HarmoniException.class.php");
  4.  
  5. /**
  6. * This class is a hold-over from Harmoni's old error Handler, which tried to
  7. * do some exception-like things in PHP4. The new implementation, just extends
  8. * the default exception for compatability purposes
  9. *
  10. * @package harmoni.error_handler
  11. *
  12. * @copyright Copyright &copy; 2005, Middlebury College
  13. * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License (GPL)
  14. *
  15. * @version $Id: Error.class.php,v 1.8 2007/09/19 14:04:09 adamfranco Exp $
  16. */
  17.  
  18. class Error
  19. extends HarmoniException
  20. {
  21.  
  22. /**
  23. * The constructor. Create a new error.
  24. * @param string $description A description of the error.
  25. * @param string $type The type of error. For sorting purposes. ie.: "user", "db", etc.
  26. * @param boolean $isFatal True if the error should halt execution.
  27. * @access public
  28. */
  29.  
  30. function __construct ($description,$type = "",$isFatal = true) {
  31. parent::__construct($description, 0, $type, $isFatal);
  32. }
  33. }
  34.  
  35. /**
  36. * This class is a hold-over from Harmoni's old error Handler, which tried to
  37. * do some exception-like things in PHP4. The new implementation, just extends
  38. * the default exception for compatability purposes
  39. *
  40. * @package harmoni.error_handler
  41. *
  42. * @copyright Copyright &copy; 2005, Middlebury College
  43. * @license http://www.gnu.org/copyleft/gpl.html GNU General Public License (GPL)
  44. *
  45. * @version $Id: Error.class.php,v 1.8 2007/09/19 14:04:09 adamfranco Exp $
  46. */
  47. class UnknownDBError extends Error {
  48. function __construct($type) {
  49. parent::Error("An unkonwn Database error occured.", $type, true);
  50. }
  51. }
  52.  
  53. ?>

Documentation generated on Wed, 19 Sep 2007 10:23:02 -0400 by phpDocumentor 1.3.0RC3