~ubuntu-branches/ubuntu/maverick/eucalyptus/maverick

« back to all changes in this revision

Viewing changes to cluster/generated/adb_describeInstancesResponseType.c

  • Committer: Bazaar Package Importer
  • Author(s): Dave Walker (Daviey)
  • Date: 2010-07-21 17:27:10 UTC
  • mfrom: (1.1.38 upstream)
  • Revision ID: james.westby@ubuntu.com-20100721172710-7xv07dmdqgivc3t9
Tags: 2.0~bzr1211-0ubuntu1
* New major upstream version merge, 2.0 (r1211).
* debian/patches/:
  - 01-wsdl-stubs.patch, debian/wsdl.md5sums: wsdl stubs updated.
  - 02-Makefile.patch: Updated to reflect new code layout.
  - 07-local_support_euca_conf-in.patch: Updated to reflect new code layout.
  - 08-ubuntu-default-networking.patch: Refreshed.
  - 09-small-128-192MB.patch: Updated to point to new location.
  - 10-disable-iscsi.patch: Refreshed.
  - 11-state-cleanup-memleakfix.patch: Removed, fixed upstream.
  - 15-fix-default-ramdisk.patch: Updated to point to new location.
  - 16-kvm_libvirt_xml_default_use_kvm.patch: Updated to reflect changes.
  - 17-fix_walrus_OOM_errors.patch: Removed, fixed upstream.
  - 18-priv_security.patch: Updated to reflect upstream changes.
  - 20-brute-force-webui.patch: Updated to reflect upstream changes. 
  - 21-eucalyptus-1.7-with-gwt-1.6.4.patch: New patch, allows 
    eucalyptus-1.7 to be built against gwt 1.6.4. Based on patch courtesy 
    of Dmitrii Zagorodnov, upstream. (LP: #597330)
* debian/eucalyptus-java-common.links: 
  - Changed symlink for groovy, point to groovy.all.jar, making compatiable 
    with groovy versions >1.7. (LP: #595421)
  - Added ant.jar & jetty-rewrite-handler.jar as they are now required.
* debian/control
  - & debian/build-jars: Added libjavassist-java and libjetty-extra-java as 
    build dependencies.
  - Added libjetty-extra-java as a dependency of eucalyptus-java-common
* The binary resulting jar's have been renamed from eucalyptus-*-1.6.2.jar
  to eucalyptus-*-main.jar:    
  - debian/eucalyptus-cc.upstart
  - debian/eucalyptus-cloud.install
  - debian/eucalyptus-common.eucalyptus.upstart
  - debian/eucalyptus-java-common.install
  - debian/eucalyptus-network.upstart
  - debian/eucalyptus-sc.install
  - debian/eucalyptus-walrus.install
* debian/eucalyptus-java-common.install: New upstream jars that have been
  installed:
  - eucalyptus-db-hsqldb-ext-main.jar
  - eucalyptus-component-main.jar
* debian/control:
  - Updated Standards Version to 3.8.4 (no change)
  - Updated the upstream Homepage to: http://open.eucalyptus.com/
  - Changed Vcs-Bzr to reflect new location of Ubuntu hosted development branch.
  - Made the Build Dependency of groovy and the binary eucalyptus-java-common
    package depend on version >=1.7.

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
         */
9
9
 
10
10
        #include "adb_describeInstancesResponseType.h"
11
 
 
 
11
        
12
12
                /*
13
13
                 * This type was generated from the piece of schema that had
14
14
                 * name = describeInstancesResponseType
15
15
                 * Namespace URI = http://eucalyptus.ucsb.edu/
16
16
                 * Namespace Prefix = ns1
17
17
                 */
18
 
 
 
18
           
19
19
 
20
20
 
21
21
        struct adb_describeInstancesResponseType
22
22
        {
23
23
            axis2_char_t* property_correlationId;
24
24
 
25
 
 
 
25
                
26
26
                axis2_bool_t is_valid_correlationId;
27
27
 
28
28
 
29
29
            axis2_char_t* property_userId;
30
30
 
31
 
 
 
31
                
32
32
                axis2_bool_t is_valid_userId;
33
33
 
34
34
 
35
35
            axis2_char_t* property_statusMessage;
36
36
 
37
 
 
 
37
                
38
38
                axis2_bool_t is_valid_statusMessage;
39
39
 
40
40
 
41
41
            axis2_bool_t property_return;
42
42
 
43
 
 
 
43
                
44
44
                axis2_bool_t is_valid_return;
45
45
 
46
46
 
47
47
            axutil_array_list_t* property_instances;
48
48
 
49
 
 
 
49
                
50
50
                axis2_bool_t is_valid_instances;
51
51
 
52
52
 
53
 
 
 
53
            
54
54
        };
55
55
 
56
56
 
57
57
       /************************* Private Function prototypes ********************************/
58
 
 
 
58
        
59
59
 
60
60
                axis2_status_t AXIS2_CALL
61
61
                adb_describeInstancesResponseType_set_correlationId_nil(
62
62
                        adb_describeInstancesResponseType_t* _describeInstancesResponseType,
63
63
                        const axutil_env_t *env);
64
 
 
 
64
            
65
65
 
66
66
                axis2_status_t AXIS2_CALL
67
67
                adb_describeInstancesResponseType_set_userId_nil(
68
68
                        adb_describeInstancesResponseType_t* _describeInstancesResponseType,
69
69
                        const axutil_env_t *env);
70
 
 
 
70
            
71
71
 
72
72
                axis2_status_t AXIS2_CALL
73
73
                adb_describeInstancesResponseType_set_return_nil(
74
74
                        adb_describeInstancesResponseType_t* _describeInstancesResponseType,
75
75
                        const axutil_env_t *env);
 
76
            
 
77
                 axis2_status_t AXIS2_CALL
 
78
                 adb_describeInstancesResponseType_set_instances_nil_at(
 
79
                        adb_describeInstancesResponseType_t* _describeInstancesResponseType, 
 
80
                        const axutil_env_t *env, int i);
 
81
                
76
82
 
 
83
                axis2_status_t AXIS2_CALL
 
84
                adb_describeInstancesResponseType_set_instances_nil(
 
85
                        adb_describeInstancesResponseType_t* _describeInstancesResponseType,
 
86
                        const axutil_env_t *env);
 
87
            
77
88
 
78
89
 
79
90
       /************************* Function Implmentations ********************************/
82
93
            const axutil_env_t *env)
83
94
        {
84
95
            adb_describeInstancesResponseType_t *_describeInstancesResponseType = NULL;
85
 
 
 
96
            
86
97
            AXIS2_ENV_CHECK(env, NULL);
87
98
 
88
99
            _describeInstancesResponseType = (adb_describeInstancesResponseType_t *) AXIS2_MALLOC(env->
105
116
            _describeInstancesResponseType->is_valid_return  = AXIS2_FALSE;
106
117
            _describeInstancesResponseType->property_instances  = NULL;
107
118
                  _describeInstancesResponseType->is_valid_instances  = AXIS2_FALSE;
108
 
 
 
119
            
109
120
 
110
121
            return _describeInstancesResponseType;
111
122
        }
115
126
                adb_describeInstancesResponseType_t* _describeInstancesResponseType,
116
127
                const axutil_env_t *env)
117
128
        {
118
 
 
 
129
            
119
130
                int i = 0;
120
131
                int count = 0;
121
132
                void *element = NULL;
122
 
 
 
133
            
123
134
 
124
135
            AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
125
136
            AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
129
140
            adb_describeInstancesResponseType_reset_statusMessage(_describeInstancesResponseType, env);
130
141
            adb_describeInstancesResponseType_reset_return(_describeInstancesResponseType, env);
131
142
            adb_describeInstancesResponseType_reset_instances(_describeInstancesResponseType, env);
132
 
 
 
143
            
133
144
 
134
145
            if(_describeInstancesResponseType)
135
146
            {
140
151
        }
141
152
 
142
153
 
143
 
 
 
154
        
144
155
 
145
156
        axis2_status_t AXIS2_CALL
146
157
        adb_describeInstancesResponseType_deserialize(
151
162
                axis2_bool_t dont_care_minoccurs)
152
163
        {
153
164
          axiom_node_t *parent = *dp_parent;
154
 
 
 
165
          
155
166
          axis2_status_t status = AXIS2_SUCCESS;
156
 
 
 
167
          
157
168
              void *element = NULL;
158
 
 
 
169
           
159
170
             axis2_char_t* text_value = NULL;
160
171
             axutil_qname_t *qname = NULL;
161
 
 
 
172
          
162
173
               int i = 0;
163
174
               axutil_array_list_t *arr_list = NULL;
164
 
 
 
175
            
165
176
               int sequence_broken = 0;
166
177
               axiom_node_t *tmp_node = NULL;
167
 
 
168
 
            axutil_qname_t *element_qname = NULL;
169
 
 
 
178
            
 
179
            axutil_qname_t *element_qname = NULL; 
 
180
            
170
181
               axiom_node_t *first_node = NULL;
171
182
               axis2_bool_t is_early_node_valid = AXIS2_TRUE;
172
183
               axiom_node_t *current_node = NULL;
173
184
               axiom_element_t *current_element = NULL;
174
 
 
 
185
            
175
186
            AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
176
187
            AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
177
188
 
178
 
 
179
 
 
 
189
            
 
190
              
180
191
              while(parent && axiom_node_get_node_type(parent, env) != AXIOM_ELEMENT)
181
192
              {
182
193
                  parent = axiom_node_get_next_sibling(parent, env);
184
195
              if (NULL == parent)
185
196
              {
186
197
                /* This should be checked before everything */
187
 
                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
 
198
                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, 
188
199
                            "Failed in building adb object for describeInstancesResponseType : "
189
200
                            "NULL elemenet can not be passed to deserialize");
190
201
                return AXIS2_FAILURE;
191
202
              }
192
 
 
193
 
 
 
203
              
 
204
                      
194
205
                      first_node = axiom_node_get_first_child(parent, env);
195
 
 
196
 
 
197
 
 
198
 
 
 
206
                      
 
207
                    
 
208
 
 
209
                     
199
210
                     /*
200
211
                      * building correlationId element
201
212
                      */
202
 
 
203
 
 
204
 
 
 
213
                     
 
214
                     
 
215
                     
205
216
                                   current_node = first_node;
206
217
                                   is_early_node_valid = AXIS2_FALSE;
207
 
 
208
 
 
 
218
                                   
 
219
                                   
209
220
                                    while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
210
221
                                    {
211
222
                                        current_node = axiom_node_get_next_sibling(current_node, env);
215
226
                                        current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
216
227
                                        qname = axiom_element_get_qname(current_element, env, current_node);
217
228
                                    }
218
 
 
 
229
                                   
219
230
                                 element_qname = axutil_qname_create(env, "correlationId", "http://eucalyptus.ucsb.edu/", NULL);
220
 
 
221
 
 
222
 
                           if (
 
231
                                 
 
232
 
 
233
                           if ( 
223
234
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
224
235
                           {
225
236
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
226
237
                              {
227
238
                                is_early_node_valid = AXIS2_TRUE;
228
239
                              }
229
 
 
230
 
 
 
240
                              
 
241
                                 
231
242
                                      text_value = axiom_element_get_text(current_element, env, current_node);
232
243
                                      if(text_value != NULL)
233
244
                                      {
234
245
                                            status = adb_describeInstancesResponseType_set_correlationId(_describeInstancesResponseType, env,
235
246
                                                               text_value);
236
247
                                      }
237
 
 
 
248
                                      
238
249
                                      else
239
250
                                      {
240
251
                                            /*
241
252
                                             * axis2_qname_t *qname = NULL;
242
253
                                             * axiom_attribute_t *the_attri = NULL;
243
 
                                             *
 
254
                                             * 
244
255
                                             * qname = axutil_qname_create(env, "nil", "http://www.w3.org/2001/XMLSchema-instance", "xsi");
245
256
                                             * the_attri = axiom_element_get_attribute(current_element, env, qname);
246
257
                                             */
258
269
                                                 axutil_hash_index_t *hi;
259
270
                                                 void *val;
260
271
                                                 const void *key;
261
 
 
262
 
                                                 for (hi = axutil_hash_first(attribute_hash, env); hi; hi = axutil_hash_next(env, hi))
 
272
                                        
 
273
                                                 for (hi = axutil_hash_first(attribute_hash, env); hi; hi = axutil_hash_next(env, hi)) 
263
274
                                                 {
264
275
                                                     axutil_hash_this(hi, &key, NULL, &val);
265
 
 
 
276
                                                     
266
277
                                                     if(strstr((axis2_char_t*)key, "nil|http://www.w3.org/2001/XMLSchema-instance"))
267
278
                                                     {
268
279
                                                         the_attri = (axiom_attribute_t*)val;
293
304
                                                                   "");
294
305
                                            }
295
306
                                      }
296
 
 
 
307
                                      
297
308
                                 if(AXIS2_FAILURE ==  status)
298
309
                                 {
299
310
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for correlationId ");
304
315
                                     return AXIS2_FAILURE;
305
316
                                 }
306
317
                              }
307
 
 
 
318
                           
308
319
                  if(element_qname)
309
320
                  {
310
321
                     axutil_qname_free(element_qname, env);
311
322
                     element_qname = NULL;
312
323
                  }
313
 
 
314
 
 
315
 
 
 
324
                 
 
325
 
 
326
                     
316
327
                     /*
317
328
                      * building userId element
318
329
                      */
319
 
 
320
 
 
321
 
 
 
330
                     
 
331
                     
 
332
                     
322
333
                                    /*
323
334
                                     * because elements are ordered this works fine
324
335
                                     */
325
 
 
326
 
 
 
336
                                  
 
337
                                   
327
338
                                   if(current_node != NULL && is_early_node_valid)
328
339
                                   {
329
340
                                       current_node = axiom_node_get_next_sibling(current_node, env);
330
 
 
331
 
 
 
341
                                       
 
342
                                       
332
343
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
333
344
                                        {
334
345
                                            current_node = axiom_node_get_next_sibling(current_node, env);
338
349
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
339
350
                                            qname = axiom_element_get_qname(current_element, env, current_node);
340
351
                                        }
341
 
 
 
352
                                       
342
353
                                   }
343
354
                                   is_early_node_valid = AXIS2_FALSE;
344
 
 
 
355
                                 
345
356
                                 element_qname = axutil_qname_create(env, "userId", "http://eucalyptus.ucsb.edu/", NULL);
346
 
 
347
 
 
348
 
                           if (
 
357
                                 
 
358
 
 
359
                           if ( 
349
360
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
350
361
                           {
351
362
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
352
363
                              {
353
364
                                is_early_node_valid = AXIS2_TRUE;
354
365
                              }
355
 
 
356
 
 
 
366
                              
 
367
                                 
357
368
                                      text_value = axiom_element_get_text(current_element, env, current_node);
358
369
                                      if(text_value != NULL)
359
370
                                      {
360
371
                                            status = adb_describeInstancesResponseType_set_userId(_describeInstancesResponseType, env,
361
372
                                                               text_value);
362
373
                                      }
363
 
 
 
374
                                      
364
375
                                      else
365
376
                                      {
366
377
                                            /*
367
378
                                             * axis2_qname_t *qname = NULL;
368
379
                                             * axiom_attribute_t *the_attri = NULL;
369
 
                                             *
 
380
                                             * 
370
381
                                             * qname = axutil_qname_create(env, "nil", "http://www.w3.org/2001/XMLSchema-instance", "xsi");
371
382
                                             * the_attri = axiom_element_get_attribute(current_element, env, qname);
372
383
                                             */
384
395
                                                 axutil_hash_index_t *hi;
385
396
                                                 void *val;
386
397
                                                 const void *key;
387
 
 
388
 
                                                 for (hi = axutil_hash_first(attribute_hash, env); hi; hi = axutil_hash_next(env, hi))
 
398
                                        
 
399
                                                 for (hi = axutil_hash_first(attribute_hash, env); hi; hi = axutil_hash_next(env, hi)) 
389
400
                                                 {
390
401
                                                     axutil_hash_this(hi, &key, NULL, &val);
391
 
 
 
402
                                                     
392
403
                                                     if(strstr((axis2_char_t*)key, "nil|http://www.w3.org/2001/XMLSchema-instance"))
393
404
                                                     {
394
405
                                                         the_attri = (axiom_attribute_t*)val;
419
430
                                                                   "");
420
431
                                            }
421
432
                                      }
422
 
 
 
433
                                      
423
434
                                 if(AXIS2_FAILURE ==  status)
424
435
                                 {
425
436
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for userId ");
430
441
                                     return AXIS2_FAILURE;
431
442
                                 }
432
443
                              }
433
 
 
 
444
                           
434
445
                  if(element_qname)
435
446
                  {
436
447
                     axutil_qname_free(element_qname, env);
437
448
                     element_qname = NULL;
438
449
                  }
439
 
 
440
 
 
441
 
 
 
450
                 
 
451
 
 
452
                     
442
453
                     /*
443
454
                      * building statusMessage element
444
455
                      */
445
 
 
446
 
 
447
 
 
 
456
                     
 
457
                     
 
458
                     
448
459
                                    /*
449
460
                                     * because elements are ordered this works fine
450
461
                                     */
451
 
 
452
 
 
 
462
                                  
 
463
                                   
453
464
                                   if(current_node != NULL && is_early_node_valid)
454
465
                                   {
455
466
                                       current_node = axiom_node_get_next_sibling(current_node, env);
456
 
 
457
 
 
 
467
                                       
 
468
                                       
458
469
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
459
470
                                        {
460
471
                                            current_node = axiom_node_get_next_sibling(current_node, env);
464
475
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
465
476
                                            qname = axiom_element_get_qname(current_element, env, current_node);
466
477
                                        }
467
 
 
 
478
                                       
468
479
                                   }
469
480
                                   is_early_node_valid = AXIS2_FALSE;
470
 
 
 
481
                                 
471
482
                                 element_qname = axutil_qname_create(env, "statusMessage", "http://eucalyptus.ucsb.edu/", NULL);
472
 
 
473
 
 
474
 
                           if (
 
483
                                 
 
484
 
 
485
                           if ( 
475
486
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
476
487
                           {
477
488
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
478
489
                              {
479
490
                                is_early_node_valid = AXIS2_TRUE;
480
491
                              }
481
 
 
482
 
 
 
492
                              
 
493
                                 
483
494
                                      text_value = axiom_element_get_text(current_element, env, current_node);
484
495
                                      if(text_value != NULL)
485
496
                                      {
486
497
                                            status = adb_describeInstancesResponseType_set_statusMessage(_describeInstancesResponseType, env,
487
498
                                                               text_value);
488
499
                                      }
489
 
 
 
500
                                      
490
501
                                 if(AXIS2_FAILURE ==  status)
491
502
                                 {
492
503
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for statusMessage ");
497
508
                                     return AXIS2_FAILURE;
498
509
                                 }
499
510
                              }
500
 
 
 
511
                           
501
512
                  if(element_qname)
502
513
                  {
503
514
                     axutil_qname_free(element_qname, env);
504
515
                     element_qname = NULL;
505
516
                  }
506
 
 
507
 
 
508
 
 
 
517
                 
 
518
 
 
519
                     
509
520
                     /*
510
521
                      * building return element
511
522
                      */
512
 
 
513
 
 
514
 
 
 
523
                     
 
524
                     
 
525
                     
515
526
                                    /*
516
527
                                     * because elements are ordered this works fine
517
528
                                     */
518
 
 
519
 
 
 
529
                                  
 
530
                                   
520
531
                                   if(current_node != NULL && is_early_node_valid)
521
532
                                   {
522
533
                                       current_node = axiom_node_get_next_sibling(current_node, env);
523
 
 
524
 
 
 
534
                                       
 
535
                                       
525
536
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
526
537
                                        {
527
538
                                            current_node = axiom_node_get_next_sibling(current_node, env);
531
542
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
532
543
                                            qname = axiom_element_get_qname(current_element, env, current_node);
533
544
                                        }
534
 
 
 
545
                                       
535
546
                                   }
536
547
                                   is_early_node_valid = AXIS2_FALSE;
537
 
 
 
548
                                 
538
549
                                 element_qname = axutil_qname_create(env, "return", "http://eucalyptus.ucsb.edu/", NULL);
539
 
 
540
 
 
541
 
                           if (
 
550
                                 
 
551
 
 
552
                           if ( 
542
553
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
543
554
                           {
544
555
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
545
556
                              {
546
557
                                is_early_node_valid = AXIS2_TRUE;
547
558
                              }
548
 
 
549
 
 
 
559
                              
 
560
                                 
550
561
                                      text_value = axiom_element_get_text(current_element, env, current_node);
551
562
                                      if(text_value != NULL)
552
563
                                      {
561
572
                                                                      AXIS2_FALSE);
562
573
                                            }
563
574
                                      }
564
 
 
 
575
                                      
565
576
                                      else
566
577
                                      {
567
578
                                          AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element return");
568
579
                                          status = AXIS2_FAILURE;
569
580
                                      }
570
 
 
 
581
                                      
571
582
                                 if(AXIS2_FAILURE ==  status)
572
583
                                 {
573
584
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for return ");
578
589
                                     return AXIS2_FAILURE;
579
590
                                 }
580
591
                              }
581
 
 
 
592
                           
582
593
                  if(element_qname)
583
594
                  {
584
595
                     axutil_qname_free(element_qname, env);
585
596
                     element_qname = NULL;
586
597
                  }
587
 
 
 
598
                 
588
599
                    /*
589
600
                     * building instances array
590
601
                     */
591
602
                       arr_list = axutil_array_list_create(env, 10);
592
 
 
593
 
 
594
 
 
 
603
                   
 
604
 
 
605
                     
595
606
                     /*
596
607
                      * building instances element
597
608
                      */
598
 
 
599
 
 
600
 
 
 
609
                     
 
610
                     
 
611
                     
601
612
                                    element_qname = axutil_qname_create(env, "instances", "http://eucalyptus.ucsb.edu/", NULL);
602
 
 
603
 
 
604
 
                               for (i = 0, sequence_broken = 0, current_node = (is_early_node_valid?axiom_node_get_next_sibling(current_node, env):current_node); !sequence_broken && current_node != NULL;)
605
 
 
 
613
                                  
 
614
                               
 
615
                               for (i = 0, sequence_broken = 0, current_node = (is_early_node_valid?axiom_node_get_next_sibling(current_node, env):current_node); !sequence_broken && current_node != NULL;) 
 
616
                                             
606
617
                               {
607
618
                                  if(axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
608
619
                                  {
610
621
                                     is_early_node_valid = AXIS2_FALSE;
611
622
                                     continue;
612
623
                                  }
613
 
 
 
624
                                  
614
625
                                  current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
615
626
                                  qname = axiom_element_get_qname(current_element, env, current_node);
616
627
 
617
628
                                  if (axutil_qname_equals(element_qname, env, qname))
618
629
                                  {
619
 
 
 
630
                                  
620
631
                                      is_early_node_valid = AXIS2_TRUE;
621
 
 
622
 
 
 
632
                                      
 
633
                                     
623
634
                                          element = (void*)adb_ccInstanceType_create(env);
624
 
 
 
635
                                          
625
636
                                          status =  adb_ccInstanceType_deserialize((adb_ccInstanceType_t*)element, env,
626
637
                                                                                 &current_node, &is_early_node_valid, AXIS2_FALSE);
627
 
 
 
638
                                          
628
639
                                          if(AXIS2_FAILURE ==  status)
629
640
                                          {
630
641
                                              AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in building element instances ");
633
644
                                          {
634
645
                                            axutil_array_list_add_at(arr_list, env, i, element);
635
646
                                          }
636
 
 
 
647
                                        
637
648
                                     if(AXIS2_FAILURE ==  status)
638
649
                                     {
639
650
                                         AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for instances ");
656
667
                                      is_early_node_valid = AXIS2_FALSE;
657
668
                                      sequence_broken = 1;
658
669
                                  }
659
 
 
 
670
                                  
660
671
                               }
661
672
 
662
 
 
 
673
                               
663
674
                                   if (i < 0)
664
675
                                   {
665
676
                                     /* found element out of order */
674
685
                                     }
675
686
                                     return AXIS2_FAILURE;
676
687
                                   }
677
 
 
 
688
                               
678
689
 
679
690
                               if(0 == axutil_array_list_size(arr_list,env))
680
691
                               {
686
697
                                                                   arr_list);
687
698
                               }
688
699
 
689
 
 
 
700
                             
690
701
                  if(element_qname)
691
702
                  {
692
703
                     axutil_qname_free(element_qname, env);
693
704
                     element_qname = NULL;
694
705
                  }
695
 
 
 
706
                 
696
707
          return status;
697
708
       }
698
709
 
699
710
          axis2_bool_t AXIS2_CALL
700
711
          adb_describeInstancesResponseType_is_particle()
701
712
          {
702
 
 
 
713
            
703
714
                 return AXIS2_FALSE;
704
 
 
 
715
              
705
716
          }
706
717
 
707
718
 
711
722
                    const axutil_env_t *env, axiom_element_t *parent_element,
712
723
                    axutil_hash_t *namespaces, int *next_ns_index)
713
724
          {
714
 
 
 
725
            
715
726
                  /* Here this is an empty function, Nothing to declare */
716
 
 
 
727
                 
717
728
          }
718
729
 
719
 
 
720
 
 
 
730
        
 
731
        
721
732
        axiom_node_t* AXIS2_CALL
722
733
        adb_describeInstancesResponseType_serialize(
723
734
                adb_describeInstancesResponseType_t* _describeInstancesResponseType,
724
735
                const axutil_env_t *env, axiom_node_t *parent, axiom_element_t *parent_element, int parent_tag_closed, axutil_hash_t *namespaces, int *next_ns_index)
725
736
        {
726
 
 
727
 
 
 
737
            
 
738
            
728
739
             axis2_char_t *string_to_stream;
729
 
 
730
 
 
 
740
            
 
741
         
731
742
         axiom_node_t *current_node = NULL;
732
743
         int tag_closed = 0;
733
744
 
734
 
 
735
 
 
 
745
         
 
746
         
736
747
                axiom_namespace_t *ns1 = NULL;
737
748
 
738
749
                axis2_char_t *qname_uri = NULL;
739
750
                axis2_char_t *qname_prefix = NULL;
740
751
                axis2_char_t *p_prefix = NULL;
741
752
                axis2_bool_t ns_already_defined;
742
 
 
 
753
            
743
754
               int i = 0;
744
755
               int count = 0;
745
756
               void *element = NULL;
746
 
 
 
757
             
747
758
                    axis2_char_t *text_value_1;
748
759
                    axis2_char_t *text_value_1_temp;
749
 
 
 
760
                    
750
761
                    axis2_char_t *text_value_2;
751
762
                    axis2_char_t *text_value_2_temp;
752
 
 
 
763
                    
753
764
                    axis2_char_t *text_value_3;
754
765
                    axis2_char_t *text_value_3_temp;
755
 
 
 
766
                    
756
767
                    axis2_char_t text_value_4[64];
757
 
 
 
768
                    
758
769
                    axis2_char_t text_value_5[64];
759
 
 
 
770
                    
760
771
               axis2_char_t *start_input_str = NULL;
761
772
               axis2_char_t *end_input_str = NULL;
762
773
               unsigned int start_input_str_len = 0;
763
774
               unsigned int end_input_str_len = 0;
764
 
 
765
 
 
 
775
            
 
776
            
766
777
               axiom_data_source_t *data_source = NULL;
767
778
               axutil_stream_t *stream = NULL;
768
779
 
769
 
 
 
780
            
770
781
 
771
782
            AXIS2_ENV_CHECK(env, NULL);
772
783
            AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, NULL);
773
 
 
774
 
 
 
784
            
 
785
            
775
786
                    current_node = parent;
776
787
                    data_source = (axiom_data_source_t *)axiom_node_get_data_element(current_node, env);
777
788
                    if (!data_source)
779
790
                    stream = axiom_data_source_get_stream(data_source, env); /* assume parent is of type data source */
780
791
                    if (!stream)
781
792
                        return NULL;
782
 
 
 
793
                  
783
794
            if(!parent_tag_closed)
784
795
            {
785
 
 
786
 
              string_to_stream = ">";
 
796
            
 
797
              string_to_stream = ">"; 
787
798
              axutil_stream_write(stream, env, string_to_stream, axutil_strlen(string_to_stream));
788
799
              tag_closed = 1;
789
 
 
 
800
            
790
801
            }
791
 
 
 
802
            
792
803
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
793
804
                       {
794
805
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
795
806
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
796
807
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
797
 
 
 
808
                           
798
809
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
799
810
                                            "http://eucalyptus.ucsb.edu/",
800
811
                                            p_prefix));
801
812
                       }
802
 
 
 
813
                      
803
814
 
804
815
                   if (!_describeInstancesResponseType->is_valid_correlationId)
805
816
                   {
806
 
 
 
817
                      
807
818
                           /* no need to complain for minoccurs=0 element */
808
 
 
809
 
 
 
819
                            
 
820
                          
810
821
                   }
811
822
                   else
812
823
                   {
813
824
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
814
 
                                 (4 + axutil_strlen(p_prefix) +
815
 
                                  axutil_strlen("correlationId")));
816
 
 
 
825
                                 (4 + axutil_strlen(p_prefix) + 
 
826
                                  axutil_strlen("correlationId"))); 
 
827
                                 
817
828
                                 /* axutil_strlen("<:>") + 1 = 4 */
818
829
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
819
830
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("correlationId")));
820
831
                                  /* axutil_strlen("</:>") + 1 = 5 */
821
 
 
822
 
 
823
 
 
824
 
 
825
 
 
826
 
 
 
832
                                  
 
833
                     
 
834
 
 
835
                   
 
836
                   
 
837
                     
827
838
                     /*
828
839
                      * parsing correlationId element
829
840
                      */
830
841
 
831
 
 
832
 
 
 
842
                    
 
843
                    
833
844
                            sprintf(start_input_str, "<%s%scorrelationId>",
834
845
                                 p_prefix?p_prefix:"",
835
846
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
836
 
 
 
847
                            
837
848
                        start_input_str_len = axutil_strlen(start_input_str);
838
849
                        sprintf(end_input_str, "</%s%scorrelationId>",
839
850
                                 p_prefix?p_prefix:"",
840
851
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
841
852
                        end_input_str_len = axutil_strlen(end_input_str);
842
 
 
 
853
                    
843
854
                           text_value_1 = _describeInstancesResponseType->property_correlationId;
844
 
 
 
855
                           
845
856
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
846
 
 
847
 
 
 
857
                           
 
858
                            
848
859
                           text_value_1_temp = axutil_xml_quote_string(env, text_value_1, AXIS2_TRUE);
849
860
                           if (text_value_1_temp)
850
861
                           {
855
866
                           {
856
867
                               axutil_stream_write(stream, env, text_value_1, axutil_strlen(text_value_1));
857
868
                           }
858
 
 
 
869
                           
859
870
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
860
 
 
861
 
 
 
871
                           
 
872
                     
862
873
                     AXIS2_FREE(env->allocator,start_input_str);
863
874
                     AXIS2_FREE(env->allocator,end_input_str);
864
 
                 }
865
 
 
866
 
 
 
875
                 } 
 
876
 
 
877
                 
867
878
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
868
879
                       {
869
880
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
870
881
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
871
882
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
872
 
 
 
883
                           
873
884
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
874
885
                                            "http://eucalyptus.ucsb.edu/",
875
886
                                            p_prefix));
876
887
                       }
877
 
 
 
888
                      
878
889
 
879
890
                   if (!_describeInstancesResponseType->is_valid_userId)
880
891
                   {
881
 
 
 
892
                      
882
893
                           /* no need to complain for minoccurs=0 element */
883
 
 
884
 
 
 
894
                            
 
895
                          
885
896
                   }
886
897
                   else
887
898
                   {
888
899
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
889
 
                                 (4 + axutil_strlen(p_prefix) +
890
 
                                  axutil_strlen("userId")));
891
 
 
 
900
                                 (4 + axutil_strlen(p_prefix) + 
 
901
                                  axutil_strlen("userId"))); 
 
902
                                 
892
903
                                 /* axutil_strlen("<:>") + 1 = 4 */
893
904
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
894
905
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("userId")));
895
906
                                  /* axutil_strlen("</:>") + 1 = 5 */
