Support Joomla!

Joomla! 1.5 Documentation

Packages

Package: Joomla-Framework

License

Content on this site is copyright © 2005 - 2008 by the individual contributors and can be used in accordance with the Creative Commons License, Attribution- NonCommercial- ShareAlike 2.5. Some parts of this website may be subject to other licenses.

 Class JException

Description

Joomla! Exception object.

Located in /joomla/error/exception.php (line 25)

Class JObject   (Subpackage Base)

Class JException   (Subpackage Error)
Variable Summary
Variable array $args
Variable mixed $backtrace
Variable string $class
Variable string $code
Variable string $file
Variable string $function
Variable string $info
Variable string $level
Variable int $line
Variable string $message
Variable string $type
Method Summary
Constructor JException __construct (string $msg, [string $code = 0], [int $level = null], [string $info = null], [boolean $backtrace = false])
Method integer getCode ()
Method string getFile ()
Method integer getLine ()
Method string getMessage ()
Method array getTrace ()
Method string getTraceAsString ()
Method string toString ()
Variables
array $args = array() (line 86)

Arguments recieved by the method the error occurred in [Available if backtrace is enabled]

mixed $backtrace = null (line 92)

Backtrace information

string $class = null (line 74)

Name of the class the error occurred in [Available if backtrace is enabled]

string $code = null (line 37)

Error code

string $file = null (line 56)

Name of the file the error occurred in [Available if backtrace is enabled]

string $function = null (line 68)

Name of the method the error occurred in [Available if backtrace is enabled]

string $info = '' (line 50)

Additional info about the error relevant to the developer

  • e.g. if a database connect fails, the dsn used

string $level = null (line 31)

Error level

int $line = 0 (line 62)

Line number the error occurred in [Available if backtrace is enabled]

string $message = null (line 43)

Error message

string $type = null (line 80)

Error type

Inherited Variables

Inherited from JObject

Variable JObject::$_errors
Methods
Constructor __construct (line 105)

Constructor

  • used to set up the error with all needed error details.

  • access: protected
JException __construct (string $msg, string $code, [int $level = null], [string $info = null], [boolean $backtrace = false])
  • string $msg: The error message
  • string $code: The error code from the application
  • int $level: The error level (use the PHP constants E_ALL, E_NOTICE etc.).
  • string $info: Optional: The additional error information.
  • boolean $backtrace: True if backtrace information is to be collected

Redefinition of:
JObject::__construct()
Class constructor, overridden in descendant classes.
getCode (line 168)

Method to get the exception code

  • since: 1.5
  • access: public
  • final:
integer getCode ()
getFile (line 181)

Method to get the source filename where the exception occured

  • since: 1.5
  • access: public
  • final:
string getFile ()
getLine (line 194)

Method to get the source line where the exception occured

  • since: 1.5
  • access: public
  • final:
integer getLine ()
getMessage (line 155)

Method to get the exception message

  • since: 1.5
  • access: public
  • final:
string getMessage ()
getTrace (line 207)

Method to get the array of the backtrace()

  • return: backtrace
  • since: 1.5
  • access: public
  • final:
array getTrace ()
getTraceAsString (line 226)

Method to get the formatted backtrace information

  • return: Formated string of trace
  • since: 1.5
  • access: public
  • final:
string getTraceAsString ()
toString (line 248)

Returns to error message

  • return: Error message
  • since: 1.5
  • access: public
string toString ()

Redefinition of:
JObject::toString()
Object-to-string conversion.

Inherited Methods

Inherited From JObject

 JObject::JObject()
 JObject::__construct()
 JObject::get()
 JObject::getError()
 JObject::getErrors()
 JObject::getProperties()
 JObject::getPublicProperties()
 JObject::set()
 JObject::setError()
 JObject::setProperties()
 JObject::toString()

Documentation generated on Tue, 29 Jan 2008 18:45:41 +0000 by phpDocumentor 1.3.1