irods
4.2.8
About: iRODS (the integrated Rule Oriented Data System) is a distributed data-management system for creating data grids, digital libraries, persistent archives, and real-time data systems. Fossies Dox: irods-4.2.8.tar.gz ("unofficial" and yet experimental doxygen-generated source code documentation) 
|
Go to the documentation of this file. 1 #ifndef __IRODS_ERROR_HPP__
2 #define __IRODS_ERROR_HPP__
10 #include <boost/optional.hpp>
17 #include <boost/assert.hpp>
18 #include <boost/format.hpp>
70 long long code()
const;
71 std::string
result()
const;
78 void code(
long long _code ) {
110 error assert_error(
bool expr_,
long long code_,
const std::string& file_,
const std::string& function_,
const std::string& format_,
int line_, ... );
111 error assert_pass(
const error& _error,
const std::string& _file,
const std::string& _function,
const std::string& _format,
int line_, ... );
117 #define ERROR( code_, message_ ) ( irods::error( false, code_, message_, __FILE__, __LINE__, __PRETTY_FUNCTION__ ) )
118 #define PASS( prev_error_ ) (irods::error( "", __FILE__, __LINE__, __PRETTY_FUNCTION__, prev_error_ ) )
119 #define PASSMSG( message_, prev_error_ ) (irods::error( message_, __FILE__, __LINE__, __PRETTY_FUNCTION__, prev_error_ ) )
120 #define CODE( code_ ) ( irods::error( true, code_, "", __FILE__, __LINE__, __PRETTY_FUNCTION__ ) )
121 #define SUCCESS( ) ( irods::error( true, 0, "", __FILE__, __LINE__, __PRETTY_FUNCTION__ ) )
123 #define ASSERT_ERROR(expr_, code_, format_, ...) (irods::assert_error(expr_, code_, __FILE__, __PRETTY_FUNCTION__, format_, __LINE__, ##__VA_ARGS__))
124 #define ASSERT_PASS(prev_error_, format_, ...) (irods::assert_pass(prev_error_, __FILE__, __PRETTY_FUNCTION__, format_, __LINE__, ##__VA_ARGS__))
126 #endif // __IRODS_ERROR_HPP__
std::string user_result() const
error assert_pass(const error &_error, const std::string &_file, const std::string &_function, const std::string &_format, int line_,...)
void message(std::string _message)
static const char * colon_token_
boost::optional< exception > exception_
static const char * status_token_
void code(long long _code)
error assert_error(bool expr_, long long code_, const std::string &file_, const std::string &function_, const std::string &format_, int line_,...)
std::string build_result_string(std::string, int, std::string)
void status(bool _status)
static const char * iRODS_token_
std::string result() const
std::vector< std::string > result_stack_
error & operator=(const error &)