896
 
 
897
 
 
898
 
 
899
 
 
900
 
 
901
 
 
 
907
                                  
 
908
                     
 
909
 
 
910
                   
 
911
                   
 
912
                     
902
913
                     /*
903
914
                      * parsing userId element
904
915
                      */
905
916
 
906
 
 
907
 
 
 
917
                    
 
918
                    
908
919
                            sprintf(start_input_str, "<%s%suserId>",
909
920
                                 p_prefix?p_prefix:"",
910
921
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
911
 
 
 
922
                            
912
923
                        start_input_str_len = axutil_strlen(start_input_str);
913
924
                        sprintf(end_input_str, "</%s%suserId>",
914
925
                                 p_prefix?p_prefix:"",
915
926
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
916
927
                        end_input_str_len = axutil_strlen(end_input_str);
917
 
 
 
928
                    
918
929
                           text_value_2 = _describeInstancesResponseType->property_userId;
919
 
 
 
930
                           
920
931
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
921
 
 
922
 
 
 
932
                           
 
933
                            
923
934
                           text_value_2_temp = axutil_xml_quote_string(env, text_value_2, AXIS2_TRUE);
924
935
                           if (text_value_2_temp)
925
936
                           {
930
941
                           {
931
942
                               axutil_stream_write(stream, env, text_value_2, axutil_strlen(text_value_2));
932
943
                           }
933
 
 
 
944
                           
934
945
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
935
 
 
936
 
 
 
946
                           
 
947
                     
937
948
                     AXIS2_FREE(env->allocator,start_input_str);
938
949
                     AXIS2_FREE(env->allocator,end_input_str);
939
 
                 }
940
 
 
941
 
 
 
950
                 } 
 
951
 
 
952
                 
942
953
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
943
954
                       {
944
955
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
945
956
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
946
957
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
947
 
 
 
958
                           
948
959
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
949
960
                                            "http://eucalyptus.ucsb.edu/",
950
961
                                            p_prefix));
