* @param string exception message
* @param int $code
* @param Exception $previous
- *
- * @internal param array|\Exception|int|null|\PEAR_Error $exception cause
- * @internal param int|null $exception code or null
*/
public function __construct($message = NULL, $code = 0, Exception$previous = NULL) {
parent::__construct($message, $code, $previous);
class CRM_Core_Error extends PEAR_ErrorStack {
/**
- * status code of various types of errors
+ * Status code of various types of errors
* @var const
*/
CONST FATAL_ERROR = 2;
public static $modeException = NULL;
/**
- * singleton function used to manage this object.
+ * Singleton function used to manage this object.
*
* @param null $package
* @param bool $msgCallback
}
/**
- * constructor
+ * Constructor
*/
function __construct() {
parent::__construct('CiviCRM');
}
/**
- * create the main callback method. this method centralizes error processing.
+ * Create the main callback method. this method centralizes error processing.
*
* the errors we expect are from the pear modules DB, DB_DataObject
* which currently use PEAR::raiseError to notify of error messages.
}
/**
- * display an error page with an error message describing what happened
+ * Display an error page with an error message describing what happened
*
- * @param null $message
- * @param null $code
- * @param null $email
+ * @param string $message the error message
+ * @param string $code the error code if any
+ * @param string $email the email address to notify of this situation
*
* @throws Exception
- * @internal param \message $string the error message
- * @internal param \code $string the error code if any
- * @internal param \email $string the email address to notify of this situation
*
* @return void
* @static
- * @acess public
+ * @access public
*/
static function fatal($message = NULL, $code = NULL, $email = NULL) {
$vars = array(
}
/**
- * display an error page with an error message describing what happened
+ * Display an error page with an error message describing what happened
*
* This function is evil -- it largely replicates fatal(). Hopefully the
* entire CRM_Core_Error system can be hollowed out and replaced with
*
* @return void
* @static
- * @acess public
+ * @access public
*/
static function handleUnhandledException($exception) {
$config = CRM_Core_Config::singleton();
}
/**
- * outputs pre-formatted debug information. Flushes the buffers
+ * Outputs pre-formatted debug information. Flushes the buffers
* so we can interrupt a potential POST/redirect
*
* @param string name of debug section
* Similar to the function debug. Only difference is
* in the formatting of the output.
*
- * @param $variable_name
- * @param $variable
- * @param bool $print
- * @param bool $log
+ * @param string $variable_name
+ * @param mixed $variable
+ * @param bool $print should we use print_r ? (else we use var_dump)
+ * @param bool $log should we log or return the output
* @param string $comp variable name
*
- * @internal param \reference $mixed to variables that we need a trace of
- * @internal param \should $bool we use print_r ? (else we use var_dump)
- * @internal param \should $bool we log or return the output
- *
* @return string the generated output
*
* @access public
}
/**
- * display the error message on terminal
+ * Display the error message on terminal
*
* @param $message
* @param bool $out should we log or return the output
* @param $message
* @param int $code
* @param string $level
- * @param null $params
+ * @param array $params
*
* @return object
*/
}
/**
- * Function to reset the error stack
+ * Reset the error stack
*
* @access public
* @static