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

« back to all changes in this revision

Viewing changes to cluster/generated/adb_runInstancesResponseType.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_runInstancesResponseType.h"
11
 
 
 
11
        
12
12
                /*
13
13
                 * This type was generated from the piece of schema that had
14
14
                 * name = runInstancesResponseType
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_runInstancesResponseType
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_runInstancesResponseType_set_correlationId_nil(
62
62
                        adb_runInstancesResponseType_t* _runInstancesResponseType,
63
63
                        const axutil_env_t *env);
64
 
 
 
64
            
65
65
 
66
66
                axis2_status_t AXIS2_CALL
67
67
                adb_runInstancesResponseType_set_userId_nil(
68
68
                        adb_runInstancesResponseType_t* _runInstancesResponseType,
69
69
                        const axutil_env_t *env);
70
 
 
 
70
            
71
71
 
72
72
                axis2_status_t AXIS2_CALL
73
73
                adb_runInstancesResponseType_set_return_nil(
74
74
                        adb_runInstancesResponseType_t* _runInstancesResponseType,
75
75
                        const axutil_env_t *env);
76
 
 
 
76
            
77
77
                 axis2_status_t AXIS2_CALL
78
78
                 adb_runInstancesResponseType_set_instances_nil_at(
79
 
                        adb_runInstancesResponseType_t* _runInstancesResponseType,
 
79
                        adb_runInstancesResponseType_t* _runInstancesResponseType, 
80
80
                        const axutil_env_t *env, int i);
81
 
 
 
81
                
82
82
 
83
83
                axis2_status_t AXIS2_CALL
84
84
                adb_runInstancesResponseType_set_instances_nil(
85
85
                        adb_runInstancesResponseType_t* _runInstancesResponseType,
86
86
                        const axutil_env_t *env);
87
 
 
 
87
            
88
88
 
89
89
 
90
90
       /************************* Function Implmentations ********************************/
93
93
            const axutil_env_t *env)
94
94
        {
95
95
            adb_runInstancesResponseType_t *_runInstancesResponseType = NULL;
96
 
 
 
96
            
97
97
            AXIS2_ENV_CHECK(env, NULL);
98
98
 
99
99
            _runInstancesResponseType = (adb_runInstancesResponseType_t *) AXIS2_MALLOC(env->
116
116
            _runInstancesResponseType->is_valid_return  = AXIS2_FALSE;
117
117
            _runInstancesResponseType->property_instances  = NULL;
118
118
                  _runInstancesResponseType->is_valid_instances  = AXIS2_FALSE;
119
 
 
 
119
            
120
120
 
121
121
            return _runInstancesResponseType;
122
122
        }
126
126
                adb_runInstancesResponseType_t* _runInstancesResponseType,
127
127
                const axutil_env_t *env)
