1 /*
2 * Portions of this file Copyright 1999-2005 University of Chicago
3 * Portions of this file Copyright 1999-2005 The University of Southern California.
4 *
5 * This file or a portion of this file is licensed under the
6 * terms of the Globus Toolkit Public License, found at
7 * http://www.globus.org/toolkit/download/license.html.
8 * If you redistribute this file, with or without
9 * modifications, you must include this notice in the file.
10 */
11
12
13 /*
14 * This file is automatically generated by the Globus WSDLtoC converter
15 */
16
17 #include "xsd_QName.h"
18 #include "globus_soap_message.h"
19 #include "globus_xsd_type_info.h"
20 #include "wsseu_AttributedURI.h"
21
22 #ifndef GLOBUS_DONT_DOCUMENT_INTERNAL
23 xsd_QName wsseu_AttributedURI_qname =
24 {
25 WSSEU_ATTRIBUTEDURI_NS,
26 WSSEU_ATTRIBUTEDURI_LOCAL
27 };
28 #endif /* GLOBUS_DONT_DOCUMENT_INTERNAL */
29
30 globus_result_t
31 wsseu_AttributedURI_serialize_wrapper(
32 xsd_QName * element_qname,
33 void * instance,
34 globus_soap_message_handle_t message_handle,
35 globus_xsd_element_options_t options)
36 0 {
37 0 return wsseu_AttributedURI_serialize(
38 element_qname,
39 (wsseu_AttributedURI *) instance,
40 message_handle, options);
41 }
42
43 globus_result_t
44 wsseu_AttributedURI_deserialize_pointer_wrapper(
45 xsd_QName * element_qname,
46 void ** ip,
47 globus_soap_message_handle_t message_handle,
48 globus_xsd_element_options_t options)
49 0 {
50 0 return wsseu_AttributedURI_deserialize_pointer(
51 element_qname,
52 (wsseu_AttributedURI **) ip,
53 message_handle, options);
54 }
55
56 globus_result_t
57 wsseu_AttributedURI_init_wrapper(void **object)
58 0 {
59 0 return wsseu_AttributedURI_init(
60 (wsseu_AttributedURI **) object);
61 }
62
63 void
64 wsseu_AttributedURI_destroy_wrapper(
65 void * object)
66 0 {
67 0 wsseu_AttributedURI_destroy(
68 (wsseu_AttributedURI *) object);
69 }
70
71 globus_result_t
72 wsseu_AttributedURI_copy_wrapper(
73 void ** dest_obj,
74 void * src_obj)
75 0 {
76 0 return wsseu_AttributedURI_copy(
77 (wsseu_AttributedURI **) dest_obj,
78 (wsseu_AttributedURI *) src_obj);
79 }
80
81 globus_result_t
82 wsseu_AttributedURI_init_contents_wrapper(void *object)
83 0 {
84 0 return wsseu_AttributedURI_init_contents(
85 (wsseu_AttributedURI *) object);
86 }
87
88 void
89 wsseu_AttributedURI_destroy_contents_wrapper(
90 void * object)
91 0 {
92 0 wsseu_AttributedURI_destroy_contents(
93 (wsseu_AttributedURI *) object);
94 }
95
96 globus_result_t
97 wsseu_AttributedURI_copy_contents_wrapper(
98 void * dest_obj,
99 void * src_obj)
100 0 {
101 0 return wsseu_AttributedURI_copy_contents(
102 (wsseu_AttributedURI *) dest_obj,
103 (wsseu_AttributedURI *) src_obj);
104 }
105
106 globus_result_t
107 wsseu_AttributedURI_serialize_contents_wrapper(
108 xsd_QName * element_qname,
109 void * instance,
110 globus_soap_message_handle_t message_handle,
111 globus_xsd_element_options_t options)
112 0 {
113 0 return wsseu_AttributedURI_serialize_contents(
114 element_qname,
115 (wsseu_AttributedURI *) instance,
116 message_handle, options);
117 }
118
119 globus_result_t
120 wsseu_AttributedURI_deserialize_contents_wrapper(
121 xsd_QName * element_qname,
122 void ** instance,
123 globus_soap_message_handle_t message_handle,
124 globus_xsd_element_options_t options)
125 0 {
126 globus_result_t result;
127 GlobusFuncName(wsseu_AttributedURI_deserialize_contents_wrapper);
128 0 GlobusSoapMessageDebugEnter();
129
130 0 if(!*instance)
131 {
132 0 result = wsseu_AttributedURI_init(
133 (wsseu_AttributedURI **)instance);
134 0 if(result != GLOBUS_SUCCESS)
135 {
136 0 goto error;
137 }
138 }
139
140 0 result = wsseu_AttributedURI_deserialize_contents(
141 element_qname,
142 *(wsseu_AttributedURI **)instance,
143 message_handle, options);
144 0 error:
145 0 GlobusSoapMessageDebugExit();
146 0 return result;
147 }
148
149 globus_result_t
150 wsseu_AttributedURI_array_serialize_wrapper(
151 xsd_QName * element,
152 void * instance,
153 globus_soap_message_handle_t message,
154 globus_xsd_element_options_t options)
155 0 {
156 0 return wsseu_AttributedURI_array_serialize(
157 element,
158 (wsseu_AttributedURI_array *) instance,
159 message, options);
160 }
161
162 globus_result_t
163 wsseu_AttributedURI_array_deserialize_wrapper(
164 xsd_QName * element_qname,
165 void ** inst,
166 globus_soap_message_handle_t message,
167 globus_xsd_element_options_t options)
168 0 {
169 0 if(!*inst)
170 {
171 globus_result_t result;
172
173 0 result = wsseu_AttributedURI_array_init(
174 (wsseu_AttributedURI_array **)inst);
175 0 if(result != GLOBUS_SUCCESS)
176 {
177 0 return result;
178 }
179 }
180
181 0 return wsseu_AttributedURI_array_deserialize(
182 element_qname,
183 *(wsseu_AttributedURI_array **) inst,
184 message, options);
185 }
186
187 globus_result_t
188 wsseu_AttributedURI_array_init_wrapper(
189 void ** arr)
190 0 {
191 0 return wsseu_AttributedURI_array_init(
192 (wsseu_AttributedURI_array **) arr);
193 }
194
195 void
196 wsseu_AttributedURI_array_destroy_wrapper(
197 void * arr)
198 0 {
199 0 wsseu_AttributedURI_array_destroy(
200 (wsseu_AttributedURI_array *) arr);
201 }
202
203 globus_result_t
204 wsseu_AttributedURI_array_copy_wrapper(
205 void ** dest_arr,
206 void * src_arr)
207 0 {
208 0 return wsseu_AttributedURI_array_copy(
209 (wsseu_AttributedURI_array **) dest_arr,
210 (wsseu_AttributedURI_array *) src_arr);
211 }
212
213 globus_result_t
214 wsseu_AttributedURI_array_init_contents_wrapper(
215 void * arr)
216 0 {
217 0 return wsseu_AttributedURI_array_init_contents(
218 (wsseu_AttributedURI_array *) arr);
219 }
220
221 void
222 wsseu_AttributedURI_array_destroy_contents_wrapper(
223 void * arr)
224 0 {
225 0 wsseu_AttributedURI_array_destroy_contents(
226 (wsseu_AttributedURI_array *) arr);
227 }
228
229 globus_result_t
230 wsseu_AttributedURI_array_copy_contents_wrapper(
231 void * dest_arr,
232 void * src_arr)
233 0 {
234 0 return wsseu_AttributedURI_array_copy_contents(
235 (wsseu_AttributedURI_array *) dest_arr,
236 (wsseu_AttributedURI_array *) src_arr);
237 }
238
239 struct globus_xsd_type_info_s wsseu_AttributedURI_contents_info =
240 {
241 &wsseu_AttributedURI_qname,
242 wsseu_AttributedURI_serialize_contents_wrapper,
243 wsseu_AttributedURI_deserialize_contents_wrapper,
244 wsseu_AttributedURI_init_wrapper,
245 wsseu_AttributedURI_destroy_wrapper,
246 wsseu_AttributedURI_copy_wrapper,
247 wsseu_AttributedURI_init_contents_wrapper,
248 wsseu_AttributedURI_destroy_contents_wrapper,
249 wsseu_AttributedURI_copy_contents_wrapper,
250 sizeof(wsseu_AttributedURI),
251 NULL,
252 NULL,
253 NULL
254 };
255
256 struct globus_xsd_type_info_s wsseu_AttributedURI_array_info =
257 {
258 &wsseu_AttributedURI_qname,
259 wsseu_AttributedURI_array_serialize_wrapper,
260 wsseu_AttributedURI_array_deserialize_wrapper,
261 wsseu_AttributedURI_array_init_wrapper,
262 wsseu_AttributedURI_array_destroy_wrapper,
263 wsseu_AttributedURI_array_copy_wrapper,
264 wsseu_AttributedURI_array_init_contents_wrapper,
265 wsseu_AttributedURI_array_destroy_contents_wrapper,
266 wsseu_AttributedURI_array_copy_contents_wrapper,
267 sizeof(wsseu_AttributedURI),
268 wsseu_AttributedURI_array_push_wrapper,
269 NULL,
270 NULL
271 };
272
273 struct globus_xsd_type_info_s wsseu_AttributedURI_info =
274 {
275 &wsseu_AttributedURI_qname,
276 wsseu_AttributedURI_serialize_wrapper,
277 wsseu_AttributedURI_deserialize_pointer_wrapper,
278 wsseu_AttributedURI_init_wrapper,
279 wsseu_AttributedURI_destroy_wrapper,
280 wsseu_AttributedURI_copy_wrapper,
281 wsseu_AttributedURI_init_contents_wrapper,
282 wsseu_AttributedURI_destroy_contents_wrapper,
283 wsseu_AttributedURI_copy_contents_wrapper,
284 sizeof(wsseu_AttributedURI),
285 NULL,
286 &wsseu_AttributedURI_contents_info,
287 &wsseu_AttributedURI_array_info
288 };
289
290 globus_result_t
291 wsseu_AttributedURI_init_contents(
292 wsseu_AttributedURI * instance)
293 0 {
294 0 globus_result_t result = GLOBUS_SUCCESS;
295 GlobusFuncName(wsseu_AttributedURI_init_contents);
296 0 GlobusSoapMessageDebugEnter();
297
298 0 memset(instance, 0, sizeof(wsseu_AttributedURI));
299
300 0 GlobusSoapMessageDebugExit();
301 0 return result;
302 }
303
304 globus_result_t
305 wsseu_AttributedURI_init(
306 wsseu_AttributedURI ** object)
307 0 {
308 wsseu_AttributedURI * instance;
309 0 globus_result_t result = GLOBUS_SUCCESS;
310 GlobusFuncName(wsseu_AttributedURI_init);
311 0 GlobusSoapMessageDebugEnter();
312
313 0 instance = globus_malloc(sizeof(wsseu_AttributedURI));
314 0 if(!instance)
315 {
316 0 result = GlobusSoapMessageErrorOutOfMemory;
317 0 goto exit;
318 }
319
320 0 memset(instance, 0, sizeof(wsseu_AttributedURI));
321
322 0 *object = instance;
323
324 0 exit:
325 0 GlobusSoapMessageDebugExit();
326 0 return result;
327 }
328
329 void
330 wsseu_AttributedURI_destroy(
331 wsseu_AttributedURI * instance)
332 0 {
333 GlobusFuncName(wsseu_AttributedURI_destroy);
334 0 GlobusSoapMessageDebugEnter();
335
336 0 if(!instance)
337 {
338 0 goto exit;
339 }
340
341 0 wsseu_AttributedURI_destroy_contents(instance);
342 0 globus_free(instance);
343
344 0 exit:
345
346 0 GlobusSoapMessageDebugExit();
347 }
348
349 void
350 wsseu_AttributedURI_destroy_contents(
351 wsseu_AttributedURI * instance)
352 0 {
353 GlobusFuncName(wsseu_AttributedURI_destroy_contents);
354 0 GlobusSoapMessageDebugEnter();
355
356 0 if(instance)
357 {
358
359
360 0 xsd_anyURI_destroy_contents(
361 &instance->base_value);
362
363 0 if(instance->_Id)
364 {
365 0 xsd_ID_destroy(
366 instance->_Id);
367 0 instance->_Id = NULL;
368 }
369
370 0 xsd_anyAttributes_destroy(instance->anyAttributes);
371 0 instance->anyAttributes = NULL;
372
373 }
374
375 0 GlobusSoapMessageDebugExit();
376 }
377
378 globus_result_t
379 wsseu_AttributedURI_copy(
380 wsseu_AttributedURI ** dest_obj,
381 const wsseu_AttributedURI * src_obj)
382 0 {
383 0 globus_result_t result = GLOBUS_SUCCESS;
384 wsseu_AttributedURI * instance;
385 GlobusFuncName(wsseu_AttributedURI_copy);
386
387 0 GlobusSoapMessageDebugEnter();
388
389 0 instance = malloc(sizeof(wsseu_AttributedURI));
390 0 if (instance == NULL)
391 {
392 0 GlobusSoapMessageDebugExit();
393 0 return GlobusSoapMessageErrorOutOfMemory;
394 }
395
396 0 result = wsseu_AttributedURI_copy_contents(instance, src_obj);
397 0 if(result != GLOBUS_SUCCESS)
398 {
399 0 globus_free(instance);
400 0 GlobusSoapMessageDebugExit();
401 0 return GlobusSoapMessageErrorOutOfMemory;
402 }
403
404 0 *dest_obj = instance;
405 0 GlobusSoapMessageDebugExit();
406 0 return result;
407 }
408
409 globus_result_t
410 wsseu_AttributedURI_copy_contents(
411 wsseu_AttributedURI * instance,
412 const wsseu_AttributedURI * src_obj)
413 0 {
414 0 globus_result_t result = GLOBUS_SUCCESS;
415 GlobusFuncName(wsseu_AttributedURI_copy_contents);
416
417 0 GlobusSoapMessageDebugEnter();
418
419
420 0 if(src_obj->_Id)
421 {
422 0 result = xsd_ID_copy(
423 &instance->_Id,
424 src_obj->_Id);
425 0 if(result != GLOBUS_SUCCESS)
426 {
427 0 result = GlobusSoapMessageErrorCopyFailed(
428 result, NULL, &xsd_ID_qname);
429 0 goto _Id_destroy;
430 }
431 }
432 else
433 {
434 0 instance->_Id = NULL;
435 }
436
437 0 if(src_obj->anyAttributes)
438 {
439 0 result = xsd_anyAttributes_copy(&instance->anyAttributes,
440 src_obj->anyAttributes);
441 0 if(result != GLOBUS_SUCCESS)
442 {
443 0 result = GlobusSoapMessageErrorCopyAnyAttrsFailed(
444 result, NULL);
445 0 goto xsd_anyAttributes_after_destroy;
446 }
447 }
448 else
449 {
450 0 instance->anyAttributes = NULL;
451 }
452
453 0 result = xsd_anyURI_copy_contents(
454 &instance->base_value,
455 &src_obj->base_value);
456 0 if(result != GLOBUS_SUCCESS)
457 {
458 0 result = GlobusSoapMessageErrorCopyFailed(
459 result, NULL, &xsd_anyURI_qname);
460 0 goto base_value_destroy;
461 }
462
463 goto exit;
464
465 fail_deserialize:
466
467 xsd_anyAttributes_destroy:
468 xsd_anyAttributes_destroy(instance->anyAttributes);
469 instance->anyAttributes = NULL;
470 0 xsd_anyAttributes_after_destroy:
471 0 xsd_anyURI_destroy_contents(
472 &instance->base_value);
473
474 0 base_value_destroy:
475
476 0 _Id_destroy:
477
478 0 if(instance->_Id)
479 {
480 0 xsd_ID_destroy(
481 instance->_Id);
482 0 instance->_Id = NULL;
483 }
484
485
486 0 exit:
487
488 0 GlobusSoapMessageDebugExit();
489 0 return result;
490 }
491
492
493
494 globus_result_t
495 wsseu_AttributedURI_serialize_contents(
496 xsd_QName * element_qname, /* ignored */
497 wsseu_AttributedURI * inst,
498 globus_soap_message_handle_t message_handle,
499 globus_xsd_element_options_t options)
500 0 {
501 0 globus_result_t result = GLOBUS_SUCCESS;
502 GlobusFuncName(wsseu_AttributedURI_serialize_contents);
503 0 GlobusSoapMessageDebugEnter();
504
505 0 result = wsseu_AttributedURI_serialize(
506 NULL,
507 inst,
508 message_handle,
509 options | GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
510 0 if(result != GLOBUS_SUCCESS)
511 {
512 0 result = GlobusSoapMessageErrorSerializeFailed(
513 result, NULL, element_qname);
514 goto exit;
515 }
516
517 0 exit:
518
519 0 GlobusSoapMessageDebugExit();
520 0 return result;
521 }
522
523
524
525 globus_result_t
526 wsseu_AttributedURI_serialize(
527 xsd_QName * element_qname,
528 wsseu_AttributedURI * instance,
529 globus_soap_message_handle_t message_handle,
530 globus_xsd_element_options_t options)
531 0 {
532 0 globus_result_t result = GLOBUS_SUCCESS;
533 xsd_QName subelement;
534 0 globus_list_t * any_attr_keys = NULL;
535 0 globus_list_t * any_attr_keys_iterator = NULL;
536 0 xsd_QName * type_attr = NULL;
537 0 char * prefix = NULL;
538 int prefix_created;
539 0 int define_prefix = 0;
540 0 int save_options = options;
541
542 GlobusFuncName(wsseu_AttributedURI_serialize);
543 0 GlobusSoapMessageDebugEnter();
544
545
546 0 if(!(options & GLOBUS_XSD_ELEMENT_CONTENTS_ONLY))
547 {
548 /* serialize wsseu_AttributedURI element */
549
550 0 result = globus_soap_message_invoke_ns_callouts(
551 message_handle,
552 element_qname,
553 GLOBUS_SOAP_MESSAGE_CALLOUT_NS_SET,
554 &options);
555 0 if(result != GLOBUS_SUCCESS)
556 {
557 0 result = GlobusSoapMessageErrorSerializeFailed(
558 result, NULL, element_qname);
559 0 goto exit;
560 }
561
562 0 result = globus_soap_message_element_ns_set(
563 message_handle,
564 element_qname->Namespace,
565 &options);
566 0 if(result != GLOBUS_SUCCESS)
567 {
568 0 result = GlobusSoapMessageErrorSerializeFailed(
569 result, NULL, element_qname);
570 0 goto exit;
571 }
572
573 0 if(instance->_Id)
574 {
575
576 0 result = globus_soap_message_attribute_ns_set(
577 message_handle,
578 "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd",
579 &options);
580
581 0 if(result != GLOBUS_SUCCESS)
582 {
583 xsd_QName error_qname;
584 0 error_qname.local = prefix;
585 0 error_qname.Namespace = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
586 0 result = GlobusSoapMessageErrorSerializeFailed(result,
587 NULL,
588 &error_qname);
589 0 goto exit;
590 }
591
592
593 }
594
595 0 if((options & GLOBUS_XSD_ELEMENT_TYPE_ATTR) &&
596 !globus_soap_message_serialize_is_c14n_subset(message_handle))
597 {
598 0 result = globus_soap_message_attribute_ns_set(
599 message_handle,
600 "http://www.w3.org/2001/XMLSchema-instance",
601 &options);
602 0 if(result != GLOBUS_SUCCESS)
603 {
604 0 result = GlobusSoapMessageErrorSerializeFailed(
605 result, NULL, element_qname);
606 0 goto exit;
607 }
608
609 0 result = globus_soap_message_attribute_ns_set(
610 message_handle,
611 wsseu_AttributedURI_qname.Namespace,
612 &options);
613 0 if(result != GLOBUS_SUCCESS)
614 {
615 0 result = GlobusSoapMessageErrorSerializeFailed(
616 result, NULL, element_qname);
617 0 goto exit;
618 }
619 }
620
621 0 result = xsd_anyAttributes_namespace_set(
622 message_handle, instance->anyAttributes, &options);
623 0 if(result != GLOBUS_SUCCESS)
624 {
625 0 result = GlobusSoapMessageErrorSerializeAnyAttrsFailed(
626 result, "Failed to set namespace");
627 0 goto exit;
628 }
629
630 0 result = globus_soap_message_invoke_callouts(
631 message_handle,
632 element_qname,
633 GLOBUS_SOAP_MESSAGE_CALLOUT_BEGIN);
634 0 if(result != GLOBUS_SUCCESS)
635 {
636 0 result = GlobusSoapMessageErrorSerializeFailed(
637 result, NULL, element_qname);
638 0 goto exit;
639 }
640
641 0 result = globus_soap_message_serialize_element(
642 message_handle,
643 element_qname,
644 options,
645 &wsseu_AttributedURI_qname);
646 0 if(result != GLOBUS_SUCCESS)
647 {
648 0 result = GlobusSoapMessageErrorSerializeFailed(
649 result, NULL, element_qname);
650 0 goto exit;
651 }
652
653 0 if((options & GLOBUS_XSD_ELEMENT_TYPE_ATTR) &&
654 !globus_soap_message_serialize_is_c14n_subset(message_handle))
655 {
656 0 xsd_QName_init(&type_attr);
657
658 0 type_attr->local = globus_libc_strdup("type");
659 0 type_attr->Namespace = globus_libc_strdup(XSI_NS);
660 }
661
662 /* serialize namespaces */
663
664 0 result = globus_soap_message_invoke_ns_callouts(
665 message_handle,
666 element_qname,
667 GLOBUS_SOAP_MESSAGE_CALLOUT_NS_ADD,
668 &options);
669 0 if(result != GLOBUS_SUCCESS)
670 {
671 0 result = GlobusSoapMessageErrorSerializeFailed(
672 result, NULL, element_qname);
673 0 goto exit;
674 }
675
676 0 result = globus_soap_message_element_ns_add(
677 message_handle,
678 element_qname->Namespace,
679 &options);
680 0 if(result != GLOBUS_SUCCESS)
681 {
682 0 result = GlobusSoapMessageErrorSerializeFailed(
683 result, NULL, element_qname);
684 0 goto exit;
685 }
686
687 0 if(instance->_Id)
688 {
689
690 0 result = globus_soap_message_attribute_ns_add(
691 message_handle,
692 "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd",
693 &options);
694
695 0 if(result != GLOBUS_SUCCESS)
696 {
697 xsd_QName error_qname;
698 0 error_qname.local = prefix;
699 0 error_qname.Namespace = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
700 0 result = GlobusSoapMessageErrorSerializeFailed(result,
701 NULL,
702 &error_qname);
703 0 goto exit;
704 }
705
706
707 }
708
709 0 if((options & GLOBUS_XSD_ELEMENT_TYPE_ATTR) &&
710 !globus_soap_message_serialize_is_c14n_subset(message_handle))
711 {
712 0 result = globus_soap_message_attribute_ns_add(
713 message_handle,
714 "http://www.w3.org/2001/XMLSchema-instance",
715 &options);
716 0 if(result != GLOBUS_SUCCESS)
717 {
718 0 result = GlobusSoapMessageErrorSerializeFailed(
719 result, NULL, element_qname);
720 0 goto exit;
721 }
722
723 0 result = globus_soap_message_attribute_ns_add(
724 message_handle,
725 wsseu_AttributedURI_qname.Namespace,
726 &options);
727 0 if(result != GLOBUS_SUCCESS)
728 {
729 0 result = GlobusSoapMessageErrorSerializeFailed(
730 result, NULL, element_qname);
731 0 goto exit;
732 }
733 }
734
735 0 result = xsd_anyAttributes_namespace_add(
736 message_handle, instance->anyAttributes, &options);
737 0 if(result != GLOBUS_SUCCESS)
738 {
739 0 result = GlobusSoapMessageErrorSerializeAnyAttrsFailed(
740 result, "Failed to add namespace");
741 0 goto exit;
742 }
743
744 /* serialize attributes */
745
746 0 subelement.Namespace = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
747 0 subelement.local = "Id";
748
749 0 if(instance->_Id)
750 {
751
752 0 result = xsd_ID_serialize_attribute(
753 &subelement,
754 instance->_Id,
755 message_handle,
756 options & (~GLOBUS_XSD_ELEMENT_SET_DEFAULT_NS));
757 0 if(result != GLOBUS_SUCCESS)
758 {
759 0 result = GlobusSoapMessageErrorSerializeFailed(result,
760 NULL,
761 element_qname);
762 0 goto exit;
763 }
764
765 }
766
767 0 if((options & GLOBUS_XSD_ELEMENT_TYPE_ATTR) &&
768 !globus_soap_message_serialize_is_c14n_subset(message_handle))
769 {
770 0 result = globus_soap_message_serialize_QName_attribute(
771 message_handle,
772 type_attr,
773 &wsseu_AttributedURI_qname);
774 0 if(result != GLOBUS_SUCCESS)
775 {
776 0 result = GlobusSoapMessageErrorSerializeFailed(
777 result, NULL, element_qname);
778 0 goto exit;
779 }
780 }
781
782 0 if(instance->anyAttributes)
783 {
784 0 any_attr_keys = xsd_anyAttributes_lex_sort(
785 instance->anyAttributes);
786 0 any_attr_keys_iterator = any_attr_keys;
787 }
788
789
790 0 result = globus_soap_message_invoke_callouts(
791 message_handle,
792 element_qname,
793 GLOBUS_SOAP_MESSAGE_CALLOUT_ATTR);
794 0 if(result != GLOBUS_SUCCESS)
795 {
796 0 result = GlobusSoapMessageErrorSerializeFailed(
797 result, NULL, element_qname);
798 0 goto exit;
799 }
800 }
801
802 0 if(!(options & GLOBUS_XSD_ELEMENT_CONTENTS_ONLY))
803 {
804 0 result = globus_soap_message_serialize_element_begin_close(
805 message_handle);
806 0 if(result != GLOBUS_SUCCESS)
807 {
808 0 result = GlobusSoapMessageErrorSerializeFailed(
809 result, NULL, element_qname);
810 0 goto exit;
811 }
812 }
813 0 options &= ~GLOBUS_XSD_ELEMENT_CONTENTS_ONLY;
814
815 /* serialize contents of type */
816
817 0 subelement.local = "base_value";
818 0 subelement.Namespace = NULL;
819
820 0 result = xsd_anyURI_serialize(
821 &subelement,
822 &instance->base_value,
823 message_handle,
824 GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
825 0 if(result != GLOBUS_SUCCESS)
826 {
827 0 result = GlobusSoapMessageErrorSerializeFailed(
828 result, NULL, &xsd_anyURI_qname);
829 0 goto exit;
830 }
831
832 0 options = save_options;
833
834 0 if(!(options & GLOBUS_XSD_ELEMENT_CONTENTS_ONLY))
835 {
836 /* add end element */
837 0 result = globus_soap_message_serialize_element_end(
838 message_handle,
839 element_qname,
840 options,
841 &wsseu_AttributedURI_qname);
842 0 if(result != GLOBUS_SUCCESS)
843 {
844 0 result = GlobusSoapMessageErrorSerializeFailed(
845 result, NULL, element_qname);
846 0 goto exit;
847 }
848
849 0 globus_soap_message_element_ns_remove(
850 message_handle,
851 element_qname->Namespace,
852 &options);
853
854 /* remove namespace/prefix mappings for these types */
855
856 0 if(instance->_Id)
857 {
858
859 0 globus_soap_message_attribute_ns_remove(
860 message_handle,
861 "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd",
862 &options);
863
864 }
865
866 0 if((options & GLOBUS_XSD_ELEMENT_TYPE_ATTR) &&
867 !globus_soap_message_serialize_is_c14n_subset(message_handle))
868 {
869 0 globus_soap_message_attribute_ns_remove(
870 message_handle,
871 "http://www.w3.org/2001/XMLSchema-instance",
872 &options);
873
874 0 globus_soap_message_attribute_ns_remove(
875 message_handle,
876 wsseu_AttributedURI_qname.Namespace,
877 &options);
878 }
879
880 0 result = xsd_anyAttributes_namespace_remove(
881 message_handle, instance->anyAttributes, &options);
882 0 if(result != GLOBUS_SUCCESS)
883 {
884 0 result = GlobusSoapMessageErrorSerializeAnyAttrsFailed(
885 result, "Failed to remove namespace");
886 0 goto exit;
887 }
888
889 0 result = globus_soap_message_invoke_ns_callouts(
890 message_handle,
891 element_qname,
892 GLOBUS_SOAP_MESSAGE_CALLOUT_NS_REMOVE,
893 &options);
894 0 if(result != GLOBUS_SUCCESS)
895 {
896 0 result = GlobusSoapMessageErrorSerializeFailed(
897 result, NULL, element_qname);
898 0 goto exit;
899 }
900
901 0 result = globus_soap_message_invoke_callouts(
902 message_handle,
903 element_qname,
904 GLOBUS_SOAP_MESSAGE_CALLOUT_END);
905 0 if(result != GLOBUS_SUCCESS)
906 {
907 0 result = GlobusSoapMessageErrorSerializeFailed(
908 result, NULL, element_qname);
909 goto exit;
910 }
911 }
912
913 0 exit:
914 0 if (type_attr)
915 {
916 0 xsd_QName_destroy(type_attr);
917 }
918
919 0 if(any_attr_keys)
920 {
921 0 globus_list_free(any_attr_keys);
922 }
923
924 0 GlobusSoapMessageDebugExit();
925 0 return result;
926 }
927
928
929
930 globus_result_t
931 wsseu_AttributedURI_deserialize_contents(
932 xsd_QName * element_qname, /* ignored */
933 wsseu_AttributedURI * inst,
934 globus_soap_message_handle_t message_handle,
935 globus_xsd_element_options_t options)
936 0 {
937 0 globus_result_t result = GLOBUS_SUCCESS;
938 GlobusFuncName(wsseu_AttributedURI_deserialize_contents);
939 0 GlobusSoapMessageDebugEnter();
940
941 0 result = wsseu_AttributedURI_deserialize(
942 NULL,
943 inst,
944 message_handle,
945 options | GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
946 0 if(result != GLOBUS_SUCCESS)
947 {
948 0 result = GlobusSoapMessageErrorDeserializeFailed(
949 result, element_qname);
950 goto exit;
951 }
952
953 0 exit:
954
955 0 GlobusSoapMessageDebugExit();
956 0 return result;
957 }
958
959
960
961 globus_result_t
962 wsseu_AttributedURI_deserialize(
963 xsd_QName * element_qname,
964 wsseu_AttributedURI * instance,
965 globus_soap_message_handle_t message_handle,
966 globus_xsd_element_options_t options)
967 0 {
968 0 globus_result_t result = GLOBUS_SUCCESS;
969 xsd_QName subelement;
970 GlobusFuncName(wsseu_AttributedURI_deserialize);
971 0 GlobusSoapMessageDebugEnter();
972
973
974 0 if(!(options & GLOBUS_XSD_ELEMENT_CONTENTS_ONLY))
975 {
976 0 result = globus_soap_message_deserialize_element(
977 message_handle, element_qname);
978 0 if(result != GLOBUS_SUCCESS)
979 {
980 0 result = GlobusSoapMessageErrorDeserializeFailed(
981 result, element_qname);
982 0 goto exit;
983 }
984
985 0 subelement.Namespace = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
986 0 subelement.local = "Id";
987
988 0 result = xsd_ID_deserialize_attribute_pointer(
989 &subelement,
990 &instance->_Id,
991 message_handle,
992 0);
993 0 if(result != GLOBUS_SUCCESS)
994 {
995 0 result = GlobusSoapMessageErrorDeserializeFailed(result, &subelement);
996 0 goto _Id_destroy;
997 }
998
999
1000 0 result = xsd_anyAttributes_init(&instance->anyAttributes);
1001 0 if(result != GLOBUS_SUCCESS)
1002 {
1003 0 result = GlobusSoapMessageErrorDeserializeFailed(
1004 result, element_qname);
1005 0 goto xsd_anyAttributes_after_destroy;
1006 }
1007
1008 0 result = xsd_anyAttributes_deserialize(
1009 message_handle,
1010 instance->anyAttributes);
1011 0 if(result != GLOBUS_SUCCESS)
1012 {
1013 0 result = GlobusSoapMessageErrorDeserializeFailed(
1014 result, element_qname);
1015 0 goto xsd_anyAttributes_destroy;
1016 }
1017
1018
1019 0 result = globus_soap_message_deserialize_element_begin_close(
1020 message_handle);
1021 0 if(result != GLOBUS_SUCCESS)
1022 {
1023 0 result = GlobusSoapMessageErrorDeserializeFailed(
1024 result, element_qname);
1025 0 goto fail_deserialize;
1026 }
1027 }
1028
1029 0 subelement.local = "base_value";
1030 0 subelement.Namespace = NULL;
1031
1032 0 result = xsd_anyURI_deserialize(
1033 &subelement,
1034 &instance->base_value,
1035 message_handle,
1036 GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
1037 0 if(result != GLOBUS_SUCCESS)
1038 {
1039 0 result = GlobusSoapMessageErrorDeserializeFailed(
1040 result,
1041 &xsd_anyURI_qname);
1042 0 goto base_value_destroy;
1043 }
1044
1045 0 if(!(options & GLOBUS_XSD_ELEMENT_CONTENTS_ONLY))
1046 {
1047 0 result = globus_soap_message_deserialize_element_end(
1048 message_handle,
1049 element_qname);
1050 0 if(result != GLOBUS_SUCCESS)
1051 {
1052 0 result = GlobusSoapMessageErrorDeserializeFailed(
1053 result, element_qname);
1054 goto fail_deserialize;
1055 }
1056 }
1057
1058 goto exit;
1059
1060 0 fail_deserialize:
1061
1062 0 xsd_anyAttributes_destroy:
1063 0 xsd_anyAttributes_destroy(instance->anyAttributes);
1064 0 instance->anyAttributes = NULL;
1065 0 xsd_anyAttributes_after_destroy:
1066 0 xsd_anyURI_destroy_contents(
1067 &instance->base_value);
1068
1069 0 base_value_destroy:
1070
1071 0 _Id_destroy:
1072
1073 0 if(instance->_Id)
1074 {
1075 0 xsd_ID_destroy(
1076 instance->_Id);
1077 0 instance->_Id = NULL;
1078 }
1079
1080
1081 0 exit:
1082
1083 0 GlobusSoapMessageDebugExit();
1084 0 return result;
1085 }
1086
1087
1088
1089 globus_result_t
1090 wsseu_AttributedURI_deserialize_pointer(
1091 xsd_QName * element_qname,
1092 wsseu_AttributedURI ** ip,
1093 globus_soap_message_handle_t message_handle,
1094 globus_xsd_element_options_t options)
1095 0 {
1096 0 wsseu_AttributedURI * instance = NULL;
1097 0 globus_result_t result = GLOBUS_SUCCESS;
1098 xsd_QName subelement;
1099 0 int found_attrs = 0;
1100 0 int empty_element = 0;
1101 GlobusFuncName(wsseu_AttributedURI_deserialize_pointer);
1102 0 GlobusSoapMessageDebugEnter();
1103
1104 0 *ip = NULL;
1105
1106 0 result = globus_soap_message_deserialize_element(
1107 message_handle, element_qname);
1108 0 if(result != GLOBUS_SUCCESS &&
1109 (GlobusSoapMessageStatusElementNotFoundCheck(result) ||
1110 GlobusSoapMessageStatusFailedElementCheck(result) ||
1111 GlobusSoapMessageStatusFailedWithTextCheck(result)))
1112 {
1113 0 *ip = NULL;
1114 0 result = GLOBUS_SUCCESS;
1115 0 goto exit;
1116 }
1117
1118 0 if(result != GLOBUS_SUCCESS)
1119 {
1120 0 result = GlobusSoapMessageErrorDeserializeFailed(
1121 result, element_qname);
1122 0 goto exit;
1123 }
1124
1125 0 if(globus_soap_message_deserialize_element_is_empty(
1126 message_handle))
1127 {
1128 0 empty_element = 1;
1129 }
1130
1131
1132
1133 0 result = wsseu_AttributedURI_init(&instance);
1134 0 if(result != GLOBUS_SUCCESS)
1135 {
1136 0 result = GlobusSoapMessageErrorDeserializeFailed(
1137 result, element_qname);
1138 0 goto exit;
1139 }
1140
1141
1142 0 subelement.Namespace = "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd";
1143 0 subelement.local = "Id";
1144
1145 0 result = xsd_ID_deserialize_attribute_pointer(
1146 &subelement,
1147 &instance->_Id,
1148 message_handle,
1149 0);
1150 0 if(result != GLOBUS_SUCCESS)
1151 {
1152 0 result = GlobusSoapMessageErrorDeserializeFailed(result, &subelement);
1153 0 goto _Id_destroy;
1154 }
1155
1156
1157 0 if(instance->_Id)
1158 {
1159 0 found_attrs++;
1160 }
1161
1162 0 result = xsd_anyAttributes_init(&instance->anyAttributes);
1163 0 if(result != GLOBUS_SUCCESS)
1164 {
1165 0 result = GlobusSoapMessageErrorDeserializeFailed(
1166 result, element_qname);
1167 0 goto xsd_anyAttributes_after_destroy;
1168 }
1169
1170 0 result = xsd_anyAttributes_deserialize(
1171 message_handle,
1172 instance->anyAttributes);
1173 0 if(result != GLOBUS_SUCCESS)
1174 {
1175 0 result = GlobusSoapMessageErrorDeserializeFailed(
1176 result, element_qname);
1177 0 goto xsd_anyAttributes_destroy;
1178 }
1179
1180 0 if(instance->anyAttributes &&
1181 xsd_anyAttributes_size(instance->anyAttributes) > 0)
1182 {
1183 0 found_attrs++;
1184 }
1185
1186
1187 0 if(empty_element)
1188 {
1189 0 result = globus_soap_message_deserialize_element_end(
1190 message_handle,
1191 element_qname);
1192 0 if(result != GLOBUS_SUCCESS)
1193 {
1194 0 result = GlobusSoapMessageErrorDeserializeFailed(
1195 result, element_qname);
1196 0 goto fail_deserialize;
1197 }
1198
1199 0 *ip = instance;
1200 0 goto exit;
1201 }
1202
1203 0 result = globus_soap_message_deserialize_element_begin_close(
1204 message_handle);
1205 0 if(result != GLOBUS_SUCCESS)
1206 {
1207 0 result = GlobusSoapMessageErrorDeserializeFailed(
1208 result, element_qname);
1209 0 goto exit;
1210 }
1211
1212
1213 0 subelement.local = "base_value";
1214 0 subelement.Namespace = NULL;
1215
1216 0 result = xsd_anyURI_deserialize(
1217 &subelement,
1218 &instance->base_value,
1219 message_handle,
1220 GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
1221 0 if(result != GLOBUS_SUCCESS)
1222 {
1223 0 result = GlobusSoapMessageErrorDeserializeFailed(
1224 result,
1225 &xsd_anyURI_qname);
1226 0 goto base_value_destroy;
1227 }
1228
1229
1230 0 result = globus_soap_message_deserialize_element_end(
1231 message_handle,
1232 element_qname);
1233 0 if(result != GLOBUS_SUCCESS)
1234 {
1235 0 result = GlobusSoapMessageErrorDeserializeFailed(
1236 result, element_qname);
1237 0 goto fail_deserialize;
1238 }
1239
1240 0 *ip = instance;
1241
1242 0 goto exit;
1243
1244 0 fail_deserialize:
1245
1246 0 xsd_anyAttributes_destroy:
1247 0 xsd_anyAttributes_destroy(instance->anyAttributes);
1248 0 instance->anyAttributes = NULL;
1249 0 xsd_anyAttributes_after_destroy:
1250 0 xsd_anyURI_destroy_contents(
1251 &instance->base_value);
1252
1253 0 base_value_destroy:
1254
1255 0 _Id_destroy:
1256
1257 0 if(instance->_Id)
1258 {
1259 0 xsd_ID_destroy(
1260 instance->_Id);
1261 0 instance->_Id = NULL;
1262 }
1263
1264 0 exit:
1265
1266 0 GlobusSoapMessageDebugExit();
1267 0 return result;
1268 }
1269
1270
1271 globus_result_t
1272 wsseu_AttributedURI_array_init_contents(
1273 wsseu_AttributedURI_array * array)
1274 0 {
1275 GlobusFuncName(wsseu_AttributedURI_array_init_contents);
1276 0 GlobusSoapMessageDebugEnter();
1277
1278 0 memset(array, 0, sizeof(wsseu_AttributedURI_array));
1279
1280 0 GlobusSoapMessageDebugExit();
1281 0 return GLOBUS_SUCCESS;
1282 }
1283
1284 globus_result_t
1285 wsseu_AttributedURI_array_init(
1286 wsseu_AttributedURI_array ** arr)
1287 0 {
1288 wsseu_AttributedURI_array * array;
1289 globus_result_t result;
1290 GlobusFuncName(wsseu_AttributedURI_array_init);
1291 0 GlobusSoapMessageDebugEnter();
1292
1293 0 array = (wsseu_AttributedURI_array *)
1294 globus_malloc(sizeof(wsseu_AttributedURI_array));
1295 0 if(!array)
1296 {
1297 0 result = GlobusSoapMessageErrorOutOfMemory;
1298 0 goto exit;
1299 }
1300
1301 0 result = wsseu_AttributedURI_array_init_contents(array);
1302 0 if(result != GLOBUS_SUCCESS)
1303 {
1304 0 globus_free(array);
1305 0 array = NULL;
1306
1307 }
1308
1309 0 *arr = array;
1310
1311 0 exit:
1312 0 GlobusSoapMessageDebugExit();
1313 0 return result;
1314 }
1315
1316 void
1317 wsseu_AttributedURI_array_destroy_contents(
1318 wsseu_AttributedURI_array * array)
1319 0 {
1320 0 int i = 0;
1321 GlobusFuncName(wsseu_AttributedURI_array_destroy_contents);
1322 0 GlobusSoapMessageDebugEnter();
1323
1324 0 for(; i < array->length; ++i)
1325 {
1326 0 wsseu_AttributedURI_destroy_contents(&array->elements[i]);
1327 }
1328
1329 0 if(array->elements)
1330 {
1331 0 globus_free(array->elements);
1332 0 array->elements = NULL;
1333 }
1334 0 array->length = 0;
1335
1336 0 GlobusSoapMessageDebugExit();
1337 }
1338
1339 void
1340 wsseu_AttributedURI_array_destroy(
1341 wsseu_AttributedURI_array * array)
1342 0 {
1343 GlobusFuncName(wsseu_AttributedURI_array_destroy);
1344 0 GlobusSoapMessageDebugEnter();
1345
1346 0 wsseu_AttributedURI_array_destroy_contents(array);
1347 0 globus_free(array);
1348
1349 0 GlobusSoapMessageDebugExit();
1350 }
1351
1352 globus_result_t
1353 wsseu_AttributedURI_array_copy(
1354 wsseu_AttributedURI_array ** dest_arr,
1355 const wsseu_AttributedURI_array * src_arr)
1356 0 {
1357 wsseu_AttributedURI_array * array;
1358 globus_result_t result;
1359 GlobusFuncName(wsseu_AttributedURI_array_copy);
1360 0 GlobusSoapMessageDebugEnter();
1361
1362 0 array = (wsseu_AttributedURI_array *) globus_malloc(
1363 sizeof(wsseu_AttributedURI_array));
1364 0 if(!array)
1365 {
1366 0 result = GlobusSoapMessageErrorOutOfMemory;
1367 0 GlobusSoapMessageDebugExit();
1368 0 return result;
1369 }
1370
1371 0 result = wsseu_AttributedURI_array_copy_contents(array, src_arr);
1372 0 if(result != GLOBUS_SUCCESS)
1373 {
1374 0 globus_free(array);
1375 0 GlobusSoapMessageDebugExit();
1376 0 return result;
1377 }
1378
1379 0 *dest_arr = array;
1380
1381 0 GlobusSoapMessageDebugExit();
1382 0 return GLOBUS_SUCCESS;
1383 }
1384
1385 globus_result_t
1386 wsseu_AttributedURI_array_copy_contents(
1387 wsseu_AttributedURI_array * dest_arr,
1388 const wsseu_AttributedURI_array * src_arr)
1389 0 {
1390 int i;
1391 0 globus_result_t result = GLOBUS_SUCCESS;
1392 GlobusFuncName(wsseu_AttributedURI_array_copy_contents);
1393 0 GlobusSoapMessageDebugEnter();
1394
1395 0 dest_arr->length = src_arr->length;
1396 0 if(dest_arr->length > 0)
1397 {
1398 0 dest_arr->elements = (wsseu_AttributedURI *) malloc(
1399 sizeof(wsseu_AttributedURI) * dest_arr->length);
1400 0 if(!dest_arr->elements)
1401 {
1402 0 result = GlobusSoapMessageErrorOutOfMemory;
1403 0 GlobusSoapMessageDebugExit();
1404 0 return result;
1405 }
1406 }
1407 else
1408 {
1409 0 dest_arr->elements = NULL;
1410 }
1411
1412 0 for(i = 0; i < dest_arr->length; i++)
1413 {
1414 0 result = wsseu_AttributedURI_copy_contents(
1415 &dest_arr->elements[i], &src_arr->elements[i]);
1416 0 if(result != GLOBUS_SUCCESS)
1417 {
1418 0 while(i--)
1419 {
1420 0 wsseu_AttributedURI_destroy_contents(&dest_arr->elements[i]);
1421 }
1422
1423 0 globus_free(dest_arr->elements);
1424 0 dest_arr->elements = NULL;
1425 0 dest_arr->length = 0;
1426 0 break;
1427 }
1428 }
1429
1430 0 GlobusSoapMessageDebugExit();
1431 0 return result;
1432 }
1433
1434 wsseu_AttributedURI *
1435 wsseu_AttributedURI_array_push(
1436 wsseu_AttributedURI_array * array)
1437 0 {
1438 GlobusFuncName(wsseu_AttributedURI_array_push);
1439 0 GlobusSoapMessageDebugEnter();
1440
1441 0 array->elements = realloc(array->elements,
1442 sizeof(wsseu_AttributedURI) *
1443 (array->length + 1));
1444 0 memset(&array->elements[array->length], 0, sizeof(wsseu_AttributedURI));
1445 0 array->length++;
1446
1447 0 GlobusSoapMessageDebugExit();
1448 0 return (&array->elements[array->length - 1]);
1449 }
1450
1451 void *
1452 wsseu_AttributedURI_array_push_wrapper(
1453 void * array)
1454 0 {
1455 0 return (void *) wsseu_AttributedURI_array_push((wsseu_AttributedURI_array *) array);
1456 }
1457
1458 globus_result_t
1459 wsseu_AttributedURI_array_serialize(
1460 xsd_QName * element_qname,
1461 wsseu_AttributedURI_array * array,
1462 globus_soap_message_handle_t message,
1463 globus_xsd_element_options_t options)
1464 0 {
1465 0 globus_result_t result = GLOBUS_SUCCESS;
1466 0 int i = 0;
1467 GlobusFuncName(wsseu_AttributedURI_array_serialize);
1468 0 GlobusSoapMessageDebugEnter();
1469
1470 0 for(; i < array->length; ++i)
1471 {
1472 0 result = wsseu_AttributedURI_serialize(
1473 element_qname,
1474 &array->elements[i],
1475 message,
1476 options);
1477 0 if(result != GLOBUS_SUCCESS)
1478 {
1479 0 goto exit;
1480 }
1481 }
1482
1483 0 exit:
1484
1485 0 GlobusSoapMessageDebugExit();
1486 0 return result;
1487 }
1488
1489 globus_result_t
1490 wsseu_AttributedURI_array_deserialize(
1491 xsd_QName * element_qname,
1492 wsseu_AttributedURI_array * array,
1493 globus_soap_message_handle_t message,
1494 globus_xsd_element_options_t options)
1495 0 {
1496 0 globus_result_t result = GLOBUS_SUCCESS;
1497 0 int i = 0;
1498 int pre_length;
1499 GlobusFuncName(wsseu_AttributedURI_array_deserialize);
1500 0 GlobusSoapMessageDebugEnter();
1501
1502 0 pre_length = array->length;
1503
1504 0 for(i = 0; i < pre_length; ++i)
1505 {
1506 0 result = wsseu_AttributedURI_deserialize(
1507 element_qname,
1508 &array->elements[i],
1509 message,
1510 options);
1511 0 if(result != GLOBUS_SUCCESS)
1512 {
1513 0 if(GlobusSoapMessageStatusFailedElementCheck(result) ||
1514 GlobusSoapMessageStatusElementNotFoundCheck(result) ||
1515 GlobusSoapMessageStatusFailedWithTextCheck(result))
1516 {
1517 0 result = GLOBUS_SUCCESS;
1518 0 break;
1519 }
1520
1521 0 result = GlobusSoapMessageErrorDeserializeFailed(
1522 result, element_qname);
1523 0 goto exit;
1524 }
1525 }
1526
1527 0 while(result == GLOBUS_SUCCESS)
1528 {
1529 wsseu_AttributedURI next;
1530 0 memset(&next, 0, sizeof(wsseu_AttributedURI));
1531
1532 0 result = wsseu_AttributedURI_deserialize(
1533 element_qname,
1534 &next,
1535 message,
1536 options);
1537 0 if(result != GLOBUS_SUCCESS)
1538 {
1539 0 if(GlobusSoapMessageStatusFailedElementCheck(result) ||
1540 GlobusSoapMessageStatusElementNotFoundCheck(result) ||
1541 GlobusSoapMessageStatusFailedWithTextCheck(result))
1542 {
1543 0 result = GLOBUS_SUCCESS;
1544 0 break;
1545 }
1546
1547 0 result = GlobusSoapMessageErrorDeserializeFailed(
1548 result, element_qname);
1549 0 goto exit;
1550 }
1551
1552 0 array->elements = realloc(
1553 array->elements,
1554 (array->length + 1) * sizeof(wsseu_AttributedURI));
1555 0 if(!array->elements)
1556 {
1557 0 result = GlobusSoapMessageErrorOutOfMemory;
1558 0 goto exit;
1559 }
1560 0 array->elements[array->length] = next;
1561 0 array->length++;
1562 0 ++i;
1563 }
1564
1565 0 exit:
1566
1567 0 if(result != GLOBUS_SUCCESS)
1568 {
1569 0 int di = 0;
1570 0 for(; di < i; ++di)
1571 {
1572 0 wsseu_AttributedURI_destroy_contents(
1573 &array->elements[di]);
1574 0 memset(&array->elements[di], 0, sizeof(wsseu_AttributedURI));
1575 }
1576 }
1577
1578 0 GlobusSoapMessageDebugExit();
1579 0 return result;