951
962
                       }
952
 
 
 
963
                      
953
964
 
954
965
                   if (!_describeInstancesResponseType->is_valid_statusMessage)
955
966
                   {
956
 
 
 
967
                      
957
968
                           /* no need to complain for minoccurs=0 element */
958
 
 
959
 
 
 
969
                            
 
970
                          
960
971
                   }
961
972
                   else
962
973
                   {
963
974
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
964
 
                                 (4 + axutil_strlen(p_prefix) +
965
 
                                  axutil_strlen("statusMessage")));
966
 
 
 
975
                                 (4 + axutil_strlen(p_prefix) + 
 
976
                                  axutil_strlen("statusMessage"))); 
 
977
                                 
967
978
                                 /* axutil_strlen("<:>") + 1 = 4 */
968
979
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
969
980
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("statusMessage")));
970
981
                                  /* axutil_strlen("</:>") + 1 = 5 */
971
 
 
972
 
 
973
 
 
974
 
 
975
 
 
976
 
 
 
982
                                  
 
983
                     
 
984
 
 
985
                   
 
986
                   
 
987
                     
977
988
                     /*
978
989
                      * parsing statusMessage element
979
990
                      */
980
991
 
981
 
 
982
 
 
 
992
                    
 
993
                    
983
994
                            sprintf(start_input_str, "<%s%sstatusMessage>",
984
995
                                 p_prefix?p_prefix:"",
985
996
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
986
 
 
 
997
                            
987
998
                        start_input_str_len = axutil_strlen(start_input_str);
988
999
                        sprintf(end_input_str, "</%s%sstatusMessage>",
989
1000
                                 p_prefix?p_prefix:"",
990
1001
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
991
1002
                        end_input_str_len = axutil_strlen(end_input_str);
992
 
 
 
1003
                    
993
1004
                           text_value_3 = _describeInstancesResponseType->property_statusMessage;
994
 
 
 
1005
                           
995
1006
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
996
 
 
997
 
 
 
1007
                           
 
1008
                            
998
1009
                           text_value_3_temp = axutil_xml_quote_string(env, text_value_3, AXIS2_TRUE);
999
1010
                           if (text_value_3_temp)
1000
1011
                           {
1005
1016
                           {
1006
1017
                               axutil_stream_write(stream, env, text_value_3, axutil_strlen(text_value_3));
1007
1018
                           }
1008
 
 
 
1019
                           
1009
1020
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
1010
 
 
1011
 
 
 
1021
                           
 
1022
                     
1012
1023
                     AXIS2_FREE(env->allocator,start_input_str);
1013
1024
                     AXIS2_FREE(env->allocator,end_input_str);
1014
 
                 }
1015
 
 
1016
 
 
 
1025
                 } 
 
1026
 
 
1027
                 
1017
1028
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
1018
1029
                       {
1019
1030
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
1020
1031
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
1021
1032
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
1022
 
 
 
1033
                           
1023
1034
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
1024
1035
                                            "http://eucalyptus.ucsb.edu/",
1025
1036
                                            p_prefix));