128
128
        {
129
 
 
 
129
            
130
130
                int i = 0;
131
131
                int count = 0;
132
132
                void *element = NULL;
133
 
 
 
133
            
134
134
 
135
135
            AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
136
136
            AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
140
140
            adb_runInstancesResponseType_reset_statusMessage(_runInstancesResponseType, env);
141
141
            adb_runInstancesResponseType_reset_return(_runInstancesResponseType, env);
142
142
            adb_runInstancesResponseType_reset_instances(_runInstancesResponseType, env);
143
 
 
 
143
            
144
144
 
145
145
            if(_runInstancesResponseType)
146
146
            {
151
151
        }
152
152
 
153
153
 
154
 
 
 
154
        
155
155
 
156
156
        axis2_status_t AXIS2_CALL
157
157
        adb_runInstancesResponseType_deserialize(
162
162
                axis2_bool_t dont_care_minoccurs)
163
163
        {
164
164
          axiom_node_t *parent = *dp_parent;
165
 
 
 
165
          
166
166
          axis2_status_t status = AXIS2_SUCCESS;
167
 
 
 
167
          
168
168
              void *element = NULL;
169
 
 
 
169
           
170
170
             axis2_char_t* text_value = NULL;
171
171
             axutil_qname_t *qname = NULL;
172
 
 
 
172
          
173
173
               int i = 0;
174
174
               axutil_array_list_t *arr_list = NULL;
175
 
 
 
175
            
176
176
               int sequence_broken = 0;
177
177
               axiom_node_t *tmp_node = NULL;
178
 
 
179
 
            axutil_qname_t *element_qname = NULL;
180
 
 
 
178
            
 
179
            axutil_qname_t *element_qname = NULL; 
 
180
            
181
181
               axiom_node_t *first_node = NULL;
182
182
               axis2_bool_t is_early_node_valid = AXIS2_TRUE;
183
183
               axiom_node_t *current_node = NULL;
184
184
               axiom_element_t *current_element = NULL;
185
 
 
 
185
            
186
186
            AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
187
187
            AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
188
188
 
189
 
 
190
 
 
 
189
            
 
190
              
191
191
              while(parent && axiom_node_get_node_type(parent, env) != AXIOM_ELEMENT)
192
192
              {
193
193
                  parent = axiom_node_get_next_sibling(parent, env);
195
195
              if (NULL == parent)
196
196
              {
197
197
                /* This should be checked before everything */
198
 
                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
 
198
                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, 
199
199
                            "Failed in building adb object for runInstancesResponseType : "
200
200
                            "NULL elemenet can not be passed to deserialize");
201
201
                return AXIS2_FAILURE;
202
202
              }
203
 
 
204
 
 
 
203
              
 
204
                      
205
205
                      first_node = axiom_node_get_first_child(parent, env);
206
 
 
207
 
 
208
 
 
209
 
 
 
206
                      
 
207
                    
 
208
 
 
209
                     
210
210
                     /*
211
211
                      * building correlationId element
212
212
                      */
213
 
 
214
 
 
215
 
 
 
213
                     
 
214
                     
 
215
                     
216
216
                                   current_node = first_node;
217
217
                                   is_early_node_valid = AXIS2_FALSE;
218
 
 
219
 
 
 
218
                                   
 
219
                                   
220
220
                                    while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
221
221
                                    {
222
222
                                        current_node = axiom_node_get_next_sibling(current_node, env);
226
226
                                        current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
227
227
                                        qname = axiom_element_get_qname(current_element, env, current_node);
228
228
                                    }
229
 
 
 
229
                                   
230
230
                                 element_qname = axutil_qname_create(env, "correlationId", "http://eucalyptus.ucsb.edu/", NULL);
231
 
 
232
 
 
233
 
                           if (
 
231
                                 
 
232
 
 
233
                           if ( 
234
234
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
235
235
                           {
236
236
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
237
237
                              {
238
238
                                is_early_node_valid = AXIS2_TRUE;
239
239
                              }
240
 
 
241
 
 
 
240
                              
 
241
                                 
242
242
                                      text_value = axiom_element_get_text(current_element, env, current_node);
243
243
                                      if(text_value != NULL)
244
244
                                      {
245
245
                                            status = adb_runInstancesResponseType_set_correlationId(_runInstancesResponseType, env,
246
246
                                                               text_value);
247
247
                                      }
248
 
 
 
248
                                      
249
249
                                      else
250
250
                                      {
251
251
                                            /*
252
252
                                             * axis2_qname_t *qname = NULL;
253
253
                                             * axiom_attribute_t *the_attri = NULL;
254
 
                                             *
 
254
                                             * 
255
255
                                             * qname = axutil_qname_create(env, "nil", "http://www.w3.org/2001/XMLSchema-instance", "xsi");
256
256
                                             * the_attri = axiom_element_get_attribute(current_element, env, qname);
257
257
                                             */
269
269
                                                 axutil_hash_index_t *hi;
270
270
                                                 void *val;
271
271
                                                 const void *key;
272
 
 
273
 
                                                 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)) 
274
274
                                                 {
275
275
                                                     axutil_hash_this(hi, &key, NULL, &val);
276
 
 
 
276
                                                     
277
277
                                                     if(strstr((axis2_char_t*)key, "nil|http://www.w3.org/2001/XMLSchema-instance"))
278
278
                                                     {
279
279
                                                         the_attri = (axiom_attribute_t*)val;
304
304
                                                                   "");
305
305
                                            }
306
306
                                      }
307
 
 
 
307
                                      
308
308
                                 if(AXIS2_FAILURE ==  status)
309
309
                                 {
310
310
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for correlationId ");
315
315
                                     return AXIS2_FAILURE;
316
316
                                 }
317
317
                              }
318
 
 
 
318
                           
319
319
                  if(element_qname)
320
320
                  {
321
321
                     axutil_qname_free(element_qname, env);
322
322
                     element_qname = NULL;
323
323
                  }
324
 
 
325
 
 
326
 
 
 
324
                 
 
325
 
 
326
                     
327
327
                     /*
328
328
                      * building userId element
329
329
                      */
330
 
 
331
 
 
332
 
 
 
330
                     
 
331
                     
 
332
                     
333
333
                                    /*
334
334
                                     * because elements are ordered this works fine
335
335
                                     */
336
 
 
337
 
 
 
336
                                  
 
337
                                   
338
338
                                   if(current_node != NULL && is_early_node_valid)
339
339
                                   {
340
340
                                       current_node = axiom_node_get_next_sibling(current_node, env);
341
 
 
342
 
 
 
341
                                       
 
342
                                       
343
343
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
344
344
                                        {
345
345
                                            current_node = axiom_node_get_next_sibling(current_node, env);
349
349
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
350
350
                                            qname = axiom_element_get_qname(current_element, env, current_node);
351
351
                                        }
352
 
 
 
352
                                       
353
353
                                   }
354
354
                                   is_early_node_valid = AXIS2_FALSE;
355
 
 
 
355
                                 
356
356
                                 element_qname = axutil_qname_create(env, "userId", "http://eucalyptus.ucsb.edu/", NULL);
357
 
 
358
 
 
359
 
                           if (
 
357
                                 
 
358
 
 
359
                           if ( 
360
360
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
361
361
                           {
362
362
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
363
363
                              {
364
364
                                is_early_node_valid = AXIS2_TRUE;
365
365
                              }
366
 
 
367
 
 
 
366
                              
 
367
                                 
368
368
                                      text_value = axiom_element_get_text(current_element, env, current_node);
369
369
                                      if(text_value != NULL)
370
370
                                      {
371
371
                                            status = adb_runInstancesResponseType_set_userId(_runInstancesResponseType, env,
372
372
                                                               text_value);
373
373
                                      }
374
 
 
 
374
                                      
375
375
                                      else
376
376
                                      {
377
377
                                            /*
378
378
                                             * axis2_qname_t *qname = NULL;
379
379
                                             * axiom_attribute_t *the_attri = NULL;
380
 
                                             *
 
380
                                             * 
381
381
                                             * qname = axutil_qname_create(env, "nil", "http://www.w3.org/2001/XMLSchema-instance", "xsi");
382
382
                                             * the_attri = axiom_element_get_attribute(current_element, env, qname);
383
383
                                             */
395
395
                                                 axutil_hash_index_t *hi;
396
396
                                                 void *val;
397
397
                                                 const void *key;
398
 
 
399
 
                                                 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)) 
400
400
                                                 {
401
401
                                                     axutil_hash_this(hi, &key, NULL, &val);
402
 
 
 
402
                                                     
403
403
                                                     if(strstr((axis2_char_t*)key, "nil|http://www.w3.org/2001/XMLSchema-instance"))
404
404
                                                     {
405
405
                                                         the_attri = (axiom_attribute_t*)val;
430
430
                                                                   "");
431
431
                                            }
432
432
                                      }
433
 
 
 
433
                                      
434
434
                                 if(AXIS2_FAILURE ==  status)
435
435
                                 {
436
436
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for userId ");
441
441
                                     return AXIS2_FAILURE;
442
442
                                 }
443
443
                              }
444
 
 
 
444
                           
445
445
                  if(element_qname)
446
446
                  {
447
447
                     axutil_qname_free(element_qname, env);
448
448
                     element_qname = NULL;
449
449
                  }
450
 
 
451
 
 
452
 
 
 
450
                 
 
451
 
 
452
                     
453
453
                     /*
454
454
                      * building statusMessage element
455
455
                      */
456
 
 
457
 
 
458
 
 
 
456
                     
 
457
                     
 
458
                     
459
459
                                    /*
460
460
                                     * because elements are ordered this works fine
461
461
                                     */
462
 
 
463
 
 
 
462
                                  
 
463
                                   
464
464
                                   if(current_node != NULL && is_early_node_valid)
465
465
                                   {
466
466
                                       current_node = axiom_node_get_next_sibling(current_node, env);
467
 
 
468
 
 
 
467
                                       
 
468
                                       
469
469
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
470
470
                                        {
471
471
                                            current_node = axiom_node_get_next_sibling(current_node, env);
475
475
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
476
476
                                            qname = axiom_element_get_qname(current_element, env, current_node);
477
477
                                        }
478
 
 
 
478
                                       
479
479
                                   }
480
480
                                   is_early_node_valid = AXIS2_FALSE;
481
 
 
 
481
                                 
482
482
                                 element_qname = axutil_qname_create(env, "statusMessage", "http://eucalyptus.ucsb.edu/", NULL);
483
 
 
484
 
 
485
 
                           if (
 
483
                                 
 
484
 
 
485
                           if ( 
486
486
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
487
487
                           {
488
488
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
489
489
                              {
490
490
                                is_early_node_valid = AXIS2_TRUE;
491
491
                              }
492
 
 
493
 
 
 
492
                              
 
493
                                 
494
494
                                      text_value = axiom_element_get_text(current_element, env, current_node);
495
495
                                      if(text_value != NULL)
496
496
                                      {
497
497
                                            status = adb_runInstancesResponseType_set_statusMessage(_runInstancesResponseType, env,
498
498
                                                               text_value);
499
499
                                      }
500
 
 
 
500
                                      
501
501
                                 if(AXIS2_FAILURE ==  status)
502
502
                                 {
503
503
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for statusMessage ");
508
508
                                     return AXIS2_FAILURE;
509
509
                                 }
510
510
                              }
511
 
 
 
511
                           
512
512
                  if(element_qname)
513
513
                  {
514
514
                     axutil_qname_free(element_qname, env);
515
515
                     element_qname = NULL;
516
516
                  }
517
 
 
518
 
 
519
 
 
 
517
                 
 
518
 
 
519
                     
520
520
                     /*
521
521
                      * building return element
522
522
                      */
523
 
 
524
 
 
525
 
 
 
523
                     
 
524
                     
 
525
                     
526
526
                                    /*
527
527
                                     * because elements are ordered this works fine
528
528
                                     */
529
 
 
530
 
 
 
529
                                  
 
530
                                   
531
531
                                   if(current_node != NULL && is_early_node_valid)
532
532
                                   {
533
533
                                       current_node = axiom_node_get_next_sibling(current_node, env);
534
 
 
535
 
 
 
534
                                       
 
535
                                       
536
536
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
537
537
                                        {
538
538
                                            current_node = axiom_node_get_next_sibling(current_node, env);
542
542
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
543
543
                                            qname = axiom_element_get_qname(current_element, env, current_node);
544
544
                                        }
545
 
 
 
545
                                       
546
546
                                   }
547
547
                                   is_early_node_valid = AXIS2_FALSE;
548
 
 
 
548
                                 
549
549
                                 element_qname = axutil_qname_create(env, "return", "http://eucalyptus.ucsb.edu/", NULL);
550
 
 
551
 
 
552
 
                           if (
 
550
                                 
 
551
 
 
552
                           if ( 
553
553
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
554
554
                           {
555
555
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
556
556
                              {
557
557
                                is_early_node_valid = AXIS2_TRUE;
558
558
                              }
559
 
 
560
 
 
 
559
                              
 
560
                                 
561
561
                                      text_value = axiom_element_get_text(current_element, env, current_node);
562
562
                                      if(text_value != NULL)
563
563
                                      {
572
572
                                                                      AXIS2_FALSE);
573
573
                                            }
574
574
                                      }
575
 
 
 
575
                                      
576
576
                                      else
577
577
                                      {
578
578
                                          AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element return");
579
579
                                          status = AXIS2_FAILURE;
580
580
                                      }
581
 
 
 
581
                                      
582
582
                                 if(AXIS2_FAILURE ==  status)
583
583
                                 {
584
584
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for return ");
589
589
                                     return AXIS2_FAILURE;
590
590
                                 }
591
591
                              }
592
 
 
 
592
                           
593
593
                  if(element_qname)
594
594
                  {
595
595
                     axutil_qname_free(element_qname, env);
596
596
                     element_qname = NULL;
597
597
                  }
598
 
 
 
598
                 
599
599
                    /*
600
600
                     * building instances array
601
601
                     */
602
602
                       arr_list = axutil_array_list_create(env, 10);
603
 
 
604
 
 
605
 
 
 
603
                   
 
604
 
 
605
                     
606
606
                     /*
607
607
                      * building instances element
608
608
                      */
609
 
 
610
 
 
611
 
 
 
609
                     
 
610
                     
 
611
                     
612
612
                                    element_qname = axutil_qname_create(env, "instances", "http://eucalyptus.ucsb.edu/", NULL);
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
 
 
 
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
                                             
617
617
                               {
618
618
                                  if(axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
619
619
                                  {
621
621
                                     is_early_node_valid = AXIS2_FALSE;
622
622
                                     continue;
623
623
                                  }
624
 
 
 
624
                                  
625
625
                                  current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
626
626
                                  qname = axiom_element_get_qname(current_element, env, current_node);
627
627
 
628
628
                                  if (axutil_qname_equals(element_qname, env, qname))
629
629
                                  {
630
 
 
 
630
                                  
631
631
                                      is_early_node_valid = AXIS2_TRUE;
632
 
 
633
 
 
 
632
                                      
 
633
                                     
634
634
                                          element = (void*)adb_ccInstanceType_create(env);
635
 
 
 
635
                                          
636
636
                                          status =  adb_ccInstanceType_deserialize((adb_ccInstanceType_t*)element, env,
637
637
                                                                                 &current_node, &is_early_node_valid, AXIS2_FALSE);
638
 
 
 
638
                                          
639
639
                                          if(AXIS2_FAILURE ==  status)
640
640
                                          {
641
641
                                              AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in building element instances ");
644
644
                                          {
645
645
                                            axutil_array_list_add_at(arr_list, env, i, element);
646
646
                                          }
647
 
 
 
647
                                        
648
648
                                     if(AXIS2_FAILURE ==  status)
649
649
                                     {
650
650
                                         AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for instances ");
667
667
                                      is_early_node_valid = AXIS2_FALSE;
668
668
                                      sequence_broken = 1;
669
669
                                  }
670
 
 
 
670
                                  
671
671
                               }
672
672
 
673
 
 
 
673
                               
674
674
                                   if (i < 0)
675
675
                                   {
676
676
                                     /* found element out of order */
685
685
                                     }
686
686
                                     return AXIS2_FAILURE;
687
687
                                   }
688
 
 
 
688
                               
689
689
 
690
690
                               if(0 == axutil_array_list_size(arr_list,env))
691
691
                               {
697
697
                                                                   arr_list);
698
698
                               }
699
699
 
700
 
 
 
700
                             
701
701
                  if(element_qname)
702
702
                  {
703
703
                     axutil_qname_free(element_qname, env);
704
704
                     element_qname = NULL;
705
705
                  }
706
 
 
 
706
                 
707
707
          return status;
708
708
       }
709
709
 
710
710
          axis2_bool_t AXIS2_CALL
711
711
          adb_runInstancesResponseType_is_particle()
712
712
          {
713
 
 
 
713
            
714
714
                 return AXIS2_FALSE;
715
 
 
 
715
              
716
716
          }
717
717
 
718
718
 
722
722
                    const axutil_env_t *env, axiom_element_t *parent_element,
723
723
                    axutil_hash_t *namespaces, int *next_ns_index)
724
724
          {
725
 
 
 
725
            
726
726
                  /* Here this is an empty function, Nothing to declare */
727
 
 
 
727
                 
728
728
          }
729
729
 
730
 
 
731
 
 
 
730
        
 
731
        
732
732
        axiom_node_t* AXIS2_CALL
733
733
        adb_runInstancesResponseType_serialize(
734
734
                adb_runInstancesResponseType_t* _runInstancesResponseType,
735
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)
736
736
        {
737
 
 
738
 
 
 
737
            
 
738
            
739
739
             axis2_char_t *string_to_stream;
740
 
 
741
 
 
 
740
            
 
741
         
742
742
         axiom_node_t *current_node = NULL;
743
743
         int tag_closed = 0;
744
744
 
745
 
 
746
 
 
 
745
         
 
746
         
747
747
                axiom_namespace_t *ns1 = NULL;
748
748
 
749
749
                axis2_char_t *qname_uri = NULL;
750
750
                axis2_char_t *qname_prefix = NULL;
751
751
                axis2_char_t *p_prefix = NULL;
752
752
                axis2_bool_t ns_already_defined;
753
 
 
 
753
            
754
754
               int i = 0;
755
755
               int count = 0;
756
756
               void *element = NULL;
757
 
 
 
757
             
758
758
                    axis2_char_t *text_value_1;
759
759
                    axis2_char_t *text_value_1_temp;
760
 
 
 
760
                    
761
761
                    axis2_char_t *text_value_2;
762
762
                    axis2_char_t *text_value_2_temp;
763
 
 
 
763
                    
764
764
                    axis2_char_t *text_value_3;
765
765
                    axis2_char_t *text_value_3_temp;
766
 
 
 
766
                    
767
767
                    axis2_char_t text_value_4[64];
768
 
 
 
768
                    
769
769
                    axis2_char_t text_value_5[64];
770
 
 
 
770
                    
771
771
               axis2_char_t *start_input_str = NULL;
772
772
               axis2_char_t *end_input_str = NULL;
773
773
               unsigned int start_input_str_len = 0;
774
774
               unsigned int end_input_str_len = 0;
775
 
 
776
 
 
 
775
            
 
776
            
777
777
               axiom_data_source_t *data_source = NULL;
778
778
               axutil_stream_t *stream = NULL;
779
779
 
780
 
 
 
780
            
781
781
 
782
782
            AXIS2_ENV_CHECK(env, NULL);
783
783
            AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, NULL);
784
 
 
785
 
 
 
784
            
 
785
            
786
786
                    current_node = parent;
787
787
                    data_source = (axiom_data_source_t *)axiom_node_get_data_element(current_node, env);
788
788
                    if (!data_source)
790
790
                    stream = axiom_data_source_get_stream(data_source, env); /* assume parent is of type data source */
791
791
                    if (!stream)
792
792
                        return NULL;
793
 
 
 
793
                  
794
794
            if(!parent_tag_closed)
795
795
            {
796
 
 
797
 
              string_to_stream = ">";
 
796
            
 
797
              string_to_stream = ">"; 
798
798
              axutil_stream_write(stream, env, string_to_stream, axutil_strlen(string_to_stream));
799
799
              tag_closed = 1;
800
 
 
 
800
            
801
801
            }
802
 
 
 
802
            
803
803
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
804
804
                       {
805
805
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
806
806
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
807
807
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
808
 
 
 
808
                           
809
809
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
810
810
                                            "http://eucalyptus.ucsb.edu/",
811
811
                                            p_prefix));
812
812
                       }
813
 
 
 
813
                      
814
814
 
815
815
                   if (!_runInstancesResponseType->is_valid_correlationId)
816
816
                   {
817
 
 
 
817
                      
818
818
                           /* no need to complain for minoccurs=0 element */
819
 
 
820
 
 
 
819
                            
 
820
                          
821
821
                   }
822
822
                   else
823
823
                   {
824
824
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
825
 
                                 (4 + axutil_strlen(p_prefix) +
826
 
                                  axutil_strlen("correlationId")));
827
 
 
 
825
                                 (4 + axutil_strlen(p_prefix) + 
 
826
                                  axutil_strlen("correlationId"))); 
 
