An XQueryException is-a ZorbaException for errors with the user's XQuery. More...
#include <zorba/xquery_exception.h>
Public Types | |
typedef internal::diagnostic::location::column_type | column_type |
typedef internal::diagnostic::location::line_type | line_type |
Public Member Functions | |
column_type | applied_column () const throw () |
Gets the XQuery source-code "applied at" column number containing the error. More... | |
column_type | applied_column_end () const throw () |
Gets the XQuery source-code "applied at" end column number containing the error. More... | |
line_type | applied_line () const throw () |
Gets the XQuery source-code "applied at" line number containing the error. More... | |
line_type | applied_line_end () const throw () |
Gets the XQuery source-code "applied at" end line number containing the error. More... | |
char const * | applied_uri () const throw () |
Gets the XQuery source-code "applied at" URI containing the error. More... | |
Diagnostic const & | diagnostic () const throw () |
Gets the diagnostic carried by this exception. More... | |
bool | has_applied () const throw () |
Checks whether the XQuery "applied at" location has been set. More... | |
bool | has_source () const throw () |
Checks whether the XQuery source-code location has been set. More... | |
XQueryException & | operator= (XQueryException const &from) |
Assigns this XQueryException from another. More... | |
void | polymorphic_throw () const |
Throws itself polymorphically; see http://www.parashift.com/c++-faq-lite/exceptions.html#faq-17.16. More... | |
XQueryStackTrace & | query_trace () throw () |
Gets the XQuery stack trace, if any. More... | |
XQueryStackTrace const & | query_trace () const throw () |
Gets the XQuery stack trace, if any. More... | |
char const * | raise_file () const throw () |
Gets the C++ source-code file name whence this exception was raised. More... | |
line_type | raise_line () const throw () |
Gets the C++ source-code line number whence this exception was raised. More... | |
void | set_applied (char const *uri, line_type line, column_type column=0, line_type line_end=0, column_type column_end=0) |
Sets the XQuery source-code "applied at" URI name, line, and column numbers. More... | |
void | set_diagnostic (Diagnostic const &diagnostic) throw () |
Sets the diagnostic. More... | |
void | set_source (char const *uri, line_type line, column_type column=0, line_type line_end=0, column_type column_end=0) |
Sets the XQuery source-code URI name, line, and column numbers. More... | |
column_type | source_column () const throw () |
Gets the XQuery source-code column number containing the error. More... | |
column_type | source_column_end () const throw () |
Gets the XQuery source-code end column number containing the error. More... | |
line_type | source_line () const throw () |
Gets the XQuery source-code line number containing the error. More... | |
line_type | source_line_end () const throw () |
Gets the XQuery source-code end line number containing the error. More... | |
char const * | source_uri () const throw () |
Gets the XQuery source-code URI containing the error. More... | |
char const * | what () const throw () |
XQueryException (XQueryException const &from) | |
Copy-constructs an XQueryException. More... | |
~XQueryException () throw () | |
Destroys this XQueryException. More... | |
Protected Member Functions | |
std::unique_ptr< ZorbaException > | clone () const |
Clones this exception object. More... | |
std::ostream & | print (std::ostream &o) const |
Prints the exception to the given ostream. More... | |
XQueryException (serialization::Archiver &ar) | |
Friends | |
XQueryException | make_xquery_exception (char const *, ZorbaException::line_type, Diagnostic const &, parameters const &, location const &) |
XQueryException * | new_xquery_exception (char const *, ZorbaException::line_type, Diagnostic const &, parameters const &, location const &) |
void | serialization::operator& (serialization::Archiver &, ZorbaException *&) |
void | set_applied (ZorbaException &, char const *, line_type, column_type, line_type, column_type, bool) |
void | set_source (ZorbaException &, char const *, line_type, column_type, line_type, column_type, bool) |
class | UserException |
An XQueryException is-a ZorbaException for errors with the user's XQuery.
An XQueryException therefore also contains the XQuery source URI, line, and column numbers.
Definition at line 37 of file xquery_exception.h.
Definition at line 39 of file xquery_exception.h.
|
inherited |
Definition at line 44 of file zorba_exception.h.
zorba::XQueryException::XQueryException | ( | XQueryException const & | from | ) |
Copy-constructs an XQueryException.
from | The XQueryException to copy from. |
zorba::XQueryException::~XQueryException | ( | ) | throw () |
Destroys this XQueryException.
|
protected |
|
inline |
Gets the XQuery source-code "applied at" column number containing the error.
Definition at line 184 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code "applied at" end column number containing the error.
Definition at line 204 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code "applied at" line number containing the error.
Definition at line 174 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code "applied at" end line number containing the error.
Definition at line 194 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code "applied at" URI containing the error.
Definition at line 165 of file xquery_exception.h.
|
protectedvirtual |
Clones this exception object.
Reimplemented from zorba::ZorbaException.
|
inlineinherited |
Gets the diagnostic carried by this exception.
Definition at line 71 of file zorba_exception.h.
|
inline |
Checks whether the XQuery "applied at" location has been set.
true
only if the "applied at" location has been set. Definition at line 139 of file xquery_exception.h.
|
inline |
Checks whether the XQuery source-code location has been set.
true
only if said has been set. Definition at line 68 of file xquery_exception.h.
XQueryException& zorba::XQueryException::operator= | ( | XQueryException const & | from | ) |
Assigns this XQueryException from another.
from | The XQueryException to assign from. |
*this
.
|
virtual |
Throws itself polymorphically; see http://www.parashift.com/c++-faq-lite/exceptions.html#faq-17.16.
Reimplemented from zorba::ZorbaException.
|
protectedvirtual |
Prints the exception to the given ostream.
o | The ostream to print to. |
Reimplemented from zorba::ZorbaException.
|
inline |
Gets the XQuery stack trace, if any.
Definition at line 215 of file xquery_exception.h.
|
inline |
Gets the XQuery stack trace, if any.
Definition at line 224 of file xquery_exception.h.
|
inlineinherited |
Gets the C++ source-code file name whence this exception was raised.
Definition at line 95 of file zorba_exception.h.
|
inlineinherited |
Gets the C++ source-code line number whence this exception was raised.
Definition at line 104 of file zorba_exception.h.
void zorba::XQueryException::set_applied | ( | char const * | uri, |
line_type | line, | ||
column_type | column = 0 , |
||
line_type | line_end = 0 , |
||
column_type | column_end = 0 |
||
) |
Sets the XQuery source-code "applied at" URI name, line, and column numbers.
uri | The source-code "applied at" URI name. If either the null pointer or the empty string, source_uri() is used. |
line | The source-code "applied at" URI line number. |
column | The source-code "applied at" URI column number. |
line_end | The source-code "applied at" URI end line number. |
column_end | The source-code "applied at" URI end column number. |
|
inlineinherited |
Sets the diagnostic.
diagnostic | The diagnostic. |
Definition at line 86 of file zorba_exception.h.
void zorba::XQueryException::set_source | ( | char const * | uri, |
line_type | line, | ||
column_type | column = 0 , |
||
line_type | line_end = 0 , |
||
column_type | column_end = 0 |
||
) |
Sets the XQuery source-code URI name, line, and column numbers.
uri | The source-code URI name. |
line | The source-code URI line number. |
column | The source-code URI column number. |
line_end | The source-code URI end line number. |
column_end | The source-code URI end column number. |
|
inline |
Gets the XQuery source-code column number containing the error.
Definition at line 110 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code end column number containing the error.
Definition at line 128 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code line number containing the error.
Definition at line 101 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code end line number containing the error.
Definition at line 119 of file xquery_exception.h.
|
inline |
Gets the XQuery source-code URI containing the error.
Definition at line 92 of file xquery_exception.h.
|
inherited |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
|
friend |
Definition at line 273 of file xquery_exception.h.