API - SmartSlog KP Library
Main Page
Data Structures
Files
File List
Globals
utils
kp_error.h
Go to the documentation of this file.
1
36
#include "kp_bool.h"
37
38
#ifndef _KP_ERROR_H
39
#define _KP_ERROR_H
40
41
#if defined(WIN32) || defined(WINCE) || defined(SMARTSLOG_WIN_EXPORTS)
42
#define SSLOG_EXTERN __declspec(dllexport)
43
#else
44
#define SSLOG_EXTERN
45
#endif
46
48
50
#define ERROR_UNKNOWN_TEXT "Unknown error."
51
52
53
54
#ifdef __cplusplus
55
extern
"C"
{
56
#endif
57
58
/******************************************************************************/
59
/******************************** Enums list **********************************/
61
64
enum
kp_errors {
65
66
#define KP_ERROR_DECLARATION( enum_code_decl, code_value, error_text) enum_code_decl code_value,
67
#define KP_ERROR_DECLARATION_LAST( enum_code_decl, code_value, error_text) enum_code_decl code_value
68
#include "kp_errors_define_decl.txt"
69
#undef KP_ERROR_DECLARATION
70
#undef KP_ERROR_DECLARATION_LAST
71
72
};
74
75
76
/******************************************************************************/
77
/****************************** Functions list ********************************/
79
80
int
set_error(
int
error_code);
81
83
84
86
87
SSLOG_EXTERN
int
get_error_code
();
88
SSLOG_EXTERN
int
get_error_code_and_reset
();
89
90
SSLOG_EXTERN
const
char
*
get_error_text
();
91
SSLOG_EXTERN
char
*
get_error_text_and_reset
();
92
SSLOG_EXTERN
const
char
*
get_error_text_by_code
(
int
error_code);
93
94
SSLOG_EXTERN
int
reset_error
();
95
97
98
#ifdef __cplusplus
99
}
100
#endif
101
102
#endif
/* _KP_ERROR_H */
Generated on Mon Dec 17 2012 16:22:27 for API - SmartSlog KP Library by
1.8.1.1