827
                                 
828
828
                                 /* axutil_strlen("<:>") + 1 = 4 */
829
829
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
830
830
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("correlationId")));
831
831
                                  /* axutil_strlen("</:>") + 1 = 5 */
832
 
 
833
 
 
834
 
 
835
 
 
836
 
 
837
 
 
 
832
                                  
 
833
                     
 
834
 
 
835
                   
 
836
                   
 
837
                     
838
838
                     /*
839
839
                      * parsing correlationId element
840
840
                      */
841
841
 
842
 
 
843
 
 
 
842
                    
 
843
                    
844
844
                            sprintf(start_input_str, "<%s%scorrelationId>",
845
845
                                 p_prefix?p_prefix:"",
846
846
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
847
 
 
 
847
                            
848
848
                        start_input_str_len = axutil_strlen(start_input_str);
849
849
                        sprintf(end_input_str, "</%s%scorrelationId>",
850
850
                                 p_prefix?p_prefix:"",
851
851
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
852
852
                        end_input_str_len = axutil_strlen(end_input_str);
853
 
 
 
853
                    
854
854
                           text_value_1 = _runInstancesResponseType->property_correlationId;
855
 
 
 
855
                           
856
856
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
857
 
 
858
 
 
 
857
                           
 
858
                            
859
859
                           text_value_1_temp = axutil_xml_quote_string(env, text_value_1, AXIS2_TRUE);
860
860
                           if (text_value_1_temp)
861
861
                           {
866
866
                           {
867
867
                               axutil_stream_write(stream, env, text_value_1, axutil_strlen(text_value_1));
868
868
                           }
869
 
 
 
869
                           
870
870
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
871
 
 
872
 
 
 
871
                           
 
872
                     
873
873
                     AXIS2_FREE(env->allocator,start_input_str);
874
874
                     AXIS2_FREE(env->allocator,end_input_str);
875
 
                 }
876
 
 
877
 
 
 
875
                 } 
 
876
 
 
877
                 
878
878
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
879
879
                       {
880
880
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
881
881
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
882
882
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
883
 
 
 
883
                           
884
884
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
885
885
                                            "http://eucalyptus.ucsb.edu/",
886
886
                                            p_prefix));
