Grid Community Toolkit  6.2.1541705016
globus_error_generic.h
Go to the documentation of this file.
1 /*
2  * Copyright 1999-2006 University of Chicago
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at
7  *
8  * http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16 
22 #ifndef GLOBUS_ERROR_GENERIC_H
23 #define GLOBUS_ERROR_GENERIC_H
24 
25 #include "globus_object.h"
26 #include "globus_module.h"
27 
28 #include <stdarg.h>
29 
76 #ifdef __cplusplus
77 extern "C" {
78 #endif
79 
95 #define GLOBUS_ERROR_TYPE_GLOBUS (&GLOBUS_ERROR_TYPE_GLOBUS_DEFINITION)
96 extern const globus_object_type_t GLOBUS_ERROR_TYPE_GLOBUS_DEFINITION;
97 
98 #ifndef DOXYGEN
99 
100 globus_object_t *
102  globus_module_descriptor_t * base_source,
103  globus_object_t * base_cause,
104  int type,
105  const char * source_file,
106  const char * source_func,
107  int source_line,
108  const char * short_desc_format,
109  ...);
110 
111 globus_object_t *
113  globus_module_descriptor_t * base_source,
114  globus_object_t * base_cause,
115  int type,
116  const char * source_file,
117  const char * source_func,
118  int source_line,
119  const char * short_desc_format,
120  va_list ap);
121 
122 globus_object_t *
124  globus_object_t * error,
125  globus_module_descriptor_t * base_source,
126  globus_object_t * base_cause,
127  int type,
128  const char * source_file,
129  const char * source_func,
130  int source_line,
131  const char * short_desc_format,
132  va_list ap);
133 
134 #endif
135 
148  globus_object_t * error);
149 
150 void
152  globus_object_t * error,
153  globus_module_descriptor_t * source_module);
154 
155 globus_object_t *
157  globus_object_t * error);
158 
159 void
161  globus_object_t * error,
162  globus_object_t * causal_error);
163 
164 int
166  globus_object_t * error);
167 
168 void
170  globus_object_t * error,
171  const int type);
172 
173 char *
175  globus_object_t * error);
176 
177 void
179  globus_object_t * error,
180  const char * short_desc_format,
181  ...);
182 
183 char *
185  globus_object_t * error);
186 
187 void
189  globus_object_t * error,
190  const char * long_desc_format,
191  ...);
192 
205  globus_object_t * error,
207  int type);
208 
209 char *
211  globus_object_t * error);
212 
213 char *
215  globus_object_t * error);
216 
244 typedef char * (*globus_error_print_friendly_t)(
245  globus_object_t * error,
246  const globus_object_type_t * type);
247 
248 
249 #define GLOBUS_ERROR_TYPE_MULTIPLE (&GLOBUS_ERROR_TYPE_MULTIPLE_DEFINITION)
250 extern const globus_object_type_t GLOBUS_ERROR_TYPE_MULTIPLE_DEFINITION;
251 
252 globus_object_t *
254  globus_module_descriptor_t * base_source,
255  int type,
256  const char * fmt,
257  ...);
258 
259 void
261  globus_object_t * multiple_error,
262  globus_object_t * chain,
263  const char * fmt,
264  ...);
265 
266 globus_object_t *
268  globus_object_t * multiple_error);
269 
270 #ifdef __cplusplus
271 }
272 #endif
273 
274 #endif /* GLOBUS_ERROR_GENERIC_H */
void globus_error_mutliple_add_chain(globus_object_t *multiple_error, globus_object_t *chain, const char *fmt,...)
Definition: globus_error_generic.c:1157
int globus_error_get_type(globus_object_t *error)
Definition: globus_error_generic.c:393
globus_object_t * globus_error_get_cause(globus_object_t *error)
Definition: globus_error_generic.c:346
globus_object_t * globus_error_construct_multiple(globus_module_descriptor_t *base_source, int type, const char *fmt,...)
Definition: globus_error_generic.c:1077
globus_object_t * globus_error_multiple_remove_chain(globus_object_t *multiple_error)
Definition: globus_error_generic.c:1213
int globus_bool_t
Boolean type.
Definition: globus_types.h:93
Reference Counting Module Activation and Deactivation.
globus_object_t * globus_error_construct_error(globus_module_descriptor_t *base_source, globus_object_t *base_cause, int type, const char *source_file, const char *source_func, int source_line, const char *short_desc_format,...)
Definition: globus_error_generic.c:85
void globus_error_set_long_desc(globus_object_t *error, const char *long_desc_format,...)
Definition: globus_error_generic.c:592
globus_bool_t globus_error_match(globus_object_t *error, globus_module_descriptor_t *module, int type)
Definition: globus_error_generic.c:667
void globus_error_set_short_desc(globus_object_t *error, const char *short_desc_format,...)
Definition: globus_error_generic.c:496
void globus_error_set_cause(globus_object_t *error, globus_object_t *causal_error)
Definition: globus_error_generic.c:370
char * globus_error_print_friendly(globus_object_t *error)
Definition: globus_error_generic.c:920
char * globus_error_get_short_desc(globus_object_t *error)
Definition: globus_error_generic.c:461
void globus_error_set_type(globus_object_t *error, const int type)
Definition: globus_error_generic.c:431
char * globus_error_print_chain(globus_object_t *error)
Definition: globus_error_generic.c:735
char * globus_error_get_long_desc(globus_object_t *error)
Definition: globus_error_generic.c:562
globus_module_descriptor_t * globus_error_get_source(globus_object_t *error)
Definition: globus_error_generic.c:300
globus_object_t * globus_error_initialize_error(globus_object_t *error, globus_module_descriptor_t *base_source, globus_object_t *base_cause, int type, const char *source_file, const char *source_func, int source_line, const char *short_desc_format, va_list ap)
Definition: globus_error_generic.c:225
globus_object_t * globus_error_v_construct_error(globus_module_descriptor_t *base_source, globus_object_t *base_cause, const int type, const char *source_file, const char *source_func, int source_line, const char *short_desc_format, va_list ap)
Definition: globus_error_generic.c:154
void globus_error_set_source(globus_object_t *error, globus_module_descriptor_t *source_module)
Definition: globus_error_generic.c:323
Module Descriptor.
Definition: globus_module.h:69