1026
1037
                       }
1027
 
 
 
1038
                      
1028
1039
 
1029
1040
                   if (!_describeInstancesResponseType->is_valid_return)
1030
1041
                   {
1031
 
 
 
1042
                      
1032
1043
                           /* no need to complain for minoccurs=0 element */
1033
 
 
1034
 
 
 
1044
                            
 
1045
                          
1035
1046
                   }
1036
1047
                   else
1037
1048
                   {
1038
1049
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1039
 
                                 (4 + axutil_strlen(p_prefix) +
1040
 
                                  axutil_strlen("return")));
1041
 
 
 
1050
                                 (4 + axutil_strlen(p_prefix) + 
 
1051
                                  axutil_strlen("return"))); 
 
1052
                                 
1042
1053
                                 /* axutil_strlen("<:>") + 1 = 4 */
1043
1054
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1044
1055
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("return")));
1045
1056
                                  /* axutil_strlen("</:>") + 1 = 5 */
1046
 
 
1047
 
 
1048
 
 
1049
 
 
1050
 
 
1051
 
 
 
1057
                                  
 
1058
                     
 
1059
 
 
1060
                   
 
1061
                   
 
1062
                     
1052
1063
                     /*
1053
1064
                      * parsing return element
1054
1065
                      */
1055
1066
 