887
887
                       }
888
 
 
 
888
                      
889
889
 
890
890
                   if (!_runInstancesResponseType->is_valid_userId)
891
891
                   {
892
 
 
 
892
                      
893
893
                           /* no need to complain for minoccurs=0 element */
894
 
 
895
 
 
 
894
                            
 
895
                          
896
896
                   }
897
897
                   else
898
898
                   {
899
899
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
900
 
                                 (4 + axutil_strlen(p_prefix) +
901
 
                                  axutil_strlen("userId")));
902
 
 
 
900
                                 (4 + axutil_strlen(p_prefix) + 
 
901
                                  axutil_strlen("userId"))); 
 
902
                                 
903
903
                                 /* axutil_strlen("<:>") + 1 = 4 */
904
904
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
905
905
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("userId")));
906
906
                                  /* axutil_strlen("</:>") + 1 = 5 */
907
 
 
908
 
 
909
 
 
910
 
 
911
 
 
912
 
 
 
907
                                  
 
908
                     
 
909
 
 
910
                   
 
911
                   
 
912
                     
913
913
                     /*
914
914
                      * parsing userId element
915
915
                      */
916
916
 
917
 
 
918
 
 
 
917
                    
 
918
                    
919
919
                            sprintf(start_input_str, "<%s%suserId>",
920
920
                                 p_prefix?p_prefix:"",
921
921
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
922
 
 
 
922
                            
923
923
                        start_input_str_len = axutil_strlen(start_input_str);
924
924
                        sprintf(end_input_str, "</%s%suserId>",
925
925
                                 p_prefix?p_prefix:"",
926
926
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
927
927
                        end_input_str_len = axutil_strlen(end_input_str);
928
 
 
 
928
                    
929
929
                           text_value_2 = _runInstancesResponseType->property_userId;
930
 
 
 
930
                           
931
931
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
932
 
 
933
 
 
 
932
                           
 
933
                            
934
934
                           text_value_2_temp = axutil_xml_quote_string(env, text_value_2, AXIS2_TRUE);
935
935
                           if (text_value_2_temp)
936
936
                           {
941
941
                           {
942
942
                               axutil_stream_write(stream, env, text_value_2, axutil_strlen(text_value_2));
943
943
                           }
944
 
 
 
944
                           
945
945
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
946
 
 
947
 
 
 
946
                           
 
947
                     
948
948
                     AXIS2_FREE(env->allocator,start_input_str);
949
949
                     AXIS2_FREE(env->allocator,end_input_str);
950
 
                 }
951
 
 
952
 
 
 
950
                 } 
 
951
 
 
952
                 
953
953
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
954
954
                       {
955
955
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
956
956
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
957
957
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
958
 
 
 
958
                           
959
959
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
960
960
                                            "http://eucalyptus.ucsb.edu/",
961
961
                                            p_prefix));
962
962
                       }
963
 
 
 
963
                      
964
964
 
965
965
                   if (!_runInstancesResponseType->is_valid_statusMessage)
966
966
                   {
967
 
 
 
967
                      
968
968
                           /* no need to complain for minoccurs=0 element */
969
 
 
970
 
 
 
969
                            
 
970
                          
971
971
                   }
972
972
                   else
973
973
                   {
974
974
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
975
 
                                 (4 + axutil_strlen(p_prefix) +
976
 
                                  axutil_strlen("statusMessage")));
977
 
 
 
975
                                 (4 + axutil_strlen(p_prefix) + 
 
976
                                  axutil_strlen("statusMessage"))); 
 
977
                                 
978
978
                                 /* axutil_strlen("<:>") + 1 = 4 */
979
979
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
980
980
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("statusMessage")));
981
981
                                  /* axutil_strlen("</:>") + 1 = 5 */
982
 
 
983
 
 
984
 
 
985
 
 
986
 
 
987
 
 
 
982
                                  
 
983
                     
 
984
 
 
985
                   
 
986
                   
 
987
                     
988
988
                     /*
989
989
                      * parsing statusMessage element
990
990
                      */
991
991
 
992
 
 
993
 
 
 
992
                    
 
993
                    
994
994
                            sprintf(start_input_str, "<%s%sstatusMessage>",
995
995
                                 p_prefix?p_prefix:"",
996
996
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
997
 
 
 
997
                            
998
998
                        start_input_str_len = axutil_strlen(start_input_str);
999
999
                        sprintf(end_input_str, "</%s%sstatusMessage>",
1000
1000
                                 p_prefix?p_prefix:"",
1001
1001
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1002
1002
                        end_input_str_len = axutil_strlen(end_input_str);
1003
 
 
 
1003
                    
1004
1004
                           text_value_3 = _runInstancesResponseType->property_statusMessage;
1005
 
 
 
1005
                           
1006
1006
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
1007
 
 
1008
 
 
 
1007
                           
 
1008
                            
1009
1009
                           text_value_3_temp = axutil_xml_quote_string(env, text_value_3, AXIS2_TRUE);
1010
1010
                           if (text_value_3_temp)
1011
1011
                           {
1016
1016
                           {
1017
1017
                               axutil_stream_write(stream, env, text_value_3, axutil_strlen(text_value_3));
1018
1018
                           }
1019
 
 
 
1019
                           
1020
1020
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
1021
 
 
1022
 
 
 
1021
                           
 
1022
                     
1023
1023
                     AXIS2_FREE(env->allocator,start_input_str);
1024
1024
                     AXIS2_FREE(env->allocator,end_input_str);
1025
 
                 }
1026
 
 
1027
 
 
 
1025
                 } 
 
1026
 
 
1027
                 
1028
1028
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
1029
1029
                       {
1030
1030
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
1031
1031
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
1032
1032
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
1033
 
 
 
1033
                           
1034
1034
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
1035
1035
                                            "http://eucalyptus.ucsb.edu/",
1036
1036
                                            p_prefix));
1037
1037
                       }
1038
 
 
 
1038
                      
