104 virtual void operator() (
int warn_code,
const char* file_name,
105 int line_num,
const char *fmt, ...) = 0;
119 virtual void operator() (
int info_code,
const char* file_name,
120 int line_num,
const char* fmt, ...);
168 virtual void operator() (
int warn_code,
const char* file_name,
169 int line_num,
const char* fmt, ...);
217 virtual void operator() (
int warn_code,
const char* file_name,
218 int line_num,
const char *fmt, ...);
271#if (defined OJPH_OS_WINDOWS)
272 #define __OJPHFILE__ \
273 (strrchr(__FILE__, '\\') ? strrchr(__FILE__, '\\') + 1 : __FILE__)
275 #define __OJPHFILE__ \
276 (strrchr(__FILE__, '/') ? strrchr(__FILE__, '/') + 1 : __FILE__)
283#define OJPH_INFO(t, ...) \
284 { ojph::get_info()[0](t, __OJPHFILE__, __LINE__, __VA_ARGS__); }
285#define OJPH_WARN(t, ...) \
286 { ojph::get_warning()[0](t, __OJPHFILE__, __LINE__, __VA_ARGS__); }
287#define OJPH_ERROR(t, ...) \
288 { ojph::get_error()[0](t, __OJPHFILE__, __LINE__,__VA_ARGS__); }
This is the base class from which all messaging levels are derived.
Derived from message_base to handle error messages.
Derived from message_base to handle info messages.
Derived from message_base to handle warning messages.
OJPH_EXPORT message_info * get_info()
Get the info message object, whose operator() member class is called for info messages – See the macr...
OJPH_EXPORT message_warning * get_warning()
Get the warning message object, whose operator() member class is called for warning messages – See th...
OJPH_EXPORT void set_error_stream(FILE *s)
Replaces the error output file from the default stderr to user defined output file.
OJPH_EXPORT void configure_error(message_error *error)
This overrides the default behaviour of handling error messages.
OJPH_EXPORT message_error * get_error()
Get the error message object, whose operator() member class is called for error messages – See the ma...
OJPH_MSG_LEVEL
This enum is use to specify the level of severity of message while processing markers.
OJPH_EXPORT void set_warning_stream(FILE *s)
Replaces the warning output file from the default stdout to user defined output file.
OJPH_EXPORT void set_info_stream(FILE *s)
Replaces the info output file from the default stdout to user defined output file.
OJPH_EXPORT void configure_warning(message_warning *warn)
This overrides the default behaviour of handling warning messages.
OJPH_EXPORT void configure_info(message_info *info)
This overrides the default behaviour of handling info messages.
OJPH_EXPORT void set_message_level(OJPH_MSG_LEVEL level)
Sets the minimum severity of the message to be reported.