1056
 
 
1057
 
 
 
1067
                    
 
1068
                    
1058
1069
                            sprintf(start_input_str, "<%s%sreturn>",
1059
1070
                                 p_prefix?p_prefix:"",
1060
1071
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1061
 
 
 
1072
                            
1062
1073
                        start_input_str_len = axutil_strlen(start_input_str);
1063
1074
                        sprintf(end_input_str, "</%s%sreturn>",
1064
1075
                                 p_prefix?p_prefix:"",
1065
1076
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1066
1077
                        end_input_str_len = axutil_strlen(end_input_str);
1067
 
 
 
1078
                    
1068
1079
                           strcpy(text_value_4, (_describeInstancesResponseType->property_return)?"true":"false");
1069
 
 
 
1080
                           
1070
1081
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
1071
 
 
 
1082
                           
1072
1083
                           axutil_stream_write(stream, env, text_value_4, axutil_strlen(text_value_4));
1073
 
 
 
1084
                           
1074
1085
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
1075
 
 
1076
 
 
 
1086
                           
 
1087
                     
1077
1088
                     AXIS2_FREE(env->allocator,start_input_str);
1078
1089
                     AXIS2_FREE(env->allocator,end_input_str);
1079
 
                 }
1080
 
 
1081
 
 
 
1090
                 } 
 
1091
 
 
1092
                 
1082
1093
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
1083
1094
                       {
1084
1095
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
1085
1096
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
1086
1097
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
1087
 
 
 
1098
                           
1088
1099
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
1089
1100
                                            "http://eucalyptus.ucsb.edu/",
1090
1101
                                            p_prefix));
1091
1102
                       }
1092
 
 
 
1103
                      
1093
1104
 
1094
1105
                   if (!_describeInstancesResponseType->is_valid_instances)
1095
1106
                   {
1096
 
 
 
1107
                      
1097
1108
                           /* no need to complain for minoccurs=0 element */
1098
 
 
1099
 
 
 
1109
                            
 
1110
                          
1100
1111
                   }
1101
1112
                   else
1102
1113
                   {
1103
1114
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1104
 
                                 (4 + axutil_strlen(p_prefix) +
1105
 
                                  axutil_strlen("instances")));
1106
 
 
 
1115
                                 (4 + axutil_strlen(p_prefix) + 
 
1116
                                  axutil_strlen("instances"))); 
 
1117
                                 
1107
1118
                                 /* axutil_strlen("<:>") + 1 = 4 */
1108
1119
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1109
1120
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("instances")));
1110
1121
                                  /* axutil_strlen("</:>") + 1 = 5 */
1111
 
 
1112
 
 
1113
 
 
1114
 
 
1115
 
 
 
1122
                                  
 
1123
                     
 
1124
 
 
1125
                   
 
1126
                   
1116
1127
                     /*
1117
1128
                      * Parsing instances array
1118
1129
                      */
1119
1130
                     if (_describeInstancesResponseType->property_instances != NULL)
1120
1131
                     {
1121
 
 
 
1132
                        
1122
1133
 
1123
1134
                            sprintf(start_input_str, "<%s%sinstances",
1124
1135
                                 p_prefix?p_prefix:"",
1125
1136
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1126
 
 
 
1137
                            
1127
1138
                         start_input_str_len = axutil_strlen(start_input_str);
1128
1139
 
1129
1140
                         sprintf(end_input_str, "</%s%sinstances>",
1136
1147
                         {
1137
1148
                            element = axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i);
1138
1149
 
1139
 
                            if(NULL == element)
 
1150
                            if(NULL == element) 
1140
1151
                            {
1141
1152
                                continue;
1142
1153
                            }
1143
 
 
1144
 
 
 
1154
                    
 
1155
                     
1145
1156
                     /*
1146
1157
                      * parsing instances element
1147
1158
                      */
1148
1159
 
1149
 
 
1150
 
 
 
1160
                    
 
1161
                     
1151
1162
                            if(!adb_ccInstanceType_is_particle())
1152
1163
                            {
1153
1164
                                axutil_stream_write(stream, env, start_input_str, start_input_str_len);
1154
1165
                            }
1155
 
 
1156
 
                            adb_ccInstanceType_serialize((adb_ccInstanceType_t*)element,
 
1166
                            
 
1167
                            adb_ccInstanceType_serialize((adb_ccInstanceType_t*)element, 
1157
1168
                                                                                 env, current_node, parent_element,
1158
1169
                                                                                 adb_ccInstanceType_is_particle() || AXIS2_FALSE, namespaces, next_ns_index);
1159
 
 
 
1170
                            
1160
1171
                            if(!adb_ccInstanceType_is_particle())
1161
1172
                            {
1162
1173
                                axutil_stream_write(stream, env, end_input_str, end_input_str_len);
1163
1174
                            }
1164
 
 
 
1175
                            
1165
1176
                         }
1166
1177
                     }
1167
 
 
1168
 
 
 
1178
                   
 
1179
                     
1169
1180
                     AXIS2_FREE(env->allocator,start_input_str);
1170
1181
                     AXIS2_FREE(env->allocator,end_input_str);
1171
 
                 }
1172
 
 
1173
 
 
 
1182
                 } 
 