1039
1039
 
1040
1040
                   if (!_runInstancesResponseType->is_valid_return)
1041
1041
                   {
1042
 
 
 
1042
                      
1043
1043
                           /* no need to complain for minoccurs=0 element */
1044
 
 
1045
 
 
 
1044
                            
 
1045
                          
1046
1046
                   }
1047
1047
                   else
1048
1048
                   {
1049
1049
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1050
 
                                 (4 + axutil_strlen(p_prefix) +
1051
 
                                  axutil_strlen("return")));
1052
 
 
 
1050
                                 (4 + axutil_strlen(p_prefix) + 
 
1051
                                  axutil_strlen("return"))); 
 
1052
                                 
1053
1053
                                 /* axutil_strlen("<:>") + 1 = 4 */
1054
1054
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1055
1055
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("return")));
1056
1056
                                  /* axutil_strlen("</:>") + 1 = 5 */
1057
 
 
1058
 
 
1059
 
 
1060
 
 
1061
 
 
1062
 
 
 
1057
                                  
 
1058
                     
 
1059
 
 
1060
                   
 
1061
                   
 
1062
                     
1063
1063
                     /*
1064
1064
                      * parsing return element
1065
1065
                      */
1066
1066
 
1067
 
 
1068
 
 
 
1067
                    
 
1068
                    
1069
1069
                            sprintf(start_input_str, "<%s%sreturn>",
1070
1070
                                 p_prefix?p_prefix:"",
1071
1071
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1072
 
 
 
1072
                            
1073
1073
                        start_input_str_len = axutil_strlen(start_input_str);
1074
1074
                        sprintf(end_input_str, "</%s%sreturn>",
1075
1075
                                 p_prefix?p_prefix:"",
1076
1076
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1077
1077
                        end_input_str_len = axutil_strlen(end_input_str);
1078
 
 
 
1078
                    
1079
1079
                           strcpy(text_value_4, (_runInstancesResponseType->property_return)?"true":"false");
1080
 
 
 
1080
                           
1081
1081
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
1082
 
 
 
1082
                           
1083
1083
                           axutil_stream_write(stream, env, text_value_4, axutil_strlen(text_value_4));
1084
 
 
 
1084
                           
1085
1085
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
1086
 
 
1087
 
 
 
1086
                           
 
1087
                     
1088
1088
                     AXIS2_FREE(env->allocator,start_input_str);
1089
1089
                     AXIS2_FREE(env->allocator,end_input_str);
1090
 
                 }
1091
 
 
1092
 
 
 
1090
                 } 
 
1091
 
 
1092
                 
1093
1093
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
1094
1094
                       {
1095
1095
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
1096
1096
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
1097
1097
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
1098
 
 
 
1098
                           
1099
1099
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
1100
1100
                                            "http://eucalyptus.ucsb.edu/",
1101
1101
                                            p_prefix));
1102
1102
                       }
1103
 
 
 
1103
                      
1104
1104
 
1105
1105
                   if (!_runInstancesResponseType->is_valid_instances)
1106
1106
                   {
1107
 
 
 
1107
                      
1108
1108
                           /* no need to complain for minoccurs=0 element */
1109
 
 
1110
 
 
 
1109
                            
 
1110
                          
1111
1111
                   }
1112
1112
                   else
1113
1113
                   {
1114
1114
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1115
 
                                 (4 + axutil_strlen(p_prefix) +
1116
 
                                  axutil_strlen("instances")));
1117
 
 
 
1115
                                 (4 + axutil_strlen(p_prefix) + 
 
1116
                                  axutil_strlen("instances"))); 
 
1117
                                 
1118
1118
                                 /* axutil_strlen("<:>") + 1 = 4 */
1119
1119
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
1120
1120
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("instances")));
1121
1121
                                  /* axutil_strlen("</:>") + 1 = 5 */
1122
 
 
1123
 
 
1124
 
 
1125
 
 
1126
 
 
 
1122
                                  
 
1123
                     
 
1124
 
 
1125
                   
 
1126
                   
1127
1127
                     /*
1128
1128
                      * Parsing instances array
1129
1129
                      */
1130
1130
                     if (_runInstancesResponseType->property_instances != NULL)
1131
1131
                     {
1132
 
 
 
1132
                        
1133
1133
 
1134
1134
                            sprintf(start_input_str, "<%s%sinstances",
1135
1135
                                 p_prefix?p_prefix:"",
1136
1136
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
1137
 
 
 
1137
                            
1138
1138
                         start_input_str_len = axutil_strlen(start_input_str);
1139
1139
 
1140
1140
                         sprintf(end_input_str, "</%s%sinstances>",
1147
1147
                         {
1148
1148
                            element = axutil_array_list_get(_runInstancesResponseType->property_instances, env, i);
1149
1149
 
1150
 
                            if(NULL == element)
 
1150
                            if(NULL == element) 
1151
1151
                            {
1152
1152
                                continue;
1153
1153
                            }
1154
 
 
1155
 
 
 
1154
                    
 
1155
                     
1156
1156
                     /*
1157
1157
                      * parsing instances element
1158
1158
                      */
1159
1159
 
1160
 
 
1161
 
 
 
1160
                    
 
1161
                     
1162
1162
                            if(!adb_ccInstanceType_is_particle())
1163
1163
                            {
1164
1164
                                axutil_stream_write(stream, env, start_input_str, start_input_str_len);
1165
1165
                            }
1166
 
 
1167
 
                            adb_ccInstanceType_serialize((adb_ccInstanceType_t*)element,
 
1166
                            
 
1167
                            adb_ccInstanceType_serialize((adb_ccInstanceType_t*)element, 
1168
1168
                                                                                 env, current_node, parent_element,
1169
1169
                                                                                 adb_ccInstanceType_is_particle() || AXIS2_FALSE, namespaces, next_ns_index);
1170
 
 
 
1170
                            
1171
1171
                            if(!adb_ccInstanceType_is_particle())
1172
1172
                            {
1173
1173
                                axutil_stream_write(stream, env, end_input_str, end_input_str_len);
1174
1174
                            }
1175
 
 
 
1175
                            
1176
1176
                         }
1177
1177
                     }
1178
 
 
1179
 
 
 
1178
                   
 
1179
                     
1180
1180
                     AXIS2_FREE(env->allocator,start_input_str);
1181
1181
                     AXIS2_FREE(env->allocator,end_input_str);
1182
 
                 }
1183
 
 
1184
 
 
 
1182
                 } 
 
1183
 
 
1184
                 
1185
1185
 
1186
1186
            return parent;
1187
1187
        }
1188
1188
 
1189
1189
 
1190
 
 
 
1190
        
1191
1191
 
1192
1192
            /**
1193
1193
             * getter for correlationId.
1197
1197
                    adb_runInstancesResponseType_t* _runInstancesResponseType,
1198
1198
                    const axutil_env_t *env)
1199
1199
             {
1200
 
 
 
1200
                
1201
1201
                    AXIS2_ENV_CHECK(env, NULL);
1202
1202
                    AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, NULL);
1203
 
 
 
1203
                  
1204
1204
 
1205
1205
                return _runInstancesResponseType->property_correlationId;
1206
1206
             }
1214
1214
                    const axutil_env_t *env,
1215
1215
                    const axis2_char_t*  arg_correlationId)
1216
1216
             {
1217
 
 
 
1217
                
1218
1218
 
1219
1219
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1220
1220
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1221
 
 
 
1221
                
1222
1222
                if(_runInstancesResponseType->is_valid_correlationId &&
1223
1223
                        arg_correlationId == _runInstancesResponseType->property_correlationId)
1224
1224
                {
1225
 
 
1226
 
                    return AXIS2_SUCCESS;
 
1225
                    
 
1226
                    return AXIS2_SUCCESS; 
1227
1227
                }
1228
1228
 
1229
1229
                adb_runInstancesResponseType_reset_correlationId(_runInstancesResponseType, env);
1230
1230
 
1231
 
 
 
1231
                
1232
1232
                if(NULL == arg_correlationId)
1233
1233
                {
1234
1234
                    /* We are already done */
