Overview

Namespaces

  • Jyxo
    • Beholder
      • TestCase
    • Gettext
      • Parser
    • Input
      • Chain
      • Filter
      • Validator
    • Mail
      • Email
        • Attachment
      • Parser
      • Sender
    • Rpc
      • Json
      • Xml
    • Shell
    • Spl
    • Svn
    • Time
    • Webdav
  • PHP

Classes

  • Charset
  • Color
  • Css
  • ErrorHandler
  • ErrorMail
  • FirePhp
  • Html
  • HtmlTag
  • SpamFilter
  • String
  • Timer
  • XmlReader

Exceptions

  • Exception
  • Overview
  • Namespace
  • Class
  • Tree
  • Deprecated

Class ErrorHandler

Error and exception handler.

Namespace: Jyxo
Category: Jyxo
Package: Jyxo\ErrorHandling
Copyright: Copyright (c) 2005-2011 Jyxo, s.r.o.
License: https://github.com/jyxo/php/blob/master/license.txt
Author: Jaroslav HanslĂ­k
Located at ErrorHandler.php
Methods summary
final public
# __construct( )

Constructor preventing from creating class instances.

Constructor preventing from creating class instances.

Throws

LogicException
When trying to create an instance
public static
# init( boolean $debug = false )

Initializes error handling.

Initializes error handling.

Parameters

$debug
boolean
Turn debugging on?
public static
# setErrorMail( Jyxo\ErrorMail $errorMail )

Sets \Jyxo\ErrorMail instance for sending fatal error emails (used by the shutdown function and error handler).

Sets \Jyxo\ErrorMail instance for sending fatal error emails (used by the shutdown function and error handler).

Parameters

$errorMail
Jyxo\ErrorMail
public static boolean
# handleError( integer $type, string $message, string $file, integer $line, array $context )

Handles errors and logs them.

Handles errors and logs them.

Parameters

$type
integer
Error type
$message
string
Error message
$file
string
File where the error occurred
$line
integer
Line on which the error occurred
$context
array
Error context variables

Returns

boolean
Was the error processed?
public static
# handleException( Exception $exception )

Catches exceptions and logs them.

Catches exceptions and logs them.

Parameters

$exception
Jyxo\Exception
Uncaught exception
public static
# handleFatalError( )

Handles critical errors and logs them.

Handles critical errors and logs them.

public static
# exception( Exception $exception, boolean $fire = true )

Adds a caught exception.

Adds a caught exception.

Parameters

$exception
Jyxo\Exception
Caught exception
$fire
boolean
Shall we use FirePHP?
public static boolean
# log( array $message, boolean $fire = true )

Logs a message.

Logs a message.

Parameters

$message
array
Message definition
$fire
boolean
Shall we use FirePHP?

Returns

boolean
Was logging successful?
Constants summary
string NOTICE 'notice'
#

Notice.

Notice.

string WARNING 'warning'
#

Warning.

Warning.

string ERROR 'error'
#

Error.

Error.

string FATAL 'fatal'
#

Fatal error.

Fatal error.

string EXCEPTION 'exception'
#

Exception.

Exception.

string STRICT 'strict'
#

Strict rules warning.

Strict rules warning.

string DEPRECATED 'deprecated'
#

Deprecated code usage warning.

Deprecated code usage warning.

Jyxo PHP Library API documentation generated by ApiGen 2.3.0