API15

Difference between revisions of "JException"

From Joomla! Documentation

(New page: <span class="editsection" style="font-size:76%;"> <nowiki>[</nowiki>Edit Descripton<nowiki>]</nowiki> </span> {{Description:JException}} ===Defined in=== ...)
 
m (preparing for archive only)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<span class="editsection" style="font-size:76%;">
 
<nowiki>[</nowiki>[[Description:JException|Edit Descripton]]<nowiki>]</nowiki>
 
</span>
 
{{Description:JException}}
 
 
 
===Defined in===
 
===Defined in===
 
libraries/joomla/error/exception.php
 
libraries/joomla/error/exception.php
Line 38: Line 33:
 
|Returns to error message
 
|Returns to error message
 
|}
 
|}
 +
 
===Importing===
 
===Importing===
 
<source lang="php">jimport( 'joomla.error.exception' );</source>
 
<source lang="php">jimport( 'joomla.error.exception' );</source>
  
<span class="editsection" style="font-size:76%;">
+
 
<nowiki>[</nowiki>[[SeeAlso:JException|Edit See Also]]<nowiki>]</nowiki>
+
 
</span>
 
{{SeeAlso:JException}}
 
  
 
===Examples===
 
===Examples===
<CodeExamplesForm />
+
=== Code Examples ===
 
<dpl>
 
<dpl>
 
  noresultsheader=\n
 
  noresultsheader=\n
 
  category=JException
 
  category=JException
  category=CodeExample
+
  namespace=CodeExample
 
  category=ClassExample
 
  category=ClassExample
 
  include=*
 
  include=*
 
  format= ,,,
 
  format= ,,,
 
</dpl>
 
</dpl>

Latest revision as of 19:35, 24 March 2017

The "API15" namespace is an archived namespace. This page contains information for a Joomla! version which is no longer supported. It exists only as a historical reference, it will not be improved and its content may be incomplete and/or contain broken links.

Defined in[edit]

libraries/joomla/error/exception.php

Methods[edit]

Method name Description
__construct Constructor

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

getMessage Method to get the exception message
getCode Method to get the exception code
getFile Method to get the source filename where the exception occured
getLine Method to get the source line where the exception occured
getTrace Method to get the array of the backtrace()
getTraceAsString Method to get the formatted backtrace information
toString Returns to error message

Importing[edit]

jimport( 'joomla.error.exception' );



Examples[edit]

Code Examples[edit]