1183
 
 
1184
                 
1174
1185
 
1175
1186
            return parent;
1176
1187
        }
1177
1188
 
1178
1189
 
1179
 
 
 
1190
        
1180
1191
 
1181
1192
            /**
1182
1193
             * getter for correlationId.
1186
1197
                    adb_describeInstancesResponseType_t* _describeInstancesResponseType,
1187
1198
                    const axutil_env_t *env)
1188
1199
             {
1189
 
 
 
1200
                
1190
1201
                    AXIS2_ENV_CHECK(env, NULL);
1191
1202
                    AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, NULL);
1192
 
 
 
1203
                  
1193
1204
 
1194
1205
                return _describeInstancesResponseType->property_correlationId;
1195
1206
             }
1203
1214
                    const axutil_env_t *env,
1204
1215
                    const axis2_char_t*  arg_correlationId)
1205
1216
             {
1206
 
 
 
1217
                
1207
1218
 
1208
1219
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1209
1220
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1210
 
 
 
1221
                
1211
1222
                if(_describeInstancesResponseType->is_valid_correlationId &&
1212
1223
                        arg_correlationId == _describeInstancesResponseType->property_correlationId)
1213
1224
                {
1214
 
 
1215
 
                    return AXIS2_SUCCESS;
 
1225
                    
 
1226
                    return AXIS2_SUCCESS; 
1216
1227
                }
1217
1228
 
1218
1229
                adb_describeInstancesResponseType_reset_correlationId(_describeInstancesResponseType, env);
1219
1230
 
1220
 
 
 
1231
                
1221
1232
                if(NULL == arg_correlationId)
1222
1233
                {
1223
1234
                    /* We are already done */
1230
1241
                            return AXIS2_FAILURE;
1231
1242
                        }
1232
1243
                        _describeInstancesResponseType->is_valid_correlationId = AXIS2_TRUE;
1233
 
 
 
1244
                    
1234
1245
                return AXIS2_SUCCESS;
1235
1246
             }
1236
1247
 
1237
 
 
 
1248
             
1238
1249
 
1239
1250
           /**
1240
1251
            * resetter for correlationId
1250
1261
 
1251
1262
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1252
1263
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1253
 
 
1254
 
 
1255
 
 
1256
 
 
1257
 
 
 
1264
               
 
1265
 
 
1266
               
 
1267
            
 
1268
                
1258
1269
                if(_describeInstancesResponseType->property_correlationId != NULL)
1259
1270
                {
1260
 
 
1261
 
 
 
1271
                   
 
1272
                   
1262
1273
                        AXIS2_FREE(env-> allocator, _describeInstancesResponseType->property_correlationId);
1263
1274
                     _describeInstancesResponseType->property_correlationId = NULL;
1264
1275
                }
1265
 
 
1266
 
 
1267
 
 
1268
 
                _describeInstancesResponseType->is_valid_correlationId = AXIS2_FALSE;
 
1276
            
 
1277
                
 
1278
                
 
1279
                _describeInstancesResponseType->is_valid_correlationId = AXIS2_FALSE; 
1269
1280
               return AXIS2_SUCCESS;
1270
1281
           }
1271
1282
 
1279
1290
           {
1280
1291
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1281
1292
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_TRUE);
1282
 
 
 
1293
               
1283
1294
               return !_describeInstancesResponseType->is_valid_correlationId;
1284
1295
           }
1285
1296
 
1294
1305
               return adb_describeInstancesResponseType_reset_correlationId(_describeInstancesResponseType, env);
1295
1306
           }
1296
1307
 
1297
 
 
 
1308
           
1298
1309
 
1299
1310
            /**
1300
1311
             * getter for userId.
1304
1315
                    adb_describeInstancesResponseType_t* _describeInstancesResponseType,
1305
1316
                    const axutil_env_t *env)
1306
1317
             {
1307
 
 
 
1318
                
1308
1319
                    AXIS2_ENV_CHECK(env, NULL);
1309
1320
                    AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, NULL);
1310
 
 
 
1321
                  
1311
1322
 
1312
1323
                return _describeInstancesResponseType->property_userId;
1313
1324
             }
1321
1332
                    const axutil_env_t *env,
1322
1333
                    const axis2_char_t*  arg_userId)
1323
1334
             {
1324
 
 
 
1335
                
1325
1336
 
1326
1337
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1327
1338
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1328
 
 
 
1339
                
1329
1340
                if(_describeInstancesResponseType->is_valid_userId &&
1330
1341
                        arg_userId == _describeInstancesResponseType->property_userId)
1331
1342
                {
1332
 
 
1333
 
                    return AXIS2_SUCCESS;
 
1343
                    
 
1344
                    return AXIS2_SUCCESS; 
1334
1345
                }
1335
1346
 
1336
1347
                adb_describeInstancesResponseType_reset_userId(_describeInstancesResponseType, env);
1337
1348
 
1338
 
 
 
1349
                
1339
1350
                if(NULL == arg_userId)
1340
1351
                {
1341
1352
                    /* We are already done */
1348
1359
                            return AXIS2_FAILURE;
1349
1360
                        }
1350
1361
                        _describeInstancesResponseType->is_valid_userId = AXIS2_TRUE;
1351
 
 
 
1362
                    
1352
1363
                return AXIS2_SUCCESS;
1353
1364
             }
1354
1365
 
1355
 
 
 
1366
             
1356
1367
 
1357
1368
           /**
1358
1369
            * resetter for userId
1368
1379
 
1369
1380
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1370
1381
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1371
 
 
1372
 
 
1373
 
 
1374
 
 
1375
 
 
 
1382
               
 
1383
 
 
1384
               
 
1385
            
 
1386
                
1376
1387
                if(_describeInstancesResponseType->property_userId != NULL)
1377
1388
                {
1378
 
 
1379
 
 
 
1389
                   
 
1390
                   
1380
1391
                        AXIS2_FREE(env-> allocator, _describeInstancesResponseType->property_userId);
1381
1392
                     _describeInstancesResponseType->property_userId = NULL;
1382
1393
                }
1383
 
 
1384
 
 
1385
 
 
1386
 
                _describeInstancesResponseType->is_valid_userId = AXIS2_FALSE;
 
1394
            
 
1395
                
 
1396
                
 
1397
                _describeInstancesResponseType->is_valid_userId = AXIS2_FALSE; 
1387
1398
               return AXIS2_SUCCESS;
1388
1399
           }
1389
1400
 
1397
1408
           {
1398
1409
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1399
1410
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_TRUE);
1400
 
 
 
1411
               
1401
1412
               return !_describeInstancesResponseType->is_valid_userId;
1402
1413
           }
1403
1414
 
1412
1423
               return adb_describeInstancesResponseType_reset_userId(_describeInstancesResponseType, env);
1413
1424
           }
1414
1425
 
1415
 
 
 
1426
           
1416
1427
 
1417
1428
            /**
1418
1429
             * getter for statusMessage.
1422
1433
                    adb_describeInstancesResponseType_t* _describeInstancesResponseType,
1423
1434
                    const axutil_env_t *env)
1424
1435
             {
1425
 
 
 
1436
                
1426
1437
                    AXIS2_ENV_CHECK(env, NULL);
1427
1438
                    AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, NULL);
1428
 
 
 
1439
                  
1429
1440
 
1430
1441
                return _describeInstancesResponseType->property_statusMessage;
1431
1442
             }
1439
1450
                    const axutil_env_t *env,
1440
1451
                    const axis2_char_t*  arg_statusMessage)
1441
1452
             {
1442
 
 
 
1453
                
1443
1454
 
1444
1455
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1445
1456
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1446
 
 
 
1457
                
1447
1458
                if(_describeInstancesResponseType->is_valid_statusMessage &&
1448
1459
                        arg_statusMessage == _describeInstancesResponseType->property_statusMessage)
1449
1460
                {
1450
 
 
1451
 
                    return AXIS2_SUCCESS;
 
1461
                    
 
1462
                    return AXIS2_SUCCESS; 
1452
1463
                }
1453
1464
 
1454
1465
                adb_describeInstancesResponseType_reset_statusMessage(_describeInstancesResponseType, env);
1455
1466
 
1456
 
 
 
1467
                
1457
1468
                if(NULL == arg_statusMessage)
1458
1469
                {
1459
1470
                    /* We are already done */
