Packages:
default
System
System.Caching
System.Collections
System.Data
System.Data.ActiveRecord
System.Data.ActiveRecord.Relations
System.Data.ActiveRecord.Scaffold
System.Data.ActiveReecord.Scaffold.InputBuilder
System.Data.Commom.Sqlite
System.Data.Common
System.Data.Common.Mssql
System.Data.Common.Mysql
System.Data.Common.Oracle
System.Data.Common.Pgsql
System.Data.Common.Sqlite
System.Data.DataGateway
System.Data.SqlMap
System.Data.SqlMap.Configuration
System.Data.SqlMap.Statements
System.Exceptions
System.I18N
System.IO
System.Security
System.Util
System.Web
System.Web.Services
System.Web.UI
System.Web.UI.ActiveControls
System.Web.UI.WebControls
System.Web.UI.WebControls.assets
System.Xml


Classes:
Keyword

Class TException

Exception
   |
   --TException

TException class

TException is the base class for all PRADO exceptions.

TException provides the functionality of translating an error code into a descriptive error message in a language that is preferred by user browser. Additional parameters may be passed together with the error code so that the translated message contains more detailed information.

By default, TException looks for a message file by calling getErrorMessageFile() method, which uses the "message-xx.txt" file located under "System.Exceptions" folder, where "xx" is the code of the user preferred language. If such a file is not found, "message.txt" will be used instead.

Since: 3.0
Author: Qiang Xue <qiang.xue@gmail.com>

Constructor Summary
public
__construct Array
Constructor.

Method Summary
string
string
protected  string
void
setErrorCode ( string $code)
protected  void
setErrorMessage ( string $message)
protected  string
translateErrorMessage ( string $key)
Translates an error code into an error message.

Constructor Details

__construct

public __construct Array

Constructor.


Method Details

getErrorCode

public string getErrorCode ()

Output
string error code
Exception

getErrorMessage

public string getErrorMessage ()

Output
string error message
Exception

getErrorMessageFile

protected string getErrorMessageFile ()

Output
string path to the error message file
Exception

setErrorCode

public void setErrorCode (string $code )

Input
string$codeerror code
Output
Exception

setErrorMessage

protected void setErrorMessage (string $message )

Input
string$messageerror message
Output
Exception

translateErrorMessage

protected string translateErrorMessage (string $key )

Translates an error code into an error message.

Input
string$keyerror code that is passed in the exception constructor.
Output
string the translated error message
Exception