zorba::SystemException Class Reference

SystemException represents an error that occurs in the Zorba system. More...

#include <zorba/exception.h>

Inheritance diagram for zorba::SystemException:

zorba::ZorbaException

List of all members.

Public Member Functions

virtual String getDescription () const
 Get the descriptionof the error that is reported by this exception.
virtual XQUERY_ERROR getErrorCode () const
 Get the ErrorCode of the error that is reported by this exception.
virtual unsigned int getFileLineNumber () const
 Get the line number in the source file in which the error occured.
virtual String getFileName () const
 Get the name of the source file in which the error occured.
virtual ~SystemException () throw ()
 Destructor.

Static Public Member Functions

static std::string getErrorCodeAsString (const XQUERY_ERROR &aErrorCode)
 Static function to convert an XQUERY_ERROR to a String.

Protected Member Functions

 SystemException (const XQUERY_ERROR &, const String &aDescription, const String &afilename, unsigned int afilelinenumber)
 Proctected constructor - only the Zorba engine can construct and throw exceptions.

Protected Attributes

String theDescription
XQUERY_ERROR theErrorCode
unsigned int theFileLineNumber
String theFileName

Friends

class Item
ZORBA_EXTERN_DECL std::ostream & operator<< (std::ostream &, const ZorbaException &)
 Print information about the exception to the given output stream.
class ZorbaImpl


Detailed Description

SystemException represents an error that occurs in the Zorba system.
Examples:

simple.cpp.

Definition at line 261 of file exception.h.


Constructor & Destructor Documentation

virtual zorba::SystemException::~SystemException (  )  throw () [virtual]

Destructor.

zorba::SystemException::SystemException ( const XQUERY_ERROR ,
const String aDescription,
const String afilename,
unsigned int  afilelinenumber 
) [protected]

Proctected constructor - only the Zorba engine can construct and throw exceptions.


Member Function Documentation

virtual String zorba::ZorbaException::getDescription (  )  const [virtual, inherited]

Get the descriptionof the error that is reported by this exception.

virtual XQUERY_ERROR zorba::ZorbaException::getErrorCode (  )  const [virtual, inherited]

Get the ErrorCode of the error that is reported by this exception.

static std::string zorba::ZorbaException::getErrorCodeAsString ( const XQUERY_ERROR aErrorCode  )  [static, inherited]

Static function to convert an XQUERY_ERROR to a String.

Parameters:
aErrorCode the XQUERY_ERROR to convert to a String.
Returns:
String the String representation of the XQUERY_ERROR.

virtual unsigned int zorba::ZorbaException::getFileLineNumber (  )  const [virtual, inherited]

Get the line number in the source file in which the error occured.

Note that this information is mainly for debugging purposes.

Returns:
unsigned int the line number in the source file.

virtual String zorba::ZorbaException::getFileName (  )  const [virtual, inherited]

Get the name of the source file in which the error occured.

Note that this information is mainly for debugging purposes.

Returns:
String the name of the file where the error occured.


Friends And Related Function Documentation

friend class Item [friend]

Definition at line 265 of file exception.h.

ZORBA_EXTERN_DECL std::ostream& operator<< ( std::ostream &  ,
const ZorbaException  
) [friend]

Print information about the exception to the given output stream.

friend class ZorbaImpl [friend]

Reimplemented from zorba::ZorbaException.

Definition at line 264 of file exception.h.


Member Data Documentation

String zorba::ZorbaException::theDescription [protected, inherited]

Definition at line 81 of file exception.h.

XQUERY_ERROR zorba::ZorbaException::theErrorCode [protected, inherited]

Definition at line 80 of file exception.h.

unsigned int zorba::ZorbaException::theFileLineNumber [protected, inherited]

Definition at line 83 of file exception.h.

String zorba::ZorbaException::theFileName [protected, inherited]

Definition at line 82 of file exception.h.


The documentation for this class was generated from the following file: