XTA: API Reference for C++ language

xta::Exception Class Reference

#include <Exception.hpp>

Inheritance diagram for xta::Exception:
Collaboration diagram for xta::Exception:

Public Member Functions

 Exception (int ret_cod, const string &function)
 
int getReturnCode ()
 
string getReturnCodeText ()
 
const string & where ()
 
 ~Exception () throw ()
 

Private Attributes

string Function
 
int ReturnCode
 

Detailed Description

XTA exception class, it extends standard exception class and adds the return code property that maps on C API. It inherits from stdexcept::runtime_error, so you can simply catch "exception" or "runtime_error", but add LIXA specific info: the reason code returned by the failed C XTA function and the name of the C XTA function that failed

Definition at line 47 of file Exception.hpp.

Constructor & Destructor Documentation

xta::Exception::Exception ( int  ret_cod,
const string &  function 
)
inline

Default constructor

Parameters
[in]ret_codreturned by the failed C XTA function
[in]functionname where the expection has been raised

Definition at line 64 of file Exception.hpp.

xta::Exception::~Exception ( )
throw (
)
inline

Definition at line 69 of file Exception.hpp.

Member Function Documentation

int xta::Exception::getReturnCode ( )
inline

Retrieve the numeric return code of the failed C function

Returns
a LIXA/XTA return code

Definition at line 75 of file Exception.hpp.

string xta::Exception::getReturnCodeText ( )
inline

Retrieve the description associated to the numeric return code of the failed C function

Returns
the human readable description associated to the return code of the failed XTA function

Definition at line 82 of file Exception.hpp.

const string& xta::Exception::where ( )
inline

Definition at line 70 of file Exception.hpp.

Member Data Documentation

string xta::Exception::Function
private

Name of the function where exception happened

Definition at line 56 of file Exception.hpp.

int xta::Exception::ReturnCode
private

LIXA return code returned by the failed C function

Definition at line 52 of file Exception.hpp.


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

Copyright © 2009-2019, Christian Ferrari tiian@users.sourceforge.net http://www.tiian.org/