1241
1241
                            return AXIS2_FAILURE;
1242
1242
                        }
1243
1243
                        _runInstancesResponseType->is_valid_correlationId = AXIS2_TRUE;
1244
 
 
 
1244
                    
1245
1245
                return AXIS2_SUCCESS;
1246
1246
             }
1247
1247
 
1248
 
 
 
1248
             
1249
1249
 
1250
1250
           /**
1251
1251
            * resetter for correlationId
1261
1261
 
1262
1262
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1263
1263
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1264
 
 
1265
 
 
1266
 
 
1267
 
 
1268
 
 
 
1264
               
 
1265
 
 
1266
               
 
1267
            
 
1268
                
1269
1269
                if(_runInstancesResponseType->property_correlationId != NULL)
1270
1270
                {
1271
 
 
1272
 
 
 
1271
                   
 
1272
                   
1273
1273
                        AXIS2_FREE(env-> allocator, _runInstancesResponseType->property_correlationId);
1274
1274
                     _runInstancesResponseType->property_correlationId = NULL;
1275
1275
                }
1276
 
 
1277
 
 
1278
 
 
1279
 
                _runInstancesResponseType->is_valid_correlationId = AXIS2_FALSE;
 
1276
            
 
1277
                
 
1278
                
 
1279
                _runInstancesResponseType->is_valid_correlationId = AXIS2_FALSE; 
1280
1280
               return AXIS2_SUCCESS;
1281
1281
           }
1282
1282
 
1290
1290
           {
1291
1291
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1292
1292
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_TRUE);
1293
 
 
 
1293
               
1294
1294
               return !_runInstancesResponseType->is_valid_correlationId;
1295
1295
           }
1296
1296
 
1305
1305
               return adb_runInstancesResponseType_reset_correlationId(_runInstancesResponseType, env);
1306
1306
           }
1307
1307
 
1308
 
 
 
1308
           
1309
1309
 
1310
1310
            /**
1311
1311
             * getter for userId.
1315
1315
                    adb_runInstancesResponseType_t* _runInstancesResponseType,
1316
1316
                    const axutil_env_t *env)
1317
1317
             {
1318
 
 
 
1318
                
1319
1319
                    AXIS2_ENV_CHECK(env, NULL);
1320
1320
                    AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, NULL);
1321
 
 
 
1321
                  
1322
1322
 
1323
1323
                return _runInstancesResponseType->property_userId;
1324
1324
             }
1332
1332
                    const axutil_env_t *env,
1333
1333
                    const axis2_char_t*  arg_userId)
1334
1334
             {
1335
 
 
 
1335
                
1336
1336
 
1337
1337
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1338
1338
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1339
 
 
 
1339
                
1340
1340
                if(_runInstancesResponseType->is_valid_userId &&
1341
1341
                        arg_userId == _runInstancesResponseType->property_userId)
1342
1342
                {
1343
 
 
1344
 
                    return AXIS2_SUCCESS;
 
1343
                    
 
1344
                    return AXIS2_SUCCESS; 
1345
1345
                }
1346
1346
 
1347
1347
                adb_runInstancesResponseType_reset_userId(_runInstancesResponseType, env);
1348
1348
 
1349
 
 
 
1349
                
1350
1350
                if(NULL == arg_userId)
1351
1351
                {
1352
1352
                    /* We are already done */
1359
1359
                            return AXIS2_FAILURE;
1360
1360
                        }
1361
1361
                        _runInstancesResponseType->is_valid_userId = AXIS2_TRUE;
1362
 
 
 
1362
                    
1363
1363
                return AXIS2_SUCCESS;
1364
1364
             }
1365
1365
 
1366
 
 
 
1366
             
1367
1367
 
1368
1368
           /**
1369
1369
            * resetter for userId
1379
1379
 
1380
1380
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1381
1381
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1382
 
 
1383
 
 
1384
 
 
1385
 
 
1386
 
 
 
1382
               
 
1383
 
 
1384
               
 
1385
            
 
1386
                
1387
1387
                if(_runInstancesResponseType->property_userId != NULL)
1388
1388
                {
1389
 
 
1390
 
 
 
1389
                   
 
1390
                   
1391
1391
                        AXIS2_FREE(env-> allocator, _runInstancesResponseType->property_userId);
1392
1392
                     _runInstancesResponseType->property_userId = NULL;
1393
1393
                }
1394
 
 
1395
 
 
1396
 
 
1397
 
                _runInstancesResponseType->is_valid_userId = AXIS2_FALSE;
 
1394
            
 
1395
                
 
1396
                
 
1397
                _runInstancesResponseType->is_valid_userId = AXIS2_FALSE; 
1398
1398
               return AXIS2_SUCCESS;
1399
1399
           }
1400
1400
 
1408
1408
           {
1409
1409
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1410
1410
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_TRUE);
1411
 
 
 
1411
               
1412
1412
               return !_runInstancesResponseType->is_valid_userId;
1413
1413
           }
1414
1414
 
1423
1423
               return adb_runInstancesResponseType_reset_userId(_runInstancesResponseType, env);
1424
1424
           }
1425
1425
 
1426
 
 
 
1426
           
1427
1427
 
1428
1428
            /**
1429
1429
             * getter for statusMessage.
1433
1433
                    adb_runInstancesResponseType_t* _runInstancesResponseType,
1434
1434
                    const axutil_env_t *env)
1435
1435
             {
1436
 
 
 
1436
                
1437
1437
                    AXIS2_ENV_CHECK(env, NULL);
1438
1438
                    AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, NULL);
1439
 
 
 
1439
                  
1440
1440
 
1441
1441
                return _runInstancesResponseType->property_statusMessage;
1442
1442
             }
1450
1450
                    const axutil_env_t *env,
1451
1451
                    const axis2_char_t*  arg_statusMessage)
1452
1452
             {
1453
 
 
 
1453
                
1454
1454
 
1455
1455
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1456
1456
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1457
 
 
 
1457
                
1458
1458
                if(_runInstancesResponseType->is_valid_statusMessage &&
1459
1459
                        arg_statusMessage == _runInstancesResponseType->property_statusMessage)
1460
1460
                {
1461
 
 
1462
 
                    return AXIS2_SUCCESS;
 
1461
                    
 
1462
                    return AXIS2_SUCCESS; 
1463
1463
                }
1464
1464
 
1465
1465
                adb_runInstancesResponseType_reset_statusMessage(_runInstancesResponseType, env);
1466
1466
 
1467
 
 
 
1467
                
1468
1468
                if(NULL == arg_statusMessage)
1469
1469
                {
1470
1470
                    /* We are already done */
1477
1477
                            return AXIS2_FAILURE;
1478
1478
                        }
1479
1479
                        _runInstancesResponseType->is_valid_statusMessage = AXIS2_TRUE;
1480
 
 
 
1480
                    
1481
1481
                return AXIS2_SUCCESS;
1482
1482
             }
1483
1483
 
1484
 
 
 
1484
             
1485
1485
 
