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
17
18 /*
19 * This file is automatically generated from source-type-simple-doclit.tmpl
20 */
21
22 #include "xsd_QName.h"
23 #include "globus_soap_message.h"
24 #include "globus_xsd_type_info.h"
25 #include "wsc_FaultCodes.h"
26 #include "globus_xsd_generic_array.h"
27
28 xsd_QName wsc_FaultCodes_qname =
29 {
30 "http://schemas.xmlsoap.org/ws/2004/04/sc",
31 "FaultCodes"
32 };
33
34
35 xsd_QName wsc_FaultCodes_wsc_BadContextToken =
36 {
37 "http://schemas.xmlsoap.org/ws/2004/04/sc",
38 "BadContextToken"
39 };
40
41 xsd_QName wsc_FaultCodes_wsc_UnsupportedContextToken =
42 {
43 "http://schemas.xmlsoap.org/ws/2004/04/sc",
44 "UnsupportedContextToken"
45 };
46
47 xsd_QName wsc_FaultCodes_wsc_UnknownDerivationSource =
48 {
49 "http://schemas.xmlsoap.org/ws/2004/04/sc",
50 "UnknownDerivationSource"
51 };
52
53 static
54 globus_bool_t
55 wsc_FaultCodes_l_is_valid_restriction(
56 const wsc_FaultCodes * instance);
57
58
59 static
60 globus_result_t
61 wsc_FaultCodes_serialize_wrapper(
62 const xsd_QName * element_qname,
63 const void * instance,
64 globus_soap_message_handle_t message_handle,
65 globus_xsd_element_options_t options)
66 0 {
67 0 return wsc_FaultCodes_serialize(
68 element_qname,
69 (wsc_FaultCodes *) instance,
70 message_handle, options);
71 }
72
73 static
74 globus_result_t
75 wsc_FaultCodes_deserialize_pointer_wrapper(
76 const xsd_QName * element_qname,
77 void ** ip,
78 globus_soap_message_handle_t message_handle,
79 globus_xsd_element_options_t options)
80 0 {
81 0 return wsc_FaultCodes_deserialize_pointer(
82 element_qname,
83 (wsc_FaultCodes **) ip,
84 message_handle, options);
85 }
86
87 globus_result_t
88 wsc_FaultCodes_init_wrapper(void **object)
89 0 {
90 0 return wsc_FaultCodes_init(
91 (wsc_FaultCodes **) object);
92 }
93
94 static
95 void
96 wsc_FaultCodes_destroy_wrapper(
97 void * object)
98 0 {
99 0 wsc_FaultCodes_destroy(
100 (wsc_FaultCodes *) object);
101 0 }
102
103 static
104 globus_result_t
105 wsc_FaultCodes_copy_wrapper(
106 void ** dest_obj,
107 const void * src_obj)
108 0 {
109 0 return wsc_FaultCodes_copy(
110 (wsc_FaultCodes **) dest_obj,
111 (const wsc_FaultCodes *) src_obj);
112 }
113
114 static
115 globus_result_t
116 wsc_FaultCodes_init_contents_wrapper(void *object)
117 0 {
118 0 return wsc_FaultCodes_init_contents(
119 (wsc_FaultCodes *) object);
120 }
121
122 static
123 void
124 wsc_FaultCodes_destroy_contents_wrapper(
125 void * object)
126 0 {
127 0 wsc_FaultCodes_destroy_contents(
128 (wsc_FaultCodes *) object);
129 0 }
130
131 static
132 globus_result_t
133 wsc_FaultCodes_copy_contents_wrapper(
134 void * dest_obj,
135 const void * src_obj)
136 0 {
137 0 return wsc_FaultCodes_copy_contents(
138 (wsc_FaultCodes *) dest_obj,
139 (const wsc_FaultCodes *) src_obj);
140 }
141
142 static
143 globus_result_t
144 wsc_FaultCodes_serialize_contents_wrapper(
145 const xsd_QName * element_qname,
146 const void * instance,
147 globus_soap_message_handle_t message_handle,
148 globus_xsd_element_options_t options)
149 0 {
150 0 return wsc_FaultCodes_serialize_contents(
151 element_qname,
152 (wsc_FaultCodes *) instance,
153 message_handle, options);
154 }
155
156 static
157 globus_result_t
158 wsc_FaultCodes_deserialize_contents_wrapper(
159 const xsd_QName * element_qname,
160 void ** instance,
161 globus_soap_message_handle_t message_handle,
162 globus_xsd_element_options_t options)
163 0 {
164 globus_result_t result;
165 GlobusFuncName(wsc_FaultCodes_deserialize_contents_wrapper);
166 0 GlobusSoapMessageDebugEnter();
167
168 0 if(!*instance)
169 {
170 0 result = wsc_FaultCodes_init(
171 (wsc_FaultCodes **)instance);
172 0 if(result != GLOBUS_SUCCESS)
173 {
174 0 goto error;
175 }
176 }
177
178 0 result = wsc_FaultCodes_deserialize_contents(
179 element_qname,
180 *(wsc_FaultCodes **)instance,
181 message_handle, options);
182 0 error:
183 0 GlobusSoapMessageDebugExit();
184 0 return result;
185 }
186
187 static
188 globus_result_t
189 wsc_FaultCodes_array_serialize_wrapper(
190 const xsd_QName * element,
191 const void * instance,
192 globus_soap_message_handle_t message,
193 globus_xsd_element_options_t options)
194 0 {
195 0 return wsc_FaultCodes_array_serialize(
196 element,
197 (wsc_FaultCodes_array *) instance,
198 message, options);
199 }
200
201 static
202 globus_result_t
203 wsc_FaultCodes_array_deserialize_wrapper(
204 const xsd_QName * element_qname,
205 void ** inst,
206 globus_soap_message_handle_t message,
207 globus_xsd_element_options_t options)
208 0 {
209 0 if(!*inst)
210 {
211 globus_result_t result;
212
213 0 result = wsc_FaultCodes_array_init(
214 (wsc_FaultCodes_array **)inst);
215 0 if(result != GLOBUS_SUCCESS)
216 {
217 0 return result;
218 }
219 }
220
221 0 return wsc_FaultCodes_array_deserialize(
222 element_qname,
223 *(wsc_FaultCodes_array **) inst,
224 message, options);
225 }
226
227 static
228 globus_result_t
229 wsc_FaultCodes_array_init_wrapper(
230 void ** arr)
231 0 {
232 0 return wsc_FaultCodes_array_init(
233 (wsc_FaultCodes_array **) arr);
234 }
235
236 static
237 void
238 wsc_FaultCodes_array_destroy_wrapper(
239 void * arr)
240 0 {
241 0 wsc_FaultCodes_array_destroy(
242 (wsc_FaultCodes_array *) arr);
243 0 }
244
245 static
246 globus_result_t
247 wsc_FaultCodes_array_copy_wrapper(
248 void ** dest_arr,
249 const void * src_arr)
250 0 {
251 0 return wsc_FaultCodes_array_copy(
252 (wsc_FaultCodes_array **) dest_arr,
253 (const wsc_FaultCodes_array *) src_arr);
254 }
255
256 static
257 globus_result_t
258 wsc_FaultCodes_array_init_contents_wrapper(
259 void * arr)
260 0 {
261 0 return wsc_FaultCodes_array_init_contents(
262 (wsc_FaultCodes_array *) arr);
263 }
264
265 static
266 void
267 wsc_FaultCodes_array_destroy_contents_wrapper(
268 void * arr)
269 0 {
270 0 wsc_FaultCodes_array_destroy_contents(
271 (wsc_FaultCodes_array *) arr);
272 0 }
273
274 static
275 globus_result_t
276 wsc_FaultCodes_array_copy_contents_wrapper(
277 void * dest_arr,
278 const void * src_arr)
279 0 {
280 0 return wsc_FaultCodes_array_copy_contents(
281 (wsc_FaultCodes_array *) dest_arr,
282 (const wsc_FaultCodes_array *) src_arr);
283 }
284
285 static
286 void *
287 wsc_FaultCodes_array_push_wrapper(
288 void * array)
289 0 {
290 0 return (void *) wsc_FaultCodes_array_push((wsc_FaultCodes_array *) array);
291 }
292
293 struct globus_xsd_type_info_s wsc_FaultCodes_array_info =
294 {
295 &wsc_FaultCodes_qname,
296 wsc_FaultCodes_array_serialize_wrapper,
297 wsc_FaultCodes_array_deserialize_wrapper,
298 wsc_FaultCodes_array_init_wrapper,
299 wsc_FaultCodes_array_destroy_wrapper,
300 wsc_FaultCodes_array_copy_wrapper,
301 wsc_FaultCodes_array_init_contents_wrapper,
302 wsc_FaultCodes_array_destroy_contents_wrapper,
303 wsc_FaultCodes_array_copy_contents_wrapper,
304 sizeof(wsc_FaultCodes),
305 wsc_FaultCodes_array_push_wrapper,
306 NULL,
307 NULL
308 };
309
310 struct globus_xsd_type_info_s wsc_FaultCodes_contents_info =
311 {
312 &wsc_FaultCodes_qname,
313 wsc_FaultCodes_serialize_contents_wrapper,
314 wsc_FaultCodes_deserialize_contents_wrapper,
315 wsc_FaultCodes_init_wrapper,
316 wsc_FaultCodes_destroy_wrapper,
317 wsc_FaultCodes_copy_wrapper,
318 wsc_FaultCodes_init_contents_wrapper,
319 wsc_FaultCodes_destroy_contents_wrapper,
320 wsc_FaultCodes_copy_contents_wrapper,
321 sizeof(wsc_FaultCodes),
322 NULL,
323 NULL,
324 NULL
325 };
326
327 struct globus_xsd_type_info_s wsc_FaultCodes_info =
328 {
329 &wsc_FaultCodes_qname,
330 wsc_FaultCodes_serialize_wrapper,
331 wsc_FaultCodes_deserialize_pointer_wrapper,
332 wsc_FaultCodes_init_wrapper,
333 wsc_FaultCodes_destroy_wrapper,
334 wsc_FaultCodes_copy_wrapper,
335 wsc_FaultCodes_init_contents_wrapper,
336 wsc_FaultCodes_destroy_contents_wrapper,
337 wsc_FaultCodes_copy_contents_wrapper,
338 sizeof(wsc_FaultCodes),
339 NULL,
340 &wsc_FaultCodes_contents_info,
341 &wsc_FaultCodes_array_info
342 };
343
344 globus_result_t
345 wsc_FaultCodes_init_contents(
346 wsc_FaultCodes * instance)
347 0 {
348 0 globus_result_t result = GLOBUS_SUCCESS;
349 GlobusFuncName(wsc_FaultCodes_init_contents);
350 0 GlobusSoapMessageDebugEnter();
351
352
353 0 xsd_QName_init_contents(instance);
354
355 0 GlobusSoapMessageDebugExit();
356 0 return result;
357 }
358
359 globus_result_t
360 wsc_FaultCodes_init(
361 wsc_FaultCodes ** object)
362 0 {
363 wsc_FaultCodes * instance;
364 0 globus_result_t result = GLOBUS_SUCCESS;
365 GlobusFuncName(wsc_FaultCodes_init);
366 0 GlobusSoapMessageDebugEnter();
367
368
369 0 xsd_QName_init(object);
370
371 0 GlobusSoapMessageDebugExit();
372 0 return result;
373 }
374
375 void
376 wsc_FaultCodes_destroy(
377 wsc_FaultCodes * instance)
378 0 {
379 GlobusFuncName(wsc_FaultCodes_destroy);
380 0 GlobusSoapMessageDebugEnter();
381
382 0 if(!instance)
383 {
384 0 goto exit;
385 }
386
387 0 wsc_FaultCodes_destroy_contents(instance);
388 0 globus_free(instance);
389
390 0 exit:
391
392 0 GlobusSoapMessageDebugExit();
393 0 }
394
395 void
396 wsc_FaultCodes_destroy_contents(
397 wsc_FaultCodes * instance)
398 0 {
399 GlobusFuncName(wsc_FaultCodes_destroy_contents);
400 0 GlobusSoapMessageDebugEnter();
401
402 0 if(instance)
403 {
404
405
406 0 xsd_QName_destroy_contents(instance);
407
408 }
409
410 0 GlobusSoapMessageDebugExit();
411 0 }
412
413 globus_result_t
414 wsc_FaultCodes_copy(
415 wsc_FaultCodes ** dest_obj,
416 const wsc_FaultCodes * src_obj)
417 0 {
418 0 globus_result_t result = GLOBUS_SUCCESS;
419 wsc_FaultCodes * instance;
420 GlobusFuncName(wsc_FaultCodes_copy);
421
422 0 GlobusSoapMessageDebugEnter();
423
424 0 instance = malloc(sizeof(wsc_FaultCodes));
425 0 if (instance == NULL)
426 {
427 0 GlobusSoapMessageDebugExit();
428 0 return GlobusSoapMessageErrorOutOfMemory;
429 }
430
431 0 result = wsc_FaultCodes_copy_contents(instance, src_obj);
432 0 if(result != GLOBUS_SUCCESS)
433 {
434 0 globus_free(instance);
435 0 GlobusSoapMessageDebugExit();
436 0 return GlobusSoapMessageErrorOutOfMemory;
437 }
438
439 0 *dest_obj = instance;
440 0 GlobusSoapMessageDebugExit();
441 0 return result;
442 }
443
444 globus_result_t
445 wsc_FaultCodes_copy_contents(
446 wsc_FaultCodes * instance,
447 const wsc_FaultCodes * src_obj)
448 0 {
449 0 globus_result_t result = GLOBUS_SUCCESS;
450 GlobusFuncName(wsc_FaultCodes_copy_contents);
451
452 0 GlobusSoapMessageDebugEnter();
453
454
455 0 result = xsd_QName_copy_contents(
456 instance, src_obj);
457
458 goto exit;
459
460 0 fail_copy:
461
462
463 0 exit:
464
465 0 GlobusSoapMessageDebugExit();
466 0 return result;
467 }
468
469
470
471 globus_result_t
472 wsc_FaultCodes_serialize_contents(
473 const xsd_QName * element_qname, /* ignored */
474 const wsc_FaultCodes * inst,
475 globus_soap_message_handle_t message_handle,
476 globus_xsd_element_options_t options)
477 0 {
478 0 globus_result_t result = GLOBUS_SUCCESS;
479 GlobusFuncName(wsc_FaultCodes_serialize_contents);
480 0 GlobusSoapMessageDebugEnter();
481
482 0 result = wsc_FaultCodes_serialize(
483 NULL,
484 inst,
485 message_handle,
486 options | GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
487 0 if(result != GLOBUS_SUCCESS)
488 {
489 0 result = GlobusSoapMessageErrorSerializeFailed(
490 result, NULL, element_qname);
491 0 goto exit;
492 }
493
494 0 exit:
495
496 0 GlobusSoapMessageDebugExit();
497 0 return result;
498 }
499
500
501
502 globus_result_t
503 wsc_FaultCodes_serialize(
504 const xsd_QName * element_qname,
505 const wsc_FaultCodes * instance,
506 globus_soap_message_handle_t message_handle,
507 globus_xsd_element_options_t options)
508 0 {
509 0 globus_result_t result = GLOBUS_SUCCESS;
510 xsd_QName subelement;
511 0 globus_list_t * any_attr_keys = NULL;
512 0 globus_list_t * any_attr_keys_iterator = NULL;
513 0 xsd_QName * type_attr = NULL;
514 0 char * type_value = NULL;
515 0 char * prefix = NULL;
516 int prefix_created;
517 0 int define_prefix = 0;
518 int i;
519 0 char * type_attr_prefix = NULL;
520
521 GlobusFuncName(wsc_FaultCodes_serialize);
522 0 GlobusSoapMessageDebugEnter();
523
524
525 0 if (!wsc_FaultCodes_l_is_valid_restriction(instance))
526 {
527 0 result = GlobusSoapMessageErrorSerializeFailed(result,
528 NULL,
529 element_qname);
530
531 0 goto exit;
532
533 }
534
535 0 result = xsd_QName_serialize(
536 element_qname,
537 instance,
538 message_handle,
539 options);
540
541 0 exit:
542
543 0 if(any_attr_keys)
544 {
545 0 globus_list_free(any_attr_keys);
546 }
547
548 0 GlobusSoapMessageDebugExit();
549 0 return result;
550 }
551
552
553
554 globus_result_t
555 wsc_FaultCodes_deserialize_contents(
556 const xsd_QName * element_qname, /* ignored */
557 wsc_FaultCodes * inst,
558 globus_soap_message_handle_t message_handle,
559 globus_xsd_element_options_t options)
560 0 {
561 0 globus_result_t result = GLOBUS_SUCCESS;
562 GlobusFuncName(wsc_FaultCodes_deserialize_contents);
563 0 GlobusSoapMessageDebugEnter();
564
565 0 result = wsc_FaultCodes_deserialize(
566 NULL,
567 inst,
568 message_handle,
569 options | GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
570 0 if(result != GLOBUS_SUCCESS)
571 {
572 0 result = GlobusSoapMessageErrorDeserializeFailed(
573 result, element_qname);
574 0 goto exit;
575 }
576
577 0 exit:
578
579 0 GlobusSoapMessageDebugExit();
580 0 return result;
581 }
582
583
584
585 globus_result_t
586 wsc_FaultCodes_deserialize(
587 const xsd_QName * element_qname,
588 wsc_FaultCodes * instance,
589 globus_soap_message_handle_t message_handle,
590 globus_xsd_element_options_t options)
591 0 {
592 0 globus_result_t result = GLOBUS_SUCCESS;
593 xsd_QName subelement;
594 GlobusFuncName(wsc_FaultCodes_deserialize);
595 0 GlobusSoapMessageDebugEnter();
596
597
598 0 result = xsd_QName_deserialize(element_qname,
599 instance, message_handle, options);
600
601 0 if (result != GLOBUS_SUCCESS)
602 {
603 0 result = GlobusSoapMessageErrorDeserializeFailed(
604 result, element_qname);
605 0 goto exit;
606 }
607
608 0 if (!wsc_FaultCodes_l_is_valid_restriction(instance))
609 {
610 0 result = GlobusSoapMessageErrorDeserializeFailed(result,
611 element_qname);
612
613 }
614
615
616 0 exit:
617
618 0 GlobusSoapMessageDebugExit();
619 0 return result;
620 }
621
622
623
624 globus_result_t
625 wsc_FaultCodes_deserialize_pointer(
626 const xsd_QName * element_qname,
627 wsc_FaultCodes ** ip,
628 globus_soap_message_handle_t message_handle,
629 globus_xsd_element_options_t options)
630 0 {
631 0 wsc_FaultCodes * instance = NULL;
632 0 globus_result_t result = GLOBUS_SUCCESS;
633 xsd_QName subelement;
634 GlobusFuncName(wsc_FaultCodes_deserialize_pointer);
635 0 GlobusSoapMessageDebugEnter();
636
637 0 *ip = NULL;
638
639
640 0 result = xsd_QName_deserialize_pointer(
641 element_qname,
642 ip, message_handle, options);
643
644 0 if (result != GLOBUS_SUCCESS)
645 {
646 0 result = GlobusSoapMessageErrorDeserializeFailed(
647 result, element_qname);
648 0 goto exit;
649 }
650
651 0 if (*ip && !wsc_FaultCodes_l_is_valid_restriction(*ip))
652 {
653 0 result = GlobusSoapMessageErrorDeserializeFailed(result,
654 element_qname);
655
656 }
657
658
659 0 exit:
660
661 0 GlobusSoapMessageDebugExit();
662 0 return result;
663 }
664
665
666
667 globus_result_t
668 wsc_FaultCodes_array_init_contents(
669 wsc_FaultCodes_array * array)
670 0 {
671 GlobusFuncName(wsc_FaultCodes_array_init_contents);
672 0 GlobusSoapMessageDebugEnter();
673
674 0 array->elements = NULL;
675 0 array->length = 0;
676 0 array->type_info = &wsc_FaultCodes_info;
677
678 0 GlobusSoapMessageDebugExit();
679 0 return GLOBUS_SUCCESS;
680 }
681
682 globus_result_t
683 wsc_FaultCodes_array_init(
684 wsc_FaultCodes_array ** arr)
685 0 {
686 0 return globus_xsd_generic_array_init(
687 (globus_xsd_generic_array_t **) arr,
688 &wsc_FaultCodes_info);
689 }
690 /* wsc_FaultCodes_array_info() */
691
692 void
693 wsc_FaultCodes_array_destroy_contents(
694 wsc_FaultCodes_array * array)
695 0 {
696 0 globus_xsd_generic_array_destroy_contents(
697 (globus_xsd_generic_array_t *) array);
698 0 }
699
700 void
701 wsc_FaultCodes_array_destroy(
702 wsc_FaultCodes_array * array)
703 0 {
704
705 0 globus_xsd_generic_array_destroy(
706 (globus_xsd_generic_array_t *) array);
707 0 }
708
709 globus_result_t
710 wsc_FaultCodes_array_copy(
711 wsc_FaultCodes_array ** dest_arr,
712 const wsc_FaultCodes_array * src_arr)
713 0 {
714 0 return globus_xsd_generic_array_copy(
715 (globus_xsd_generic_array_t **) dest_arr,
716 (const globus_xsd_generic_array_t *) src_arr);
717 }
718
719 globus_result_t
720 wsc_FaultCodes_array_copy_contents(
721 wsc_FaultCodes_array * dest_arr,
722 const wsc_FaultCodes_array * src_arr)
723 0 {
724 0 return globus_xsd_generic_array_copy_contents(
725 (globus_xsd_generic_array_t *) dest_arr,
726 (const globus_xsd_generic_array_t *) src_arr);
727 }
728
729 wsc_FaultCodes *
730 wsc_FaultCodes_array_push(
731 wsc_FaultCodes_array * array)
732 0 {
733 /* Some contents initializers don't initialize subelments but to set their
734 * values to be NULL
735 */
736 0 if (array->type_info == NULL)
737 {
738 0 array->type_info = &wsc_FaultCodes_info;
739 }
740 0 return globus_xsd_generic_array_push(
741 (globus_xsd_generic_array_t *) array);
742 }
743
744
745 globus_result_t
746 wsc_FaultCodes_array_serialize(
747 const xsd_QName * element_qname,
748 const wsc_FaultCodes_array * array,
749 globus_soap_message_handle_t message,
750 globus_xsd_element_options_t options)
751 0 {
752 0 return globus_xsd_generic_array_serialize(
753 element_qname,
754 (const globus_xsd_generic_array_t *) array,
755 message,
756 options);
757 }
758
759 globus_result_t
760 wsc_FaultCodes_array_deserialize(
761 const xsd_QName * element_qname,
762 wsc_FaultCodes_array * array,
763 globus_soap_message_handle_t message,
764 globus_xsd_element_options_t options)
765 0 {
766 /* Some initializers set the array contents to NULL */
767 0 if (array->type_info == NULL)
768 {
769 0 array->type_info = &wsc_FaultCodes_info;
770 }
771
772 0 return globus_xsd_generic_array_deserialize(
773 element_qname,
774 (globus_xsd_generic_array_t *) array,
775 message,
776 options);
777 }
778
779
780 globus_result_t
781 wsc_FaultCodes_serialize_attribute(
782 const xsd_QName * attr_qname,
783 const wsc_FaultCodes * val,
784 globus_soap_message_handle_t handle,
785 globus_xsd_element_options_t options)
786 0 {
787 0 globus_result_t result = GLOBUS_SUCCESS;
788 GlobusFuncName(wsc_FaultCodes_serialize_attribute);
789 0 GlobusSoapMessageDebugEnter();
790
791
792 0 result = xsd_QName_serialize_attribute(
793 attr_qname, (xsd_QName *)val, handle, options);
794 0 if(result != GLOBUS_SUCCESS)
795 {
796 0 result = GlobusSoapMessageErrorSerializeFailed(
797 result, NULL, attr_qname);
798 0 goto exit;
799 }
800
801 0 exit:
802
803 0 GlobusSoapMessageDebugExit();
804 0 return result;
805 }
806
807 globus_result_t
808 wsc_FaultCodes_deserialize_attribute(
809 const xsd_QName * attr_qname,
810 wsc_FaultCodes * instance,
811 globus_soap_message_handle_t message,
812 globus_xsd_element_options_t options)
813 0 {
814 0 globus_result_t result = GLOBUS_SUCCESS;
815 GlobusFuncName(wsc_FaultCodes_deserialize_attribute);
816 0 GlobusSoapMessageDebugEnter();
817
818
819 0 result = xsd_QName_deserialize_attribute(
820 attr_qname, (xsd_QName *)instance, message, options);
821
822 0 if(result != GLOBUS_SUCCESS)
823 {
824 0 result = GlobusSoapMessageErrorDeserializeFailed(
825 result, attr_qname);
826 0 goto exit;
827 }
828
829 0 exit:
830
831 0 GlobusSoapMessageDebugExit();
832 0 return result;
833 }
834
835 globus_result_t
836 wsc_FaultCodes_deserialize_attribute_pointer(
837 const xsd_QName * attr_qname,
838 wsc_FaultCodes ** instance,
839 globus_soap_message_handle_t message,
840 globus_xsd_element_options_t options)
841 0 {
842 0 globus_result_t result = GLOBUS_SUCCESS;
843 GlobusFuncName(wsc_FaultCodes_deserialize_attribute_pointer);
844 0 GlobusSoapMessageDebugEnter();
845
846
847 0 result = xsd_QName_deserialize_attribute_pointer(
848 attr_qname, (xsd_QName **)instance, message, options);
849
850 0 if(GlobusSoapMessageStatusAttributeNotFoundCheck(result))
851 {
852 0 result = GLOBUS_SUCCESS;
853 0 wsc_FaultCodes_destroy(*instance);
854 0 *instance = NULL;
855 goto exit;
856 }
857
858 0 exit:
859
860 0 GlobusSoapMessageDebugExit();
861 0 return result;
862 }
863
864
865 static
866 xsd_QName * wsc_FaultCodes_l_restrictions[] =
867 {
868 &wsc_FaultCodes_wsc_BadContextToken,
869
870
871 &wsc_FaultCodes_wsc_UnsupportedContextToken,
872
873
874 &wsc_FaultCodes_wsc_UnknownDerivationSource,
875
876
877
878 NULL
879 };
880
881 globus_bool_t
882 wsc_FaultCodes_l_is_valid_restriction(
883 const wsc_FaultCodes * instance)
884 0 {
885 int i;
886 0 globus_bool_t valid = GLOBUS_FALSE;
887 GlobusFuncName(wsc_FaultCodes_l_validate_restriction);
888 0 GlobusSoapMessageDebugEnter();
889
890
891
892 0 for (i = 0; wsc_FaultCodes_l_restrictions[i] != NULL; i++)
893 {
894
895 0 if (xsd_QName_keyeq((void *) wsc_FaultCodes_l_restrictions[i],
896 (void *) instance))
897 {
898 0 valid = GLOBUS_TRUE;
899
900 0 break;
901 }
902
903 }
904
905 0 GlobusSoapMessageDebugExit();
906
907 0 return valid;