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 by the Globus WSDLtoC converter
20 */
21
22 #include "xsd_QName.h"
23 #include "globus_soap_message.h"
24 #include "globus_xsd_type_info.h"
25 #include "wsu_TimestampType.h"
26 #include "globus_xsd_generic_array.h"
27
28 xsd_QName wsu_TimestampType_choice_qname =
29 {
30 "http://schemas.xmlsoap.org/ws/2002/07/utility",
31 "TimestampType_choice"
32 };
33
34 static
35 globus_result_t
36 wsu_TimestampType_choice_serialize_wrapper(
37 const xsd_QName * element_qname,
38 const void * instance,
39 globus_soap_message_handle_t message_handle,
40 globus_xsd_element_options_t options)
41 0 {
42 0 return wsu_TimestampType_choice_serialize(
43 element_qname,
44 (wsu_TimestampType_choice *) instance,
45 message_handle, options);
46 }
47
48 static
49 globus_result_t
50 wsu_TimestampType_choice_deserialize_pointer_wrapper(
51 const xsd_QName * element_qname,
52 void ** ip,
53 globus_soap_message_handle_t message_handle,
54 globus_xsd_element_options_t options)
55 0 {
56 0 return wsu_TimestampType_choice_deserialize_pointer(
57 element_qname,
58 (wsu_TimestampType_choice **) ip,
59 message_handle, options);
60 }
61
62 static
63 globus_result_t
64 wsu_TimestampType_choice_init_wrapper(void **object)
65 0 {
66 0 return wsu_TimestampType_choice_init(
67 (wsu_TimestampType_choice **) object);
68 }
69
70 static
71 void
72 wsu_TimestampType_choice_destroy_wrapper(
73 void * object)
74 0 {
75 0 wsu_TimestampType_choice_destroy(
76 (wsu_TimestampType_choice *) object);
77 0 }
78
79 static
80 globus_result_t
81 wsu_TimestampType_choice_copy_wrapper(
82 void ** dest_obj,
83 const void * src_obj)
84 0 {
85 0 return wsu_TimestampType_choice_copy(
86 (wsu_TimestampType_choice **) dest_obj,
87 (wsu_TimestampType_choice *) src_obj);
88 }
89
90 static
91 globus_result_t
92 wsu_TimestampType_choice_init_contents_wrapper(void *object)
93 0 {
94 0 return wsu_TimestampType_choice_init_contents(
95 (wsu_TimestampType_choice *) object);
96 }
97
98 static
99 void
100 wsu_TimestampType_choice_destroy_contents_wrapper(
101 void * object)
102 0 {
103 0 wsu_TimestampType_choice_destroy_contents(
104 (wsu_TimestampType_choice *) object);
105 0 }
106
107 static
108 globus_result_t
109 wsu_TimestampType_choice_copy_contents_wrapper(
110 void * dest_obj,
111 const void * src_obj)
112 0 {
113 0 return wsu_TimestampType_choice_copy_contents(
114 (wsu_TimestampType_choice *) dest_obj,
115 (wsu_TimestampType_choice *) src_obj);
116 }
117
118 static
119 globus_result_t
120 wsu_TimestampType_choice_serialize_contents_wrapper(
121 const xsd_QName * element_qname,
122 const void * instance,
123 globus_soap_message_handle_t message_handle,
124 globus_xsd_element_options_t options)
125 0 {
126 0 return wsu_TimestampType_choice_serialize_contents(
127 element_qname,
128 (const wsu_TimestampType_choice *) instance,
129 message_handle, options);
130 }
131
132 static
133 globus_result_t
134 wsu_TimestampType_choice_deserialize_contents_wrapper(
135 const xsd_QName * element_qname,
136 void ** instance,
137 globus_soap_message_handle_t message_handle,
138 globus_xsd_element_options_t options)
139 0 {
140 globus_result_t result;
141 GlobusFuncName(wsu_TimestampType_choice_deserialize_contents_wrapper);
142 0 GlobusSoapMessageDebugEnter();
143
144 0 if(!*instance)
145 {
146 0 result = wsu_TimestampType_choice_init(
147 (wsu_TimestampType_choice **)instance);
148 0 if(result != GLOBUS_SUCCESS)
149 {
150 0 goto error;
151 }
152 }
153
154 0 result = wsu_TimestampType_choice_deserialize_contents(
155 element_qname,
156 *(wsu_TimestampType_choice **)instance,
157 message_handle, options);
158 0 error:
159 0 GlobusSoapMessageDebugExit();
160 0 return result;
161 }
162
163 static
164 globus_result_t
165 wsu_TimestampType_choice_array_serialize_wrapper(
166 const xsd_QName * element,
167 const void * instance,
168 globus_soap_message_handle_t message,
169 globus_xsd_element_options_t options)
170 0 {
171 0 return wsu_TimestampType_choice_array_serialize(
172 element,
173 (wsu_TimestampType_choice_array *) instance,
174 message, options);
175 }
176
177 static
178 globus_result_t
179 wsu_TimestampType_choice_array_deserialize_wrapper(
180 const xsd_QName * element_qname,
181 void ** inst,
182 globus_soap_message_handle_t message,
183 globus_xsd_element_options_t options)
184 0 {
185 0 if(!*inst)
186 {
187 globus_result_t result;
188
189 0 result = wsu_TimestampType_choice_array_init(
190 (wsu_TimestampType_choice_array **)inst);
191 0 if(result != GLOBUS_SUCCESS)
192 {
193 0 return result;
194 }
195 }
196
197 0 return wsu_TimestampType_choice_array_deserialize(
198 element_qname,
199 *(wsu_TimestampType_choice_array **) inst,
200 message, options);
201 }
202
203 static
204 globus_result_t
205 wsu_TimestampType_choice_array_init_wrapper(
206 void ** arr)
207 0 {
208 0 return wsu_TimestampType_choice_array_init(
209 (wsu_TimestampType_choice_array **) arr);
210 }
211
212 static
213 void
214 wsu_TimestampType_choice_array_destroy_wrapper(
215 void * arr)
216 0 {
217 0 wsu_TimestampType_choice_array_destroy(
218 (wsu_TimestampType_choice_array *) arr);
219 0 }
220
221 static
222 globus_result_t
223 wsu_TimestampType_choice_array_copy_wrapper(
224 void ** dest_arr,
225 const void * src_arr)
226 0 {
227 0 return wsu_TimestampType_choice_array_copy(
228 (wsu_TimestampType_choice_array **) dest_arr,
229 (const wsu_TimestampType_choice_array *) src_arr);
230 }
231
232 static
233 globus_result_t
234 wsu_TimestampType_choice_array_init_contents_wrapper(
235 void * arr)
236 0 {
237 0 return wsu_TimestampType_choice_array_init_contents(
238 (wsu_TimestampType_choice_array *) arr);
239 }
240
241 static
242 void
243 wsu_TimestampType_choice_array_destroy_contents_wrapper(
244 void * arr)
245 0 {
246 0 wsu_TimestampType_choice_array_destroy_contents(
247 (wsu_TimestampType_choice_array *) arr);
248 0 }
249
250 static
251 globus_result_t
252 wsu_TimestampType_choice_array_copy_contents_wrapper(
253 void * dest_arr,
254 const void * src_arr)
255 0 {
256 0 return wsu_TimestampType_choice_array_copy_contents(
257 (wsu_TimestampType_choice_array *) dest_arr,
258 (const wsu_TimestampType_choice_array *) src_arr);
259 }
260
261 static
262 void *
263 wsu_TimestampType_choice_array_push_wrapper(
264 void * array)
265 0 {
266 0 return (void *) wsu_TimestampType_choice_array_push(
267 (wsu_TimestampType_choice_array *) array);
268 }
269
270 struct globus_xsd_type_info_s wsu_TimestampType_choice_array_info =
271 {
272 &wsu_TimestampType_choice_qname,
273 wsu_TimestampType_choice_array_serialize_wrapper,
274 wsu_TimestampType_choice_array_deserialize_wrapper,
275 wsu_TimestampType_choice_array_init_wrapper,
276 wsu_TimestampType_choice_array_destroy_wrapper,
277 wsu_TimestampType_choice_array_copy_wrapper,
278 wsu_TimestampType_choice_array_init_contents_wrapper,
279 wsu_TimestampType_choice_array_destroy_contents_wrapper,
280 wsu_TimestampType_choice_array_copy_contents_wrapper,
281 sizeof(wsu_TimestampType_choice),
282 wsu_TimestampType_choice_array_push_wrapper,
283 NULL,
284 NULL
285 };
286
287 struct globus_xsd_type_info_s wsu_TimestampType_choice_contents_info =
288 {
289 &wsu_TimestampType_choice_qname,
290 wsu_TimestampType_choice_serialize_contents_wrapper,
291 wsu_TimestampType_choice_deserialize_contents_wrapper,
292 wsu_TimestampType_choice_init_wrapper,
293 wsu_TimestampType_choice_destroy_wrapper,
294 wsu_TimestampType_choice_copy_wrapper,
295 wsu_TimestampType_choice_init_contents_wrapper,
296 wsu_TimestampType_choice_destroy_contents_wrapper,
297 wsu_TimestampType_choice_copy_contents_wrapper,
298 sizeof(wsu_TimestampType_choice),
299 NULL,
300 NULL,
301 NULL
302 };
303
304 struct globus_xsd_type_info_s wsu_TimestampType_choice_info =
305 {
306 &wsu_TimestampType_choice_qname,
307 wsu_TimestampType_choice_serialize_wrapper,
308 wsu_TimestampType_choice_deserialize_pointer_wrapper,
309 wsu_TimestampType_choice_init_wrapper,
310 wsu_TimestampType_choice_destroy_wrapper,
311 wsu_TimestampType_choice_copy_wrapper,
312 wsu_TimestampType_choice_init_contents_wrapper,
313 wsu_TimestampType_choice_destroy_contents_wrapper,
314 wsu_TimestampType_choice_copy_contents_wrapper,
315 sizeof(wsu_TimestampType_choice),
316 NULL,
317 &wsu_TimestampType_choice_contents_info,
318 &wsu_TimestampType_choice_array_info
319 };
320
321 globus_result_t
322 wsu_TimestampType_choice_init_contents(
323 wsu_TimestampType_choice * instance)
324 0 {
325 0 globus_result_t result = GLOBUS_SUCCESS;
326 GlobusFuncName(wsu_TimestampType_choice_init_contents);
327 0 GlobusSoapMessageDebugEnter();
328
329 0 memset(instance, 0, sizeof(wsu_TimestampType));
330
331 0 GlobusSoapMessageDebugExit();
332 0 return result;
333 }
334
335 globus_result_t
336 wsu_TimestampType_choice_init(
337 wsu_TimestampType_choice ** object)
338 0 {
339 wsu_TimestampType_choice * instance;
340 0 globus_result_t result = GLOBUS_SUCCESS;
341 GlobusFuncName(wsu_TimestampType_choice_init);
342 0 GlobusSoapMessageDebugEnter();
343
344 0 instance = globus_malloc(sizeof(wsu_TimestampType_choice));
345 0 if(!instance)
346 {
347 0 result = GlobusSoapMessageErrorOutOfMemory;
348 0 goto exit;
349 }
350
351 0 memset(instance, 0, sizeof(wsu_TimestampType_choice));
352
353 0 *object = instance;
354
355 0 exit:
356 0 GlobusSoapMessageDebugExit();
357 0 return result;
358 }
359
360 void
361 wsu_TimestampType_choice_destroy(
362 wsu_TimestampType_choice * instance)
363 0 {
364 GlobusFuncName(wsu_TimestampType_choice_destroy);
365 0 GlobusSoapMessageDebugEnter();
366
367 0 if(!instance)
368 {
369 0 goto exit;
370 }
371
372 0 wsu_TimestampType_choice_destroy_contents(instance);
373 0 free(instance);
374
375 0 exit:
376
377 0 GlobusSoapMessageDebugExit();
378 0 }
379
380
381
382 void
383 wsu_TimestampType_choice_destroy_contents(
384 wsu_TimestampType_choice * instance)
385 0 {
386 GlobusFuncName(wsu_TimestampType_choice_destroy_contents);
387 0 GlobusSoapMessageDebugEnter();
388
389 0 switch(instance->type)
390 {
391
392 case wsu_TimestampType_Received:
393
394 0 wsu_ReceivedType_destroy_contents(
395 &instance->value.Received);
396 0 break;
397
398 case wsu_TimestampType_any:
399
400 0 xsd_any_destroy_contents(
401 &instance->value.any);
402 break;
403
404 default:
405 break;
406 }
407
408 0 instance->type = wsu_TimestampType_undefined;
409
410 0 GlobusSoapMessageDebugExit();
411 0 }
412
413 globus_result_t
414 wsu_TimestampType_choice_copy(
415 wsu_TimestampType_choice ** dest_obj,
416 const wsu_TimestampType_choice * src_obj)
417 0 {
418 0 globus_result_t result = GLOBUS_SUCCESS;
419 wsu_TimestampType_choice * instance;
420 GlobusFuncName(wsu_TimestampType_choice_copy);
421
422 0 GlobusSoapMessageDebugEnter();
423
424 0 instance = malloc(sizeof(wsu_TimestampType_choice));
425 0 if (instance == NULL)
426 {
427 0 GlobusSoapMessageDebugExit();
428 0 return GlobusSoapMessageErrorOutOfMemory;
429 }
430
431 0 result = wsu_TimestampType_choice_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
445
446 globus_result_t
447 wsu_TimestampType_choice_copy_contents(
448 wsu_TimestampType_choice * instance,
449 const wsu_TimestampType_choice * src_obj)
450 0 {
451 xsd_QName subelement;
452 0 globus_result_t result = GLOBUS_SUCCESS;
453 GlobusFuncName(wsu_TimestampType_choice_copy_contents);
454
455 0 GlobusSoapMessageDebugEnter();
456
457 0 switch(src_obj->type)
458 {
459
460 case wsu_TimestampType_Received:
461 0 instance->type = wsu_TimestampType_Received;
462 0 result = wsu_ReceivedType_copy_contents(
463 &instance->value.Received,
464 &src_obj->value.Received);
465 0 if(result != GLOBUS_SUCCESS)
466 {
467 0 result = GlobusSoapMessageErrorSerializeFailed(
468 result, NULL, &wsu_TimestampType_choice_qname);
469 0 goto exit;
470 }
471
472 0 break;
473
474 case wsu_TimestampType_any:
475 0 instance->type = wsu_TimestampType_any;
476 0 result = xsd_any_copy_contents(
477 &instance->value.any,
478 &src_obj->value.any);
479 0 if(result != GLOBUS_SUCCESS)
480 {
481 0 result = GlobusSoapMessageErrorSerializeFailed(
482 result, NULL, &wsu_TimestampType_choice_qname);
483 0 goto exit;
484 }
485
486 break;
487
488 default:
489 break;
490 }
491
492 0 exit:
493
494 0 GlobusSoapMessageDebugExit();
495 0 return result;
496 }
497
498
499
500
501
502 globus_result_t
503 wsu_TimestampType_choice_serialize_contents(
504 const xsd_QName * element_qname, /* ignored */
505 const wsu_TimestampType_choice * instance,
506 globus_soap_message_handle_t message_handle,
507 globus_xsd_element_options_t options)
508 0 {
509 xsd_QName subelement;
510 0 globus_result_t result = GLOBUS_SUCCESS;
511 GlobusFuncName(wsu_TimestampType_choice_serialize_contents);
512 0 GlobusSoapMessageDebugEnter();
513
514 0 switch(instance->type)
515 {
516
517 case wsu_TimestampType_Received:
518
519 0 subelement.local = "Received";
520 0 subelement.Namespace = "http://schemas.xmlsoap.org/ws/2002/07/utility";
521 0 result = wsu_ReceivedType_serialize(
522 &subelement,
523 &instance->value.Received,
524 message_handle,
525 options);
526 0 if(result != GLOBUS_SUCCESS)
527 {
528 0 result = GlobusSoapMessageErrorSerializeFailed(
529 result, NULL, &wsu_TimestampType_choice_qname);
530 0 goto exit;
531 }
532
533 0 break;
534
535 case wsu_TimestampType_any:
536
537 0 subelement.local = "any";
538 0 subelement.Namespace = "http://www.w3.org/2001/XMLSchema";
539 0 result = xsd_any_serialize(
540 &subelement,
541 &instance->value.any,
542 message_handle,
543 options);
544 0 if(result != GLOBUS_SUCCESS)
545 {
546 0 result = GlobusSoapMessageErrorSerializeFailed(
547 result, NULL, &wsu_TimestampType_choice_qname);
548 0 goto exit;
549 }
550
551 break;
552
553 default:
554 break;
555 }
556
557 0 exit:
558
559 0 GlobusSoapMessageDebugExit();
560 0 return result;
561 }
562
563
564
565 globus_result_t
566 wsu_TimestampType_choice_serialize(
567 const xsd_QName * element_qname,
568 const wsu_TimestampType_choice * instance,
569 globus_soap_message_handle_t message_handle,
570 globus_xsd_element_options_t options)
571 0 {
572 0 globus_result_t result = GLOBUS_SUCCESS;
573 GlobusFuncName(wsu_TimestampType_choice_serialize);
574 0 GlobusSoapMessageDebugEnter();
575
576 0 result = wsu_TimestampType_choice_serialize_contents(
577 element_qname,
578 instance,
579 message_handle,
580 options);
581 0 if(result != GLOBUS_SUCCESS)
582 {
583 0 result = GlobusSoapMessageErrorSerializeFailed(
584 result, NULL, &wsu_TimestampType_choice_qname);
585 0 goto exit;
586 }
587
588 0 exit:
589 0 GlobusSoapMessageDebugExit();
590 0 return result;
591 }
592
593
594
595
596
597 globus_result_t
598 wsu_TimestampType_choice_deserialize_contents(
599 const xsd_QName * element_qname, /* ignored */
600 wsu_TimestampType_choice * instance,
601 globus_soap_message_handle_t message_handle,
602 globus_xsd_element_options_t options)
603 0 {
604 0 globus_result_t result = GLOBUS_SUCCESS;
605 GlobusFuncName(wsu_TimestampType_choice_deserialize_contents);
606 0 GlobusSoapMessageDebugEnter();
607
608 0 result = wsu_TimestampType_choice_deserialize(
609 NULL,
610 instance,
611 message_handle,
612 options | GLOBUS_XSD_ELEMENT_CONTENTS_ONLY);
613 0 if(result != GLOBUS_SUCCESS)
614 {
615 0 result = GlobusSoapMessageErrorDeserializeFailed(
616 result, element_qname);
617 0 goto exit;
618 }
619
620 0 exit:
621
622 0 GlobusSoapMessageDebugExit();
623 0 return result;
624 }
625
626
627
628 globus_result_t
629 wsu_TimestampType_choice_deserialize(
630 const xsd_QName * element_qname,
631 wsu_TimestampType_choice * instance,
632 globus_soap_message_handle_t message_handle,
633 globus_xsd_element_options_t options)
634 0 {
635 0 globus_result_t result = GLOBUS_SUCCESS;
636 xsd_QName subelement;
637 0 xsd_QName deselem_qname = { NULL, NULL } ;
638 GlobusFuncName(wsu_TimestampType_choice_deserialize);
639 0 GlobusSoapMessageDebugEnter();
640
641 0 xsd_QName_init_contents(&deselem_qname);
642
643 0 result = globus_soap_message_deserialize_element_unknown(
644 message_handle, &deselem_qname);
645 0 if(result != GLOBUS_SUCCESS)
646 {
647 0 result = GlobusSoapMessageErrorDeserializeFailed(
648 result, &wsu_TimestampType_choice_qname);
649 0 goto exit;
650 }
651
652 /*
653 if(globus_soap_message_deserialize_element_is_nil(message_handle))
654 {
655 xsd_QName_destroy_contents(&deselem_qname);
656 result = globus_soap_message_deserialize_element_end(
657 message_handle,
658 element_qname);
659 if(result != GLOBUS_SUCCESS)
660 {
661 result = GlobusSoapMessageErrorDeserializeFailed(
662 result, &wsu_TimestampType_choice_qname);
663 goto exit;
664 }
665 }
666 */
667
668 0 globus_soap_message_deserialize_push_element(message_handle);
669
670 0 subelement.local = "Received";
671 0 subelement.Namespace = "http://schemas.xmlsoap.org/ws/2002/07/utility";
672 0 if(xsd_QName_keyeq((void *)&subelement, (void *)&deselem_qname))
673 {
674 0 instance->type=wsu_TimestampType_Received;
675 0 result = wsu_ReceivedType_deserialize(
676 &subelement,
677 &instance->value.Received,
678 message_handle,
679 options);
680 0 if(result != GLOBUS_SUCCESS)
681 {
682 0 result = GlobusSoapMessageErrorDeserializeFailed(
683 result, &wsu_TimestampType_choice_qname);
684 0 goto Received_destroy;
685 }
686
687 0 goto exit;
688 }
689
690 0 subelement.local = "any";
691
692 0 subelement.Namespace = "##other{http://schemas.xmlsoap.org/ws/2002/07/utility}";
693
694
695 /* try to parse as any element */
696 0 result = xsd_any_deserialize(
697 &subelement,
698 &instance->value.any,
699 message_handle,
700 options);
701 0 if(result != GLOBUS_SUCCESS)
702 {
703 0 result = GlobusSoapMessageErrorDeserializeFailed(
704 result, &wsu_TimestampType_choice_qname);
705 0 goto any_destroy;
706 }
707 else
708 {
709 0 instance->type=wsu_TimestampType_any;
710 0 goto exit;
711 }
712
713 instance->type = wsu_TimestampType_undefined;
714 result = GlobusSoapMessageErrorDeserializeFailed(
715 result, &wsu_TimestampType_choice_qname);
716
717 goto exit;
718
719 0 deserialize_failed:
720
721 0 any_destroy:
722
723 0 Received_destroy:
724
725 0 exit:
726
727 0 xsd_QName_destroy_contents(&deselem_qname);
728
729 0 GlobusSoapMessageDebugExit();
730 0 return result;
731 }
732
733
734
735 globus_result_t
736 wsu_TimestampType_choice_deserialize_pointer(
737 const xsd_QName * element_qname,
738 wsu_TimestampType_choice ** ip,
739 globus_soap_message_handle_t message_handle,
740 globus_xsd_element_options_t options)
741 0 {
742 0 wsu_TimestampType_choice * instance = NULL;
743 0 globus_result_t result = GLOBUS_SUCCESS;
744 xsd_QName subelement;
745 GlobusFuncName(wsu_TimestampType_choice_deserialize_pointer);
746 0 GlobusSoapMessageDebugEnter();
747
748 0 *ip = NULL;
749
750 0 result = wsu_TimestampType_choice_init(&instance);
751 0 if(result != GLOBUS_SUCCESS)
752 {
753 0 result = GlobusSoapMessageErrorDeserializeFailed(
754 result, element_qname);
755 0 goto exit;
756 }
757
758 0 result = wsu_TimestampType_choice_deserialize(
759 element_qname,
760 instance,
761 message_handle,
762 options);
763 0 if(result != GLOBUS_SUCCESS)
764 {
765 0 goto exit;
766 }
767
768 0 *ip = instance;
769
770 0 exit:
771
772 0 GlobusSoapMessageDebugExit();
773 0 return result;
774 }
775
776
777
778 globus_result_t
779 wsu_TimestampType_choice_array_init_contents(
780 wsu_TimestampType_choice_array * array)
781 0 {
782 0 return globus_xsd_generic_array_init_contents(
783 (globus_xsd_generic_array_t *) array,
784 &wsu_TimestampType_choice_array_info);
785 }
786 /* wsu_TimestampType_choice_array_init_contents() */
787
788 globus_result_t
789 wsu_TimestampType_choice_array_init(
790 wsu_TimestampType_choice_array ** arr)
791 0 {
792 0 return globus_xsd_generic_array_init(
793 (globus_xsd_generic_array_t **) arr,
794 &wsu_TimestampType_choice_info);
795 }
796 /* wsu_TimestampType_choice_array_init() */
797
798 void
799 wsu_TimestampType_choice_array_destroy_contents(
800 wsu_TimestampType_choice_array * array)
801 0 {
802 0 globus_xsd_generic_array_destroy_contents(
803 (globus_xsd_generic_array_t *) array);
804 0 }
805 /* wsu_TimestampType_choice_array_destroy_contents() */
806
807 void
808 wsu_TimestampType_choice_array_destroy(
809 wsu_TimestampType_choice_array * array)
810 0 {
811 0 globus_xsd_generic_array_destroy(
812 (globus_xsd_generic_array_t *) array);
813 0 }
814 /* wsu_TimestampType_choice_array_destroy() */
815
816 globus_result_t
817 wsu_TimestampType_choice_array_copy(
818 wsu_TimestampType_choice_array ** dest_arr,
819 const wsu_TimestampType_choice_array * src_arr)
820 0 {
821 0 return globus_xsd_generic_array_copy(
822 (globus_xsd_generic_array_t **) dest_arr,
823 (const globus_xsd_generic_array_t *) src_arr);
824 }
825 /* wsu_TimestampType_choice_array_copy() */
826
827 globus_result_t
828 wsu_TimestampType_choice_array_copy_contents(
829 wsu_TimestampType_choice_array * dest_arr,
830 const wsu_TimestampType_choice_array * src_arr)
831 0 {
832 0 return globus_xsd_generic_array_copy_contents(
833 (globus_xsd_generic_array_t *) dest_arr,
834 (const globus_xsd_generic_array_t *) src_arr);
835 }
836
837 wsu_TimestampType_choice *
838 wsu_TimestampType_choice_array_push(
839 wsu_TimestampType_choice_array * array)
840 0 {
841 /* Some contents initializers don't initialize subelments but to set their
842 * values to be NULL
843 */
844 0 if (array->type_info == NULL)
845 {
846 0 array->type_info = &wsu_TimestampType_choice_info;
847 }
848 0 return globus_xsd_generic_array_push(
849 (globus_xsd_generic_array_t *) array);
850 }
851 /* wsu_TimestampType_choice_array_push() */
852
853 globus_result_t
854 wsu_TimestampType_choice_array_serialize(
855 const xsd_QName * element_qname,
856 const wsu_TimestampType_choice_array * array,
857 globus_soap_message_handle_t message,
858 globus_xsd_element_options_t options)
859 0 {
860 0 return globus_xsd_generic_array_serialize(
861 element_qname,
862 (const globus_xsd_generic_array_t *) array,
863 message,
864 options);
865 }
866 /* wsu_TimestampType_choice_array_serialize() */
867
868 globus_result_t
869 wsu_TimestampType_choice_array_deserialize(
870 const xsd_QName * element_qname,
871 wsu_TimestampType_choice_array * array,
872 globus_soap_message_handle_t message,
873 globus_xsd_element_options_t options)
874 0 {
875 /* Some initializers set the array's contents to NULL */
876 0 if (array->type_info == NULL)
877 {
878 0 array->type_info = &wsu_TimestampType_choice_info;
879 }
880 0 return globus_xsd_generic_array_deserialize(
881 element_qname,
882 (globus_xsd_generic_array_t *) array,
883 message,
884 options);
885 }