1486
1486
           /**
1487
1487
            * resetter for statusMessage
1497
1497
 
1498
1498
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1499
1499
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1500
 
 
1501
 
 
1502
 
 
1503
 
 
1504
 
 
 
1500
               
 
1501
 
 
1502
               
 
1503
            
 
1504
                
1505
1505
                if(_runInstancesResponseType->property_statusMessage != NULL)
1506
1506
                {
1507
 
 
1508
 
 
 
1507
                   
 
1508
                   
1509
1509
                        AXIS2_FREE(env-> allocator, _runInstancesResponseType->property_statusMessage);
1510
1510
                     _runInstancesResponseType->property_statusMessage = NULL;
1511
1511
                }
1512
 
 
1513
 
 
1514
 
 
1515
 
                _runInstancesResponseType->is_valid_statusMessage = AXIS2_FALSE;
 
1512
            
 
1513
                
 
1514
                
 
1515
                _runInstancesResponseType->is_valid_statusMessage = AXIS2_FALSE; 
1516
1516
               return AXIS2_SUCCESS;
1517
1517
           }
1518
1518
 
1526
1526
           {
1527
1527
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1528
1528
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_TRUE);
1529
 
 
 
1529
               
1530
1530
               return !_runInstancesResponseType->is_valid_statusMessage;
1531
1531
           }
1532
1532
 
1541
1541
               return adb_runInstancesResponseType_reset_statusMessage(_runInstancesResponseType, env);
1542
1542
           }
1543
1543
 
1544
 
 
 
1544
           
1545
1545
 
1546
1546
            /**
1547
1547
             * getter for return.
1551
1551
                    adb_runInstancesResponseType_t* _runInstancesResponseType,
1552
1552
                    const axutil_env_t *env)
1553
1553
             {
1554
 
 
 
1554
                
1555
1555
                    AXIS2_ENV_CHECK(env, (axis2_bool_t)0);
1556
1556
                    AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, (axis2_bool_t)0);
1557
 
 
 
1557
                  
1558
1558
 
1559
1559
                return _runInstancesResponseType->property_return;
1560
1560
             }
1568
1568
                    const axutil_env_t *env,
1569
1569
                    axis2_bool_t  arg_return)
1570
1570
             {
1571
 
 
 
1571
                
1572
1572
 
1573
1573
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1574
1574
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1575
 
 
 
1575
                
1576
1576
                if(_runInstancesResponseType->is_valid_return &&
1577
1577
                        arg_return == _runInstancesResponseType->property_return)
1578
1578
                {
1579
 
 
1580
 
                    return AXIS2_SUCCESS;
 
1579
                    
 
1580
                    return AXIS2_SUCCESS; 
1581
1581
                }
1582
1582
 
1583
1583
                adb_runInstancesResponseType_reset_return(_runInstancesResponseType, env);
1584
1584
 
1585
1585
                _runInstancesResponseType->property_return = arg_return;
1586
1586
                        _runInstancesResponseType->is_valid_return = AXIS2_TRUE;
1587
 
 
 
1587
                    
1588
1588
                return AXIS2_SUCCESS;
1589
1589
             }
1590
1590
 
1591
 
 
 
1591
             
1592
1592
 
1593
1593
           /**
1594
1594
            * resetter for return
1604
1604
 
1605
1605
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1606
1606
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1607
 
 
1608
 
 
1609
 
               _runInstancesResponseType->is_valid_return = AXIS2_FALSE;
 
1607
               
 
1608
 
 
1609
               _runInstancesResponseType->is_valid_return = AXIS2_FALSE; 
1610
1610
               return AXIS2_SUCCESS;
1611
1611
           }
1612
1612
 
1620
1620
           {
1621
1621
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1622
1622
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_TRUE);
1623
 
 
 
1623
               
1624
1624
               return !_runInstancesResponseType->is_valid_return;
1625
1625
           }
1626
1626
 
1635
1635
               return adb_runInstancesResponseType_reset_return(_runInstancesResponseType, env);
1636
1636
           }
1637
1637
 
1638
 
 
 
1638
           
1639
1639
 
1640
1640
            /**
1641
1641
             * getter for instances.
1645
1645
                    adb_runInstancesResponseType_t* _runInstancesResponseType,
1646
1646
                    const axutil_env_t *env)
1647
1647
             {
1648
 
 
 
1648
                
1649
1649
                    AXIS2_ENV_CHECK(env, NULL);
1650
1650
                    AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, NULL);
1651
 
 
 
1651
                  
1652
1652
 
1653
1653
                return _runInstancesResponseType->property_instances;
1654
1654
             }
1662
1662
                    const axutil_env_t *env,
1663
1663
                    axutil_array_list_t*  arg_instances)
1664
1664
             {
1665
 
 
 
1665
                
1666
1666
                 int size = 0;
1667
1667
                 int i = 0;
1668
1668
                 axis2_bool_t non_nil_exists = AXIS2_FALSE;
1669
 
 
 
1669
                
1670
1670
 
1671
1671
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1672
1672
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1673
 
 
 
1673
                
1674
1674
                if(_runInstancesResponseType->is_valid_instances &&
1675
1675
                        arg_instances == _runInstancesResponseType->property_instances)
1676
1676
                {
1677
 
 
1678
 
                    return AXIS2_SUCCESS;
 
1677
                    
 
1678
                    return AXIS2_SUCCESS; 
1679
1679
                }
1680
1680
 
1681
 
 
 
1681
                
1682
1682
                 size = axutil_array_list_size(arg_instances, env);
1683
 
 
 
1683
                 
1684
1684
                 if (size < 0)
1685
1685
                 {
1686
1686
                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "instances has less than minOccurs(0)");
1697
1697
 
1698
1698
                 adb_runInstancesResponseType_reset_instances(_runInstancesResponseType, env);
1699
1699
 
1700
 
 
 
1700
                
1701
1701
                if(NULL == arg_instances)
1702
1702
                {
1703
1703
                    /* We are already done */
1708
1708
                        {
1709
1709
                            _runInstancesResponseType->is_valid_instances = AXIS2_TRUE;
1710
1710
                        }
1711
 
 
1712
 
 
 
1711
                        
 
1712
                    
1713
1713
                return AXIS2_SUCCESS;
1714
1714
             }
1715
1715
 
1716
 
 
 
1716
            
1717
1717
            /**
1718
1718
             * Get ith element of instances.
1719
1719
             */
1724
1724
            {
1725
1725
                adb_ccInstanceType_t* ret_val;
1726
1726
 
1727
 
 
 
1727
                
1728
1728
                    AXIS2_ENV_CHECK(env, NULL);
1729
1729
                    AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, NULL);
1730
 
 
 
1730
                  
1731
1731
 
1732
1732
                if(_runInstancesResponseType->property_instances == NULL)
1733
1733
                {
1734
1734
                    return (adb_ccInstanceType_t*)0;
1735
1735
                }
1736
1736
                ret_val = (adb_ccInstanceType_t*)axutil_array_list_get(_runInstancesResponseType->property_instances, env, i);
1737
 
 
 
1737
                
1738
1738
                    return ret_val;
1739
 
 
 
1739
                  
1740
1740
            }
1741
1741
 
1742
1742
            /**
1754
1754
                int k;
1755
1755
                axis2_bool_t non_nil_exists = AXIS2_FALSE;
1756
1756
 
1757
 
 
 
1757
                
1758
1758
 
1759
1759
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1760
1760
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1761
 
 
 
1761
                
1762
1762
                if( _runInstancesResponseType->is_valid_instances &&
1763
1763
                    _runInstancesResponseType->property_instances &&
1764
 
 
 
1764
                
1765
1765
                    arg_instances == (adb_ccInstanceType_t*)axutil_array_list_get(_runInstancesResponseType->property_instances, env, i))
1766
 
 
 
1766
                  
1767
1767
                {
1768
 
 
1769
 
                    return AXIS2_SUCCESS;
 
1768
                    
 
1769
                    return AXIS2_SUCCESS; 
1770
1770
                }
1771
1771
 
1772
 
 
 
1772
                
1773
1773
                    if(NULL == arg_instances)
1774
1774
                    {
1775
1775
                        if(_runInstancesResponseType->property_instances != NULL)
1777
1777
                            size = axutil_array_list_size(_runInstancesResponseType->property_instances, env);
1778
1778
                            for(j = 0, k = 0; j < size; j ++ )
1779
1779
                            {
1780
 
                                if(i == j) continue;
 
1780
                                if(i == j) continue; 
1781
1781
                                if(NULL != axutil_array_list_get(_runInstancesResponseType->property_instances, env, i))
1782
1782
                                {
1783
1783
                                    k ++;
1794
1794
                    {
1795
1795
                        non_nil_exists = AXIS2_TRUE;
1796
1796
                    }
1797
 
 
 
1797
                  
1798
1798
                if( k < 0)
1799
1799
                {
1800
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)");
1805
1805
                {
1806
1806
                    _runInstancesResponseType->property_instances = axutil_array_list_create(env, 10);
1807
1807
                }
1808
 
 
 
1808
                
1809
1809
                /* check whether there already exist an element */
1810
1810
                element = axutil_array_list_get(_runInstancesResponseType->property_instances, env, i);
