|
X-shooter Pipeline Reference Manual 3.8.15
|
Macros | |
| #define | MAXSTRINGLENGTH 1024 /* Used to pass a va_list to cpl_msg_warning */ |
| #define | xsh_msg_dbg_high(...) |
| #define | xsh_msg_dbg_medium(...) |
| #define | xsh_msg_dbg_low(...) |
| #define | xsh_msg_error(...) cpl_msg_error(__func__, __VA_ARGS__) |
| Print an error message. | |
| #define | xsh_msg_progress(i, iter, ...) |
| Print a progress message. | |
| #define | xsh_msg_warning(...) xsh_msg_warning_macro(__func__, __VA_ARGS__) |
| Print an warning message. | |
| #define | xsh_msg_debug(...) cpl_msg_debug(__func__, __VA_ARGS__) |
| Print a debug message. | |
| #define | xsh_msg_indented(...) |
| Print an indented message. | |
| #define | xsh_msg(...) cpl_msg_info("", __VA_ARGS__) |
| Print a message on info level. | |
Functions | |
| void | xsh_msg_init (void) |
| Initialize messaging. | |
| int | xsh_msg_get_warnings (void) |
| Get number of warnings printed so far. | |
| void | xsh_msg_warning_macro (const char *fct, const char *format,...) |
| Print a warning message. | |
Variables | |
| static int | number_of_warnings = 0 |
This module exists in order to save the user from typing the function name when calling a CPL message function (by using the ANSI-C99 __func__ identifier).
Also, a record is kept on the number of warnings printed using xsh_msg_warning().
These messaging functions never set the CPL error code.
| #define MAXSTRINGLENGTH 1024 /* Used to pass a va_list to cpl_msg_warning */ |
| #define xsh_msg | ( | ... | ) | cpl_msg_info("", __VA_ARGS__) |
| #define xsh_msg_dbg_high | ( | ... | ) |
| #define xsh_msg_dbg_low | ( | ... | ) |
| #define xsh_msg_dbg_medium | ( | ... | ) |
| #define xsh_msg_debug | ( | ... | ) | cpl_msg_debug(__func__, __VA_ARGS__) |
| #define xsh_msg_error | ( | ... | ) | cpl_msg_error(__func__, __VA_ARGS__) |
| #define xsh_msg_indented | ( | ... | ) |
| #define xsh_msg_progress | ( | i, | |
| iter, | |||
| ... | |||
| ) |
Print a progress message.
| i | See cpl_msg_progress() |
| iter | See cpl_msg_progress() |
| ... | Message to print |
This function is used instead of cpl_msg_progress(), and saves the user from typing the calling function name.
| #define xsh_msg_warning | ( | ... | ) | xsh_msg_warning_macro(__func__, __VA_ARGS__) |
| int xsh_msg_get_warnings | ( | void | ) |
Get number of warnings printed so far.
Definition at line 116 of file xsh_msg.c.
References number_of_warnings.
Referenced by xsh_end().
| void xsh_msg_init | ( | void | ) |
Initialize messaging.
This function
Definition at line 80 of file xsh_msg.c.
References number_of_warnings.
Referenced by xsh_init().
| void xsh_msg_warning_macro | ( | const char * | fct, |
| const char * | format, | ||
| ... | |||
| ) |
Print a warning message.
| fct | Identity of calling function |
| format | A printf()-like format string |
Don't call this function directly, use the macro xsh_msg_warning().
This function is used instead of cpl_msg_warning(), and saves the user from typing the calling function name.
Additionally, record is kept on the total number of warnings printed (see xsh_msg_get_warnings()).
Definition at line 137 of file xsh_msg.c.
References MAXSTRINGLENGTH, and number_of_warnings.
|
static |
Definition at line 66 of file xsh_msg.c.
Referenced by xsh_msg_get_warnings(), xsh_msg_init(), and xsh_msg_warning_macro().