1466
1477
                            return AXIS2_FAILURE;
1467
1478
                        }
1468
1479
                        _describeInstancesResponseType->is_valid_statusMessage = AXIS2_TRUE;
1469
 
 
 
1480
                    
1470
1481
                return AXIS2_SUCCESS;
1471
1482
             }
1472
1483
 
1473
 
 
 
1484
             
1474
1485
 
1475
1486
           /**
1476
1487
            * resetter for statusMessage
1486
1497
 
1487
1498
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1488
1499
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1489
 
 
1490
 
 
1491
 
 
1492
 
 
1493
 
 
 
1500
               
 
1501
 
 
1502
               
 
1503
            
 
1504
                
1494
1505
                if(_describeInstancesResponseType->property_statusMessage != NULL)
1495
1506
                {
1496
 
 
1497
 
 
 
1507
                   
 
1508
                   
1498
1509
                        AXIS2_FREE(env-> allocator, _describeInstancesResponseType->property_statusMessage);
1499
1510
                     _describeInstancesResponseType->property_statusMessage = NULL;
1500
1511
                }
1501
 
 
1502
 
 
1503
 
 
1504
 
                _describeInstancesResponseType->is_valid_statusMessage = AXIS2_FALSE;
 
1512
            
 
1513
                
 
1514
                
 
1515
                _describeInstancesResponseType->is_valid_statusMessage = AXIS2_FALSE; 
1505
1516
               return AXIS2_SUCCESS;
1506
1517
           }
1507
1518
 
1515
1526
           {
1516
1527
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1517
1528
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_TRUE);
1518
 
 
 
1529
               
1519
1530
               return !_describeInstancesResponseType->is_valid_statusMessage;
1520
1531
           }
1521
1532
 
1530
1541
               return adb_describeInstancesResponseType_reset_statusMessage(_describeInstancesResponseType, env);
1531
1542
           }
1532
1543
 
1533
 
 
 
1544
           
1534
1545
 
1535
1546
            /**
1536
1547
             * getter for return.
1540
1551
                    adb_describeInstancesResponseType_t* _describeInstancesResponseType,
1541
1552
                    const axutil_env_t *env)
1542
1553
             {
1543
 
 
 
1554
                
1544
1555
                    AXIS2_ENV_CHECK(env, (axis2_bool_t)0);
1545
1556
                    AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, (axis2_bool_t)0);
1546
 
 
 
1557
                  
1547
1558
 
1548
1559
                return _describeInstancesResponseType->property_return;
1549
1560
             }
1557
1568
                    const axutil_env_t *env,
1558
1569
                    axis2_bool_t  arg_return)
1559
1570
             {
1560
 
 
 
1571
                
1561
1572
 
1562
1573
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1563
1574
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1564
 
 
 
1575
                
1565
1576
                if(_describeInstancesResponseType->is_valid_return &&
1566
1577
                        arg_return == _describeInstancesResponseType->property_return)
1567
1578
                {
1568
 
 
1569
 
                    return AXIS2_SUCCESS;
 
1579
                    
 
1580
                    return AXIS2_SUCCESS; 
1570
1581
                }
1571
1582
 
1572
1583
                adb_describeInstancesResponseType_reset_return(_describeInstancesResponseType, env);
1573
1584
 
1574
1585
                _describeInstancesResponseType->property_return = arg_return;
1575
1586
                        _describeInstancesResponseType->is_valid_return = AXIS2_TRUE;
1576
 
 
 
1587
                    
1577
1588
                return AXIS2_SUCCESS;
1578
1589
             }
1579
1590
 
1580
 
 
 
1591
             
1581
1592
 
1582
1593
           /**
1583
1594
            * resetter for return
1593
1604
 
1594
1605
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1595
1606
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1596
 
 
1597
 
 
1598
 
               _describeInstancesResponseType->is_valid_return = AXIS2_FALSE;
 
1607
               
 
1608
 
 
1609
               _describeInstancesResponseType->is_valid_return = AXIS2_FALSE; 
1599
1610
               return AXIS2_SUCCESS;
1600
1611
           }
1601
1612
 
1609
1620
           {
1610
1621
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1611
1622
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_TRUE);
1612
 
 
 
1623
               
1613
1624
               return !_describeInstancesResponseType->is_valid_return;
1614
1625
           }
1615
1626
 
1624
1635
               return adb_describeInstancesResponseType_reset_return(_describeInstancesResponseType, env);
1625
1636
           }
1626
1637
 
1627
 
 
 
1638
           
1628
1639
 
1629
1640
            /**
1630
1641
             * getter for instances.
1634
1645
                    adb_describeInstancesResponseType_t* _describeInstancesResponseType,
1635
1646
                    const axutil_env_t *env)
1636
1647
             {
1637
 
 
 
1648
                
1638
1649
                    AXIS2_ENV_CHECK(env, NULL);
1639
1650
                    AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, NULL);
1640
 
 
 
1651
                  
1641
1652
 
1642
1653
                return _describeInstancesResponseType->property_instances;
1643
1654
             }
1651
1662
                    const axutil_env_t *env,
1652
1663
                    axutil_array_list_t*  arg_instances)
1653
1664
             {
1654
 
 
 
1665
                
1655
1666
                 int size = 0;
1656
1667
                 int i = 0;
1657
1668
                 axis2_bool_t non_nil_exists = AXIS2_FALSE;
1658
 
 
 
1669
                
1659
1670
 
1660
1671
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1661
1672
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1662
 
 
 
1673
                
1663
1674
                if(_describeInstancesResponseType->is_valid_instances &&
1664
1675
                        arg_instances == _describeInstancesResponseType->property_instances)
1665
1676
                {
1666
 
 
1667
 
                    return AXIS2_SUCCESS;
 
1677
                    
 
1678
                    return AXIS2_SUCCESS; 
1668
1679
                }
1669
1680
 
1670
 
 
 
1681
                
1671
1682
                 size = axutil_array_list_size(arg_instances, env);
1672
 
 
 
1683
                 
1673
1684
                 if (size < 0)
1674
1685
                 {
1675
1686
                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "instances has less than minOccurs(0)");
1686
1697
 
1687
1698
                 adb_describeInstancesResponseType_reset_instances(_describeInstancesResponseType, env);
1688
1699
 
1689
 
 
 
1700
                
1690
1701
                if(NULL == arg_instances)
1691
1702
                {
1692
1703
                    /* We are already done */
1697
1708
                        {
1698
1709
                            _describeInstancesResponseType->is_valid_instances = AXIS2_TRUE;
1699
1710
                        }
1700
 
 
1701
 
 
 
1711
                        
 
1712
                    
1702
1713
                return AXIS2_SUCCESS;
1703
1714
             }
1704
1715
 
1705
 
 
 
1716
            
1706
1717
            /**
1707
1718
             * Get ith element of instances.
1708
1719
             */
1713
1724
            {
1714
1725
                adb_ccInstanceType_t* ret_val;
1715
1726
 
1716
 
 
 
1727
                
1717
1728
                    AXIS2_ENV_CHECK(env, NULL);
1718
1729
                    AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, NULL);
1719
 
 
 
1730
                  
1720
1731
 
1721
1732
                if(_describeInstancesResponseType->property_instances == NULL)
1722
1733
                {
1723
1734
                    return (adb_ccInstanceType_t*)0;
1724
1735
                }
1725
1736
                ret_val = (adb_ccInstanceType_t*)axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i);
1726
 
 
 
1737
                
1727
1738
                    return ret_val;
1728
 
 
 
1739
                  
1729
1740
            }
1730
1741
 
1731
1742
            /**
1743
1754
                int k;
1744
1755
                axis2_bool_t non_nil_exists = AXIS2_FALSE;
1745
1756
 
1746
 
 
 
1757
                
1747
1758
 
1748
1759
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1749
1760
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1750
 
 
 
1761
                
1751
1762
                if( _describeInstancesResponseType->is_valid_instances &&
1752
1763
                    _describeInstancesResponseType->property_instances &&
1753
 
 
 
1764
                
1754
1765
                    arg_instances == (adb_ccInstanceType_t*)axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i))
1755
 
 
 
1766
                  
1756
1767
                {
1757
 
 
1758
 
                    return AXIS2_SUCCESS;
 
1768
                    
 
1769
                    return AXIS2_SUCCESS; 
1759
1770
                }
1760
1771
 
1761
 
 
 
1772
                
1762
1773
                    if(NULL == arg_instances)
1763
1774
                    {
1764
1775
                        if(_describeInstancesResponseType->property_instances != NULL)
1766
1777
                            size = axutil_array_list_size(_describeInstancesResponseType->property_instances, env);
1767
1778
                            for(j = 0, k = 0; j < size; j ++ )
1768
1779
                            {
1769
 
                                if(i == j) continue;
 
1780
                                if(i == j) continue; 
1770
1781
                                if(NULL != axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i))
1771
1782
                                {
1772
1783
                                    k ++;
1783
1794
                    {
1784
1795
                        non_nil_exists = AXIS2_TRUE;
1785
1796
                    }
1786
 
 
 
1797
                  
1787
1798
                if( k < 0)
1788
1799
                {
1789
1800
                       AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Size of the array of instances is beinng set to be smaller than the specificed number of minOccurs(0)");
1794
1805
                {
1795
1806
                    _describeInstancesResponseType->property_instances = axutil_array_list_create(env, 10);
1796
1807
                }
1797
 
 
 
1808
                
1798
1809
                /* check whether there already exist an element */