1811
1811
                if(NULL != element)
1812
1812
                {
1813
 
 
1814
 
 
1815
 
 
 
1813
                  
 
1814
                  
 
1815
                  
1816
1816
                        adb_ccInstanceType_free((adb_ccInstanceType_t*)element, env);
1817
 
 
 
1817
                     
1818
1818
                }
1819
1819
 
1820
 
 
 
1820
                
1821
1821
                    if(!non_nil_exists)
1822
1822
                    {
1823
 
 
 
1823
                        
1824
1824
                        _runInstancesResponseType->is_valid_instances = AXIS2_FALSE;
1825
1825
                        axutil_array_list_set(_runInstancesResponseType->property_instances , env, i, NULL);
1826
 
 
 
1826
                        
1827
1827
                        return AXIS2_SUCCESS;
1828
1828
                    }
1829
 
 
 
1829
                
1830
1830
                   axutil_array_list_set(_runInstancesResponseType->property_instances , env, i, arg_instances);
1831
1831
                  _runInstancesResponseType->is_valid_instances = AXIS2_TRUE;
1832
 
 
 
1832
                
1833
1833
                return AXIS2_SUCCESS;
1834
1834
            }
1835
1835
 
1842
1842
                    const axutil_env_t *env,
1843
1843
                    adb_ccInstanceType_t* arg_instances)
1844
1844
             {
1845
 
 
 
1845
                
1846
1846
 
1847
1847
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1848
1848
                AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1849
1849
 
1850
 
 
 
1850
                
1851
1851
                    if(NULL == arg_instances)
1852
1852
                    {
1853
 
 
1854
 
                           return AXIS2_SUCCESS;
1855
 
 
 
1853
                      
 
1854
                           return AXIS2_SUCCESS; 
 
1855
                        
1856
1856
                    }
1857
 
 
 
1857
                  
1858
1858
 
1859
1859
                if(_runInstancesResponseType->property_instances == NULL)
1860
1860
                {
1864
1864
                {
1865
1865
                    AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Failed in allocatting memory for instances");
1866
1866
                    return AXIS2_FAILURE;
1867
 
 
 
1867
                    
1868
1868
                }
1869
 
 
 
1869
                
1870
1870
                   axutil_array_list_add(_runInstancesResponseType->property_instances , env, arg_instances);
1871
1871
                  _runInstancesResponseType->is_valid_instances = AXIS2_TRUE;
1872
1872
                return AXIS2_SUCCESS;
1900
1900
                return adb_runInstancesResponseType_set_instances_nil_at(_runInstancesResponseType, env, i);
1901
1901
            }
1902
1902
 
1903
 
 
 
1903
            
1904
1904
 
1905
1905
           /**
1906
1906
            * resetter for instances
1916
1916
 
1917
1917
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
1918
1918
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_FAILURE);
1919
 
 
1920
 
 
1921
 
 
 
1919
               
 
1920
 
 
1921
               
1922
1922
                  if (_runInstancesResponseType->property_instances != NULL)
1923
1923
                  {
1924
1924
                      count = axutil_array_list_size(_runInstancesResponseType->property_instances, env);
1925
1925
                      for(i = 0; i < count; i ++)
1926
1926
                      {
1927
1927
                         element = axutil_array_list_get(_runInstancesResponseType->property_instances, env, i);
1928
 
 
1929
 
 
1930
 
 
 
1928
                
 
1929
            
 
1930
                
1931
1931
                if(element != NULL)
1932
1932
                {
1933
 
 
1934
 
 
 
1933
                   
 
1934
                   
1935
1935
                        adb_ccInstanceType_free((adb_ccInstanceType_t*)element, env);
1936
1936
                     element = NULL;
1937
1937
                }
1938
 
 
1939
 
 
1940
 
 
1941
 
 
 
1938
            
 
1939
                
 
1940
                
 
1941
                
1942
1942
                      }
1943
1943
                      axutil_array_list_free(_runInstancesResponseType->property_instances, env);
1944
1944
                  }
1945
 
                _runInstancesResponseType->is_valid_instances = AXIS2_FALSE;
 
1945
                _runInstancesResponseType->is_valid_instances = AXIS2_FALSE; 
1946
1946
               return AXIS2_SUCCESS;
1947
1947
           }
1948
1948
 
1956
1956
           {
1957
1957
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1958
1958
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_TRUE);
1959
 
 
 
1959
               
1960
1960
               return !_runInstancesResponseType->is_valid_instances;
1961
1961
           }
1962
1962
 
1971
1971
               return adb_runInstancesResponseType_reset_instances(_runInstancesResponseType, env);
1972
1972
           }
1973
1973
 
1974
 
 
 
1974
           
1975
1975
           /**
1976
1976
            * Check whether instances is nill at i
1977
1977
            */
1982
1982
           {
1983
1983
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
1984
1984
               AXIS2_PARAM_CHECK(env->error, _runInstancesResponseType, AXIS2_TRUE);
1985
 
 
 
1985
               
1986
1986
               return (_runInstancesResponseType->is_valid_instances == AXIS2_FALSE ||
1987
 
                        NULL == _runInstancesResponseType->property_instances ||
 
1987
                        NULL == _runInstancesResponseType->property_instances || 
1988
1988
                        NULL == axutil_array_list_get(_runInstancesResponseType->property_instances, env, i));
1989
1989
           }
1990
1990
 
2009
2009
                if(_runInstancesResponseType->property_instances == NULL ||
2010
2010
                            _runInstancesResponseType->is_valid_instances == AXIS2_FALSE)
2011
2011
                {
2012
 
 
 
2012
                    
2013
2013
                    non_nil_exists = AXIS2_FALSE;
2014
2014
                }
2015
2015
                else
2017
2017
                    size = axutil_array_list_size(_runInstancesResponseType->property_instances, env);
2018
2018
                    for(j = 0, k = 0; j < size; j ++ )
2019
2019
                    {
2020
 
                        if(i == j) continue;
 
2020
                        if(i == j) continue; 
2021
2021
                        if(NULL != axutil_array_list_get(_runInstancesResponseType->property_instances, env, i))
2022
2022
                        {
2023
2023
                            k ++;
2029
2029
                        }
2030
2030
                    }
2031
2031
                }
2032
 
 
 
2032
                
2033
2033
 
2034
2034
                if( k < 0)
2035
2035
                {
2036
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)");
2037
2037
                       return AXIS2_FAILURE;
2038
2038
                }
2039
 
 
 
2039
 
2040
2040
                if(_runInstancesResponseType->property_instances == NULL)
2041
2041
                {
2042
2042
                    _runInstancesResponseType->is_valid_instances = AXIS2_FALSE;
2043
 
 
 
2043
                    
2044
2044
                    return AXIS2_SUCCESS;
2045
2045
                }
2046
2046
 
2048
2048
                element = axutil_array_list_get(_runInstancesResponseType->property_instances, env, i);
2049
2049
                if(NULL != element)
2050
2050
                {
2051
 
 
2052
 
 
2053
 
 
 
2051
                  
 
2052
                  
 
2053
                  
2054
2054
                        adb_ccInstanceType_free((adb_ccInstanceType_t*)element, env);
2055
 
 
 
2055
                     
2056
2056
                }
2057
2057
 
2058
 
 
 
2058
                
2059
2059
                    if(!non_nil_exists)
2060
2060
                    {
2061
 
 
 
2061
                        
2062
2062
                        _runInstancesResponseType->is_valid_instances = AXIS2_FALSE;
2063
2063
                        axutil_array_list_set(_runInstancesResponseType->property_instances , env, i, NULL);
2064
2064
                        return AXIS2_SUCCESS;
2065
2065
                    }
2066
 
 
2067
 
 
2068
 
 
 
2066
                
 
2067
 
 
2068
                
2069
2069
                axutil_array_list_set(_runInstancesResponseType->property_instances , env, i, NULL);
2070
 
 
 
2070
                
2071
2071
                return AXIS2_SUCCESS;
2072
2072
 
2073
2073
           }
2074
2074
 
2075
 
 
 
2075
           
2076
2076