1799
1810
                element = axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i);
1800
1811
                if(NULL != element)
1801
1812
                {
1802
 
 
1803
 
 
1804
 
 
 
1813
                  
 
1814
                  
 
1815
                  
1805
1816
                        adb_ccInstanceType_free((adb_ccInstanceType_t*)element, env);
1806
 
 
 
1817
                     
1807
1818
                }
1808
1819
 
1809
 
 
 
1820
                
1810
1821
                    if(!non_nil_exists)
1811
1822
                    {
1812
 
 
 
1823
                        
1813
1824
                        _describeInstancesResponseType->is_valid_instances = AXIS2_FALSE;
1814
1825
                        axutil_array_list_set(_describeInstancesResponseType->property_instances , env, i, NULL);
1815
 
 
 
1826
                        
1816
1827
                        return AXIS2_SUCCESS;
1817
1828
                    }
1818
 
 
 
1829
                
1819
1830
                   axutil_array_list_set(_describeInstancesResponseType->property_instances , env, i, arg_instances);
1820
1831
                  _describeInstancesResponseType->is_valid_instances = AXIS2_TRUE;
1821
 
 
 
1832
                
1822
1833
                return AXIS2_SUCCESS;
1823
1834
            }
1824
1835
 
1831
1842
                    const axutil_env_t *env,
1832
1843
                    adb_ccInstanceType_t* arg_instances)
1833
1844
             {
1834
 
 
 
1845
                
1835
1846
 
1836
1847
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1837
1848
                AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1838
1849
 
1839
 
 
 
1850
                
1840
1851
                    if(NULL == arg_instances)
1841
1852
                    {
1842
 
 
1843
 
                           return AXIS2_SUCCESS;
1844
 
 
 
1853
                      
 
1854
                           return AXIS2_SUCCESS; 
 
1855
                        
1845
1856
                    }
1846
 
 
 
1857
                  
1847
1858
 
1848
1859
                if(_describeInstancesResponseType->property_instances == NULL)
1849
1860
                {
1853
1864
                {
1854
1865
                    AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Failed in allocatting memory for instances");
1855
1866
                    return AXIS2_FAILURE;
1856
 
 
 
1867
                    
1857
1868
                }
1858
 
 
 
1869
                
1859
1870
                   axutil_array_list_add(_describeInstancesResponseType->property_instances , env, arg_instances);
1860
1871
                  _describeInstancesResponseType->is_valid_instances = AXIS2_TRUE;
1861
1872
                return AXIS2_SUCCESS;
1889
1900
                return adb_describeInstancesResponseType_set_instances_nil_at(_describeInstancesResponseType, env, i);
1890
1901
            }
1891
1902
 
1892
 
 
 
1903
            
1893
1904
 
1894
1905
           /**
1895
1906
            * resetter for instances
1905
1916
 
1906
1917
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1907
1918
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_FAILURE);
1908
 
 
1909
 
 
1910
 
 
 
1919
               
 
1920
 
 
1921
               
1911
1922
                  if (_describeInstancesResponseType->property_instances != NULL)
1912
1923
                  {
1913
1924
                      count = axutil_array_list_size(_describeInstancesResponseType->property_instances, env);
1914
1925
                      for(i = 0; i < count; i ++)
1915
1926
                      {
1916
1927
                         element = axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i);
1917
 
 
1918
 
 
1919
 
 
 
1928
                
 
1929
            
 
1930
                
1920
1931
                if(element != NULL)
1921
1932
                {
1922
 
 
1923
 
 
 
1933
                   
 
1934
                   
1924
1935
                        adb_ccInstanceType_free((adb_ccInstanceType_t*)element, env);
1925
1936
                     element = NULL;
1926
1937
                }
1927
 
 
1928
 
 
1929
 
 
1930
 
 
 
1938
            
 
1939
                
 
1940
                
 
1941
                
1931
1942
                      }
1932
1943
                      axutil_array_list_free(_describeInstancesResponseType->property_instances, env);
1933
1944
                  }
1934
 
                _describeInstancesResponseType->is_valid_instances = AXIS2_FALSE;
 
1945
                _describeInstancesResponseType->is_valid_instances = AXIS2_FALSE; 
1935
1946
               return AXIS2_SUCCESS;
1936
1947
           }
1937
1948
 
1945
1956
           {
1946
1957
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1947
1958
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_TRUE);
1948
 
 
 
1959
               
1949
1960
               return !_describeInstancesResponseType->is_valid_instances;
1950
1961
           }
1951
1962
 
1960
1971
               return adb_describeInstancesResponseType_reset_instances(_describeInstancesResponseType, env);
1961
1972
           }
1962
1973
 
1963
 
 
 
1974
           
1964
1975
           /**
1965
1976
            * Check whether instances is nill at i
1966
1977
            */
1971
1982
           {
1972
1983
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1973
1984
               AXIS2_PARAM_CHECK(env->error, _describeInstancesResponseType, AXIS2_TRUE);
1974
 
 
 
1985
               
1975
1986
               return (_describeInstancesResponseType->is_valid_instances == AXIS2_FALSE ||
1976
 
                        NULL == _describeInstancesResponseType->property_instances ||
 
1987
                        NULL == _describeInstancesResponseType->property_instances || 
1977
1988
                        NULL == axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i));
1978
1989
           }
1979
1990
 
1998
2009
                if(_describeInstancesResponseType->property_instances == NULL ||
1999
2010
                            _describeInstancesResponseType->is_valid_instances == AXIS2_FALSE)
2000
2011
                {
2001
 
 
 
2012
                    
2002
2013
                    non_nil_exists = AXIS2_FALSE;
2003
2014
                }
2004
2015
                else
2006
2017
                    size = axutil_array_list_size(_describeInstancesResponseType->property_instances, env);
2007
2018
                    for(j = 0, k = 0; j < size; j ++ )
2008
2019
                    {
2009
 
                        if(i == j) continue;
 
2020
                        if(i == j) continue; 
2010
2021
                        if(NULL != axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i))
2011
2022
                        {
2012
2023
                            k ++;
2018
2029
                        }
2019
2030
                    }
2020
2031
                }
2021
 
 
 
2032
                
2022
2033
 
2023
2034
                if( k < 0)
2024
2035
                {
2025
2036
                       AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Size of the array of instances is beinng set to be smaller than the specificed number of minOccurs(0)");
2026
2037
                       return AXIS2_FAILURE;
2027
2038
                }
2028
 
 
 
2039
 
2029
2040
                if(_describeInstancesResponseType->property_instances == NULL)
2030
2041
                {
2031
2042
                    _describeInstancesResponseType->is_valid_instances = AXIS2_FALSE;
2032
 
 
 
2043
                    
2033
2044
                    return AXIS2_SUCCESS;
2034
2045
                }
2035
2046
 
2037
2048
                element = axutil_array_list_get(_describeInstancesResponseType->property_instances, env, i);
2038
2049
                if(NULL != element)
2039
2050
                {
2040
 
 
2041
 
 
2042
 
 
 
2051
                  
 
2052
                  
 
2053
                  
2043
2054
                        adb_ccInstanceType_free((adb_ccInstanceType_t*)element, env);
2044
 
 
 
2055
                     
2045
2056
                }
2046
2057
 
2047
 
 
 
2058
                
2048
2059
                    if(!non_nil_exists)
2049
2060
                    {
2050
 
 
 
2061
                        
2051
2062
                        _describeInstancesResponseType->is_valid_instances = AXIS2_FALSE;
2052
2063
                        axutil_array_list_set(_describeInstancesResponseType->property_instances , env, i, NULL);
2053
2064
                        return AXIS2_SUCCESS;
2054
2065
                    }
2055
 
 
2056
 
 
2057
 
 
 
2066
                
 
2067
 
 
2068
                
2058
2069
                axutil_array_list_set(_describeInstancesResponseType->property_instances , env, i, NULL);
2059
 
 
 
2070
                
2060
2071
                return AXIS2_SUCCESS;
2061
2072
 
2062
2073
           }
2063
2074
 
2064
 
 
 
2075
           
2065
2076