~ubuntu-virt/ubuntu/maverick/eucalyptus/2.0

« back to all changes in this revision

Viewing changes to cluster/generated/adb_describeNetworksResponseType.c

  • Committer: Dave Walker (Daviey)
  • Date: 2010-06-21 12:59:20 UTC
  • mfrom: (1048.1.14 ubuntu)
  • Revision ID: davewalker@ubuntu.com-20100621125920-60uhixwq174elnj1
* New major upstream version merge, 1.7 (r1200).
* debian/patches/:
  - 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: Refreshed.
  - 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. 

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
 
 
3
        /**
 
4
         * adb_describeNetworksResponseType.c
 
5
         *
 
6
         * This file was auto-generated from WSDL
 
7
         * by the Apache Axis2/C version: SNAPSHOT  Built on : Mar 10, 2008 (08:35:52 GMT+00:00)
 
8
         */
 
9
 
 
10
        #include "adb_describeNetworksResponseType.h"
 
11
 
 
12
                /*
 
13
                 * This type was generated from the piece of schema that had
 
14
                 * name = describeNetworksResponseType
 
15
                 * Namespace URI = http://eucalyptus.ucsb.edu/
 
16
                 * Namespace Prefix = ns1
 
17
                 */
 
18
 
 
19
 
 
20
 
 
21
        struct adb_describeNetworksResponseType
 
22
        {
 
23
            axis2_char_t* property_correlationId;
 
24
 
 
25
 
 
26
                axis2_bool_t is_valid_correlationId;
 
27
 
 
28
 
 
29
            axis2_char_t* property_userId;
 
30
 
 
31
 
 
32
                axis2_bool_t is_valid_userId;
 
33
 
 
34
 
 
35
            axis2_char_t* property_statusMessage;
 
36
 
 
37
 
 
38
                axis2_bool_t is_valid_statusMessage;
 
39
 
 
40
 
 
41
            axis2_bool_t property_return;
 
42
 
 
43
 
 
44
                axis2_bool_t is_valid_return;
 
45
 
 
46
 
 
47
            int property_mode;
 
48
 
 
49
 
 
50
                axis2_bool_t is_valid_mode;
 
51
 
 
52
 
 
53
            int property_addrsPerNet;
 
54
 
 
55
 
 
56
                axis2_bool_t is_valid_addrsPerNet;
 
57
 
 
58
 
 
59
            axutil_array_list_t* property_activeNetworks;
 
60
 
 
61
 
 
62
                axis2_bool_t is_valid_activeNetworks;
 
63
 
 
64
 
 
65
 
 
66
        };
 
67
 
 
68
 
 
69
       /************************* Private Function prototypes ********************************/
 
70
 
 
71
 
 
72
                axis2_status_t AXIS2_CALL
 
73
                adb_describeNetworksResponseType_set_correlationId_nil(
 
74
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
75
                        const axutil_env_t *env);
 
76
 
 
77
 
 
78
                axis2_status_t AXIS2_CALL
 
79
                adb_describeNetworksResponseType_set_userId_nil(
 
80
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
81
                        const axutil_env_t *env);
 
82
 
 
83
 
 
84
                axis2_status_t AXIS2_CALL
 
85
                adb_describeNetworksResponseType_set_return_nil(
 
86
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
87
                        const axutil_env_t *env);
 
88
 
 
89
 
 
90
                axis2_status_t AXIS2_CALL
 
91
                adb_describeNetworksResponseType_set_mode_nil(
 
92
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
93
                        const axutil_env_t *env);
 
94
 
 
95
 
 
96
                axis2_status_t AXIS2_CALL
 
97
                adb_describeNetworksResponseType_set_addrsPerNet_nil(
 
98
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
99
                        const axutil_env_t *env);
 
100
 
 
101
                 axis2_status_t AXIS2_CALL
 
102
                 adb_describeNetworksResponseType_set_activeNetworks_nil_at(
 
103
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
104
                        const axutil_env_t *env, int i);
 
105
 
 
106
 
 
107
                axis2_status_t AXIS2_CALL
 
108
                adb_describeNetworksResponseType_set_activeNetworks_nil(
 
109
                        adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
110
                        const axutil_env_t *env);
 
111
 
 
112
 
 
113
 
 
114
       /************************* Function Implmentations ********************************/
 
115
        adb_describeNetworksResponseType_t* AXIS2_CALL
 
116
        adb_describeNetworksResponseType_create(
 
117
            const axutil_env_t *env)
 
118
        {
 
119
            adb_describeNetworksResponseType_t *_describeNetworksResponseType = NULL;
 
120
 
 
121
            AXIS2_ENV_CHECK(env, NULL);
 
122
 
 
123
            _describeNetworksResponseType = (adb_describeNetworksResponseType_t *) AXIS2_MALLOC(env->
 
124
                allocator, sizeof(adb_describeNetworksResponseType_t));
 
125
 
 
126
            if(NULL == _describeNetworksResponseType)
 
127
            {
 
128
                AXIS2_ERROR_SET(env->error, AXIS2_ERROR_NO_MEMORY, AXIS2_FAILURE);
 
129
                return NULL;
 
130
            }
 
131
 
 
132
            memset(_describeNetworksResponseType, 0, sizeof(adb_describeNetworksResponseType_t));
 
133
 
 
134
            _describeNetworksResponseType->property_correlationId  = NULL;
 
135
                  _describeNetworksResponseType->is_valid_correlationId  = AXIS2_FALSE;
 
136
            _describeNetworksResponseType->property_userId  = NULL;
 
137
                  _describeNetworksResponseType->is_valid_userId  = AXIS2_FALSE;
 
138
            _describeNetworksResponseType->property_statusMessage  = NULL;
 
139
                  _describeNetworksResponseType->is_valid_statusMessage  = AXIS2_FALSE;
 
140
            _describeNetworksResponseType->is_valid_return  = AXIS2_FALSE;
 
141
            _describeNetworksResponseType->is_valid_mode  = AXIS2_FALSE;
 
142
            _describeNetworksResponseType->is_valid_addrsPerNet  = AXIS2_FALSE;
 
143
            _describeNetworksResponseType->property_activeNetworks  = NULL;
 
144
                  _describeNetworksResponseType->is_valid_activeNetworks  = AXIS2_FALSE;
 
145
 
 
146
 
 
147
            return _describeNetworksResponseType;
 
148
        }
 
149
 
 
150
        axis2_status_t AXIS2_CALL
 
151
        adb_describeNetworksResponseType_free (
 
152
                adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
153
                const axutil_env_t *env)
 
154
        {
 
155
 
 
156
                int i = 0;
 
157
                int count = 0;
 
158
                void *element = NULL;
 
159
 
 
160
 
 
161
            AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
162
            AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
163
 
 
164
            adb_describeNetworksResponseType_reset_correlationId(_describeNetworksResponseType, env);
 
165
            adb_describeNetworksResponseType_reset_userId(_describeNetworksResponseType, env);
 
166
            adb_describeNetworksResponseType_reset_statusMessage(_describeNetworksResponseType, env);
 
167
            adb_describeNetworksResponseType_reset_return(_describeNetworksResponseType, env);
 
168
            adb_describeNetworksResponseType_reset_mode(_describeNetworksResponseType, env);
 
169
            adb_describeNetworksResponseType_reset_addrsPerNet(_describeNetworksResponseType, env);
 
170
            adb_describeNetworksResponseType_reset_activeNetworks(_describeNetworksResponseType, env);
 
171
 
 
172
 
 
173
            if(_describeNetworksResponseType)
 
174
            {
 
175
                AXIS2_FREE(env->allocator, _describeNetworksResponseType);
 
176
                _describeNetworksResponseType = NULL;
 
177
            }
 
178
            return AXIS2_SUCCESS;
 
179
        }
 
180
 
 
181
 
 
182
 
 
183
 
 
184
        axis2_status_t AXIS2_CALL
 
185
        adb_describeNetworksResponseType_deserialize(
 
186
                adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
187
                const axutil_env_t *env,
 
188
                axiom_node_t **dp_parent,
 
189
                axis2_bool_t *dp_is_early_node_valid,
 
190
                axis2_bool_t dont_care_minoccurs)
 
191
        {
 
192
          axiom_node_t *parent = *dp_parent;
 
193
 
 
194
          axis2_status_t status = AXIS2_SUCCESS;
 
195
 
 
196
              void *element = NULL;
 
197
 
 
198
             axis2_char_t* text_value = NULL;
 
199
             axutil_qname_t *qname = NULL;
 
200
 
 
201
               int i = 0;
 
202
               axutil_array_list_t *arr_list = NULL;
 
203
 
 
204
               int sequence_broken = 0;
 
205
               axiom_node_t *tmp_node = NULL;
 
206
 
 
207
            axutil_qname_t *element_qname = NULL;
 
208
 
 
209
               axiom_node_t *first_node = NULL;
 
210
               axis2_bool_t is_early_node_valid = AXIS2_TRUE;
 
211
               axiom_node_t *current_node = NULL;
 
212
               axiom_element_t *current_element = NULL;
 
213
 
 
214
            AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
215
            AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
216
 
 
217
 
 
218
 
 
219
              while(parent && axiom_node_get_node_type(parent, env) != AXIOM_ELEMENT)
 
220
              {
 
221
                  parent = axiom_node_get_next_sibling(parent, env);
 
222
              }
 
223
              if (NULL == parent)
 
224
              {
 
225
                /* This should be checked before everything */
 
226
                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI,
 
227
                            "Failed in building adb object for describeNetworksResponseType : "
 
228
                            "NULL elemenet can not be passed to deserialize");
 
229
                return AXIS2_FAILURE;
 
230
              }
 
231
 
 
232
 
 
233
                      first_node = axiom_node_get_first_child(parent, env);
 
234
 
 
235
 
 
236
 
 
237
 
 
238
                     /*
 
239
                      * building correlationId element
 
240
                      */
 
241
 
 
242
 
 
243
 
 
244
                                   current_node = first_node;
 
245
                                   is_early_node_valid = AXIS2_FALSE;
 
246
 
 
247
 
 
248
                                    while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
249
                                    {
 
250
                                        current_node = axiom_node_get_next_sibling(current_node, env);
 
251
                                    }
 
252
                                    if(current_node != NULL)
 
253
                                    {
 
254
                                        current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
255
                                        qname = axiom_element_get_qname(current_element, env, current_node);
 
256
                                    }
 
257
 
 
258
                                 element_qname = axutil_qname_create(env, "correlationId", "http://eucalyptus.ucsb.edu/", NULL);
 
259
 
 
260
 
 
261
                           if (
 
262
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
 
263
                           {
 
264
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
 
265
                              {
 
266
                                is_early_node_valid = AXIS2_TRUE;
 
267
                              }
 
268
 
 
269
 
 
270
                                      text_value = axiom_element_get_text(current_element, env, current_node);
 
271
                                      if(text_value != NULL)
 
272
                                      {
 
273
                                            status = adb_describeNetworksResponseType_set_correlationId(_describeNetworksResponseType, env,
 
274
                                                               text_value);
 
275
                                      }
 
276
 
 
277
                                      else
 
278
                                      {
 
279
                                            /*
 
280
                                             * axis2_qname_t *qname = NULL;
 
281
                                             * axiom_attribute_t *the_attri = NULL;
 
282
                                             *
 
283
                                             * qname = axutil_qname_create(env, "nil", "http://www.w3.org/2001/XMLSchema-instance", "xsi");
 
284
                                             * the_attri = axiom_element_get_attribute(current_element, env, qname);
 
285
                                             */
 
286
                                            /* currently thereis a bug in the axiom_element_get_attribute, so we have to go to this bad method */
 
287
 
 
288
                                            axiom_attribute_t *the_attri = NULL;
 
289
                                            axis2_char_t *attrib_text = NULL;
 
290
                                            axutil_hash_t *attribute_hash = NULL;
 
291
 
 
292
                                            attribute_hash = axiom_element_get_all_attributes(current_element, env);
 
293
 
 
294
                                            attrib_text = NULL;
 
295
                                            if(attribute_hash)
 
296
                                            {
 
297
                                                 axutil_hash_index_t *hi;
 
298
                                                 void *val;
 
299
                                                 const void *key;
 
300
 
 
301
                                                 for (hi = axutil_hash_first(attribute_hash, env); hi; hi = axutil_hash_next(env, hi))
 
302
                                                 {
 
303
                                                     axutil_hash_this(hi, &key, NULL, &val);
 
304
 
 
305
                                                     if(strstr((axis2_char_t*)key, "nil|http://www.w3.org/2001/XMLSchema-instance"))
 
306
                                                     {
 
307
                                                         the_attri = (axiom_attribute_t*)val;
 
308
                                                         break;
 
309
                                                     }
 
310
                                                 }
 
311
                                            }
 
312
 
 
313
                                            if(the_attri)
 
314
                                            {
 
315
                                                attrib_text = axiom_attribute_get_value(the_attri, env);
 
316
                                            }
 
317
                                            else
 
318
                                            {
 
319
                                                /* this is hoping that attribute is stored in "http://www.w3.org/2001/XMLSchema-instance", this happnes when name is in default namespace */
 
320
                                                attrib_text = axiom_element_get_attribute_value_by_name(current_element, env, "nil");
 
321
                                            }
 
322
 
 
323
                                            if(attrib_text && 0 == axutil_strcmp(attrib_text, "1"))
 
324
                                            {
 
325
                                                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element correlationId");
 
326
                                                status = AXIS2_FAILURE;
 
327
                                            }
 
328
                                            else
 
329
                                            {
 
330
                                                /* after all, we found this is a empty string */
 
331
                                                status = adb_describeNetworksResponseType_set_correlationId(_describeNetworksResponseType, env,
 
332
                                                                   "");
 
333
                                            }
 
334
                                      }
 
335
 
 
336
                                 if(AXIS2_FAILURE ==  status)
 
337
                                 {
 
338
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for correlationId ");
 
339
                                     if(element_qname)
 
340
                                     {
 
341
                                         axutil_qname_free(element_qname, env);
 
342
                                     }
 
343
                                     return AXIS2_FAILURE;
 
344
                                 }
 
345
                              }
 
346
 
 
347
                  if(element_qname)
 
348
                  {
 
349
                     axutil_qname_free(element_qname, env);
 
350
                     element_qname = NULL;
 
351
                  }
 
352
 
 
353
 
 
354
 
 
355
                     /*
 
356
                      * building userId element
 
357
                      */
 
358
 
 
359
 
 
360
 
 
361
                                    /*
 
362
                                     * because elements are ordered this works fine
 
363
                                     */
 
364
 
 
365
 
 
366
                                   if(current_node != NULL && is_early_node_valid)
 
367
                                   {
 
368
                                       current_node = axiom_node_get_next_sibling(current_node, env);
 
369
 
 
370
 
 
371
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
372
                                        {
 
373
                                            current_node = axiom_node_get_next_sibling(current_node, env);
 
374
                                        }
 
375
                                        if(current_node != NULL)
 
376
                                        {
 
377
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
378
                                            qname = axiom_element_get_qname(current_element, env, current_node);
 
379
                                        }
 
380
 
 
381
                                   }
 
382
                                   is_early_node_valid = AXIS2_FALSE;
 
383
 
 
384
                                 element_qname = axutil_qname_create(env, "userId", "http://eucalyptus.ucsb.edu/", NULL);
 
385
 
 
386
 
 
387
                           if (
 
388
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
 
389
                           {
 
390
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
 
391
                              {
 
392
                                is_early_node_valid = AXIS2_TRUE;
 
393
                              }
 
394
 
 
395
 
 
396
                                      text_value = axiom_element_get_text(current_element, env, current_node);
 
397
                                      if(text_value != NULL)
 
398
                                      {
 
399
                                            status = adb_describeNetworksResponseType_set_userId(_describeNetworksResponseType, env,
 
400
                                                               text_value);
 
401
                                      }
 
402
 
 
403
                                      else
 
404
                                      {
 
405
                                            /*
 
406
                                             * axis2_qname_t *qname = NULL;
 
407
                                             * axiom_attribute_t *the_attri = NULL;
 
408
                                             *
 
409
                                             * qname = axutil_qname_create(env, "nil", "http://www.w3.org/2001/XMLSchema-instance", "xsi");
 
410
                                             * the_attri = axiom_element_get_attribute(current_element, env, qname);
 
411
                                             */
 
412
                                            /* currently thereis a bug in the axiom_element_get_attribute, so we have to go to this bad method */
 
413
 
 
414
                                            axiom_attribute_t *the_attri = NULL;
 
415
                                            axis2_char_t *attrib_text = NULL;
 
416
                                            axutil_hash_t *attribute_hash = NULL;
 
417
 
 
418
                                            attribute_hash = axiom_element_get_all_attributes(current_element, env);
 
419
 
 
420
                                            attrib_text = NULL;
 
421
                                            if(attribute_hash)
 
422
                                            {
 
423
                                                 axutil_hash_index_t *hi;
 
424
                                                 void *val;
 
425
                                                 const void *key;
 
426
 
 
427
                                                 for (hi = axutil_hash_first(attribute_hash, env); hi; hi = axutil_hash_next(env, hi))
 
428
                                                 {
 
429
                                                     axutil_hash_this(hi, &key, NULL, &val);
 
430
 
 
431
                                                     if(strstr((axis2_char_t*)key, "nil|http://www.w3.org/2001/XMLSchema-instance"))
 
432
                                                     {
 
433
                                                         the_attri = (axiom_attribute_t*)val;
 
434
                                                         break;
 
435
                                                     }
 
436
                                                 }
 
437
                                            }
 
438
 
 
439
                                            if(the_attri)
 
440
                                            {
 
441
                                                attrib_text = axiom_attribute_get_value(the_attri, env);
 
442
                                            }
 
443
                                            else
 
444
                                            {
 
445
                                                /* this is hoping that attribute is stored in "http://www.w3.org/2001/XMLSchema-instance", this happnes when name is in default namespace */
 
446
                                                attrib_text = axiom_element_get_attribute_value_by_name(current_element, env, "nil");
 
447
                                            }
 
448
 
 
449
                                            if(attrib_text && 0 == axutil_strcmp(attrib_text, "1"))
 
450
                                            {
 
451
                                                AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element userId");
 
452
                                                status = AXIS2_FAILURE;
 
453
                                            }
 
454
                                            else
 
455
                                            {
 
456
                                                /* after all, we found this is a empty string */
 
457
                                                status = adb_describeNetworksResponseType_set_userId(_describeNetworksResponseType, env,
 
458
                                                                   "");
 
459
                                            }
 
460
                                      }
 
461
 
 
462
                                 if(AXIS2_FAILURE ==  status)
 
463
                                 {
 
464
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for userId ");
 
465
                                     if(element_qname)
 
466
                                     {
 
467
                                         axutil_qname_free(element_qname, env);
 
468
                                     }
 
469
                                     return AXIS2_FAILURE;
 
470
                                 }
 
471
                              }
 
472
 
 
473
                  if(element_qname)
 
474
                  {
 
475
                     axutil_qname_free(element_qname, env);
 
476
                     element_qname = NULL;
 
477
                  }
 
478
 
 
479
 
 
480
 
 
481
                     /*
 
482
                      * building statusMessage element
 
483
                      */
 
484
 
 
485
 
 
486
 
 
487
                                    /*
 
488
                                     * because elements are ordered this works fine
 
489
                                     */
 
490
 
 
491
 
 
492
                                   if(current_node != NULL && is_early_node_valid)
 
493
                                   {
 
494
                                       current_node = axiom_node_get_next_sibling(current_node, env);
 
495
 
 
496
 
 
497
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
498
                                        {
 
499
                                            current_node = axiom_node_get_next_sibling(current_node, env);
 
500
                                        }
 
501
                                        if(current_node != NULL)
 
502
                                        {
 
503
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
504
                                            qname = axiom_element_get_qname(current_element, env, current_node);
 
505
                                        }
 
506
 
 
507
                                   }
 
508
                                   is_early_node_valid = AXIS2_FALSE;
 
509
 
 
510
                                 element_qname = axutil_qname_create(env, "statusMessage", "http://eucalyptus.ucsb.edu/", NULL);
 
511
 
 
512
 
 
513
                           if (
 
514
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
 
515
                           {
 
516
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
 
517
                              {
 
518
                                is_early_node_valid = AXIS2_TRUE;
 
519
                              }
 
520
 
 
521
 
 
522
                                      text_value = axiom_element_get_text(current_element, env, current_node);
 
523
                                      if(text_value != NULL)
 
524
                                      {
 
525
                                            status = adb_describeNetworksResponseType_set_statusMessage(_describeNetworksResponseType, env,
 
526
                                                               text_value);
 
527
                                      }
 
528
 
 
529
                                 if(AXIS2_FAILURE ==  status)
 
530
                                 {
 
531
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for statusMessage ");
 
532
                                     if(element_qname)
 
533
                                     {
 
534
                                         axutil_qname_free(element_qname, env);
 
535
                                     }
 
536
                                     return AXIS2_FAILURE;
 
537
                                 }
 
538
                              }
 
539
 
 
540
                  if(element_qname)
 
541
                  {
 
542
                     axutil_qname_free(element_qname, env);
 
543
                     element_qname = NULL;
 
544
                  }
 
545
 
 
546
 
 
547
 
 
548
                     /*
 
549
                      * building return element
 
550
                      */
 
551
 
 
552
 
 
553
 
 
554
                                    /*
 
555
                                     * because elements are ordered this works fine
 
556
                                     */
 
557
 
 
558
 
 
559
                                   if(current_node != NULL && is_early_node_valid)
 
560
                                   {
 
561
                                       current_node = axiom_node_get_next_sibling(current_node, env);
 
562
 
 
563
 
 
564
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
565
                                        {
 
566
                                            current_node = axiom_node_get_next_sibling(current_node, env);
 
567
                                        }
 
568
                                        if(current_node != NULL)
 
569
                                        {
 
570
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
571
                                            qname = axiom_element_get_qname(current_element, env, current_node);
 
572
                                        }
 
573
 
 
574
                                   }
 
575
                                   is_early_node_valid = AXIS2_FALSE;
 
576
 
 
577
                                 element_qname = axutil_qname_create(env, "return", "http://eucalyptus.ucsb.edu/", NULL);
 
578
 
 
579
 
 
580
                           if (
 
581
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
 
582
                           {
 
583
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
 
584
                              {
 
585
                                is_early_node_valid = AXIS2_TRUE;
 
586
                              }
 
587
 
 
588
 
 
589
                                      text_value = axiom_element_get_text(current_element, env, current_node);
 
590
                                      if(text_value != NULL)
 
591
                                      {
 
592
                                            if (!axutil_strcasecmp(text_value , "true"))
 
593
                                            {
 
594
                                                status = adb_describeNetworksResponseType_set_return(_describeNetworksResponseType, env,
 
595
                                                                 AXIS2_TRUE);
 
596
                                            }
 
597
                                            else
 
598
                                            {
 
599
                                                status = adb_describeNetworksResponseType_set_return(_describeNetworksResponseType, env,
 
600
                                                                      AXIS2_FALSE);
 
601
                                            }
 
602
                                      }
 
603
 
 
604
                                      else
 
605
                                      {
 
606
                                          AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element return");
 
607
                                          status = AXIS2_FAILURE;
 
608
                                      }
 
609
 
 
610
                                 if(AXIS2_FAILURE ==  status)
 
611
                                 {
 
612
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for return ");
 
613
                                     if(element_qname)
 
614
                                     {
 
615
                                         axutil_qname_free(element_qname, env);
 
616
                                     }
 
617
                                     return AXIS2_FAILURE;
 
618
                                 }
 
619
                              }
 
620
 
 
621
                  if(element_qname)
 
622
                  {
 
623
                     axutil_qname_free(element_qname, env);
 
624
                     element_qname = NULL;
 
625
                  }
 
626
 
 
627
 
 
628
 
 
629
                     /*
 
630
                      * building mode element
 
631
                      */
 
632
 
 
633
 
 
634
 
 
635
                                    /*
 
636
                                     * because elements are ordered this works fine
 
637
                                     */
 
638
 
 
639
 
 
640
                                   if(current_node != NULL && is_early_node_valid)
 
641
                                   {
 
642
                                       current_node = axiom_node_get_next_sibling(current_node, env);
 
643
 
 
644
 
 
645
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
646
                                        {
 
647
                                            current_node = axiom_node_get_next_sibling(current_node, env);
 
648
                                        }
 
649
                                        if(current_node != NULL)
 
650
                                        {
 
651
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
652
                                            qname = axiom_element_get_qname(current_element, env, current_node);
 
653
                                        }
 
654
 
 
655
                                   }
 
656
                                   is_early_node_valid = AXIS2_FALSE;
 
657
 
 
658
                                 element_qname = axutil_qname_create(env, "mode", "http://eucalyptus.ucsb.edu/", NULL);
 
659
 
 
660
 
 
661
                           if (
 
662
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
 
663
                           {
 
664
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
 
665
                              {
 
666
                                is_early_node_valid = AXIS2_TRUE;
 
667
                              }
 
668
 
 
669
 
 
670
                                      text_value = axiom_element_get_text(current_element, env, current_node);
 
671
                                      if(text_value != NULL)
 
672
                                      {
 
673
                                            status = adb_describeNetworksResponseType_set_mode(_describeNetworksResponseType, env,
 
674
                                                                   atoi(text_value));
 
675
                                      }
 
676
 
 
677
                                      else
 
678
                                      {
 
679
                                          AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element mode");
 
680
                                          status = AXIS2_FAILURE;
 
681
                                      }
 
682
 
 
683
                                 if(AXIS2_FAILURE ==  status)
 
684
                                 {
 
685
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for mode ");
 
686
                                     if(element_qname)
 
687
                                     {
 
688
                                         axutil_qname_free(element_qname, env);
 
689
                                     }
 
690
                                     return AXIS2_FAILURE;
 
691
                                 }
 
692
                              }
 
693
 
 
694
                  if(element_qname)
 
695
                  {
 
696
                     axutil_qname_free(element_qname, env);
 
697
                     element_qname = NULL;
 
698
                  }
 
699
 
 
700
 
 
701
 
 
702
                     /*
 
703
                      * building addrsPerNet element
 
704
                      */
 
705
 
 
706
 
 
707
 
 
708
                                    /*
 
709
                                     * because elements are ordered this works fine
 
710
                                     */
 
711
 
 
712
 
 
713
                                   if(current_node != NULL && is_early_node_valid)
 
714
                                   {
 
715
                                       current_node = axiom_node_get_next_sibling(current_node, env);
 
716
 
 
717
 
 
718
                                        while(current_node && axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
719
                                        {
 
720
                                            current_node = axiom_node_get_next_sibling(current_node, env);
 
721
                                        }
 
722
                                        if(current_node != NULL)
 
723
                                        {
 
724
                                            current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
725
                                            qname = axiom_element_get_qname(current_element, env, current_node);
 
726
                                        }
 
727
 
 
728
                                   }
 
729
                                   is_early_node_valid = AXIS2_FALSE;
 
730
 
 
731
                                 element_qname = axutil_qname_create(env, "addrsPerNet", "http://eucalyptus.ucsb.edu/", NULL);
 
732
 
 
733
 
 
734
                           if (
 
735
                                (current_node   && current_element && (axutil_qname_equals(element_qname, env, qname))))
 
736
                           {
 
737
                              if( current_node   && current_element && (axutil_qname_equals(element_qname, env, qname)))
 
738
                              {
 
739
                                is_early_node_valid = AXIS2_TRUE;
 
740
                              }
 
741
 
 
742
 
 
743
                                      text_value = axiom_element_get_text(current_element, env, current_node);
 
744
                                      if(text_value != NULL)
 
745
                                      {
 
746
                                            status = adb_describeNetworksResponseType_set_addrsPerNet(_describeNetworksResponseType, env,
 
747
                                                                   atoi(text_value));
 
748
                                      }
 
749
 
 
750
                                      else
 
751
                                      {
 
752
                                          AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "NULL value is set to a non nillable element addrsPerNet");
 
753
                                          status = AXIS2_FAILURE;
 
754
                                      }
 
755
 
 
756
                                 if(AXIS2_FAILURE ==  status)
 
757
                                 {
 
758
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for addrsPerNet ");
 
759
                                     if(element_qname)
 
760
                                     {
 
761
                                         axutil_qname_free(element_qname, env);
 
762
                                     }
 
763
                                     return AXIS2_FAILURE;
 
764
                                 }
 
765
                              }
 
766
 
 
767
                  if(element_qname)
 
768
                  {
 
769
                     axutil_qname_free(element_qname, env);
 
770
                     element_qname = NULL;
 
771
                  }
 
772
 
 
773
                    /*
 
774
                     * building activeNetworks array
 
775
                     */
 
776
                       arr_list = axutil_array_list_create(env, 10);
 
777
 
 
778
 
 
779
 
 
780
                     /*
 
781
                      * building activeNetworks element
 
782
                      */
 
783
 
 
784
 
 
785
 
 
786
                                    element_qname = axutil_qname_create(env, "activeNetworks", "http://eucalyptus.ucsb.edu/", NULL);
 
787
 
 
788
 
 
789
                               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;)
 
790
 
 
791
                               {
 
792
                                  if(axiom_node_get_node_type(current_node, env) != AXIOM_ELEMENT)
 
793
                                  {
 
794
                                     current_node =axiom_node_get_next_sibling(current_node, env);
 
795
                                     is_early_node_valid = AXIS2_FALSE;
 
796
                                     continue;
 
797
                                  }
 
798
 
 
799
                                  current_element = (axiom_element_t *)axiom_node_get_data_element(current_node, env);
 
800
                                  qname = axiom_element_get_qname(current_element, env, current_node);
 
801
 
 
802
                                  if (axutil_qname_equals(element_qname, env, qname))
 
803
                                  {
 
804
 
 
805
                                      is_early_node_valid = AXIS2_TRUE;
 
806
 
 
807
 
 
808
                                          element = (void*)adb_networkType_create(env);
 
809
 
 
810
                                          status =  adb_networkType_deserialize((adb_networkType_t*)element, env,
 
811
                                                                                 &current_node, &is_early_node_valid, AXIS2_FALSE);
 
812
 
 
813
                                          if(AXIS2_FAILURE ==  status)
 
814
                                          {
 
815
                                              AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in building element activeNetworks ");
 
816
                                          }
 
817
                                          else
 
818
                                          {
 
819
                                            axutil_array_list_add_at(arr_list, env, i, element);
 
820
                                          }
 
821
 
 
822
                                     if(AXIS2_FAILURE ==  status)
 
823
                                     {
 
824
                                         AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "failed in setting the value for activeNetworks ");
 
825
                                         if(element_qname)
 
826
                                         {
 
827
                                            axutil_qname_free(element_qname, env);
 
828
                                         }
 
829
                                         if(arr_list)
 
830
                                         {
 
831
                                            axutil_array_list_free(arr_list, env);
 
832
                                         }
 
833
                                         return AXIS2_FAILURE;
 
834
                                     }
 
835
 
 
836
                                     i ++;
 
837
                                    current_node = axiom_node_get_next_sibling(current_node, env);
 
838
                                  }
 
839
                                  else
 
840
                                  {
 
841
                                      is_early_node_valid = AXIS2_FALSE;
 
842
                                      sequence_broken = 1;
 
843
                                  }
 
844
 
 
845
                               }
 
846
 
 
847
 
 
848
                                   if (i < 0)
 
849
                                   {
 
850
                                     /* found element out of order */
 
851
                                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "activeNetworks (@minOccurs = '0') only have %d elements", i);
 
852
                                     if(element_qname)
 
853
                                     {
 
854
                                        axutil_qname_free(element_qname, env);
 
855
                                     }
 
856
                                     if(arr_list)
 
857
                                     {
 
858
                                        axutil_array_list_free(arr_list, env);
 
859
                                     }
 
860
                                     return AXIS2_FAILURE;
 
861
                                   }
 
862
 
 
863
 
 
864
                               if(0 == axutil_array_list_size(arr_list,env))
 
865
                               {
 
866
                                    axutil_array_list_free(arr_list, env);
 
867
                               }
 
868
                               else
 
869
                               {
 
870
                                    status = adb_describeNetworksResponseType_set_activeNetworks(_describeNetworksResponseType, env,
 
871
                                                                   arr_list);
 
872
                               }
 
873
 
 
874
 
 
875
                  if(element_qname)
 
876
                  {
 
877
                     axutil_qname_free(element_qname, env);
 
878
                     element_qname = NULL;
 
879
                  }
 
880
 
 
881
          return status;
 
882
       }
 
883
 
 
884
          axis2_bool_t AXIS2_CALL
 
885
          adb_describeNetworksResponseType_is_particle()
 
886
          {
 
887
 
 
888
                 return AXIS2_FALSE;
 
889
 
 
890
          }
 
891
 
 
892
 
 
893
          void AXIS2_CALL
 
894
          adb_describeNetworksResponseType_declare_parent_namespaces(
 
895
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
896
                    const axutil_env_t *env, axiom_element_t *parent_element,
 
897
                    axutil_hash_t *namespaces, int *next_ns_index)
 
898
          {
 
899
 
 
900
                  /* Here this is an empty function, Nothing to declare */
 
901
 
 
902
          }
 
903
 
 
904
 
 
905
 
 
906
        axiom_node_t* AXIS2_CALL
 
907
        adb_describeNetworksResponseType_serialize(
 
908
                adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
909
                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)
 
910
        {
 
911
 
 
912
 
 
913
             axis2_char_t *string_to_stream;
 
914
 
 
915
 
 
916
         axiom_node_t *current_node = NULL;
 
917
         int tag_closed = 0;
 
918
 
 
919
 
 
920
 
 
921
                axiom_namespace_t *ns1 = NULL;
 
922
 
 
923
                axis2_char_t *qname_uri = NULL;
 
924
                axis2_char_t *qname_prefix = NULL;
 
925
                axis2_char_t *p_prefix = NULL;
 
926
                axis2_bool_t ns_already_defined;
 
927
 
 
928
               int i = 0;
 
929
               int count = 0;
 
930
               void *element = NULL;
 
931
 
 
932
                    axis2_char_t *text_value_1;
 
933
                    axis2_char_t *text_value_1_temp;
 
934
 
 
935
                    axis2_char_t *text_value_2;
 
936
                    axis2_char_t *text_value_2_temp;
 
937
 
 
938
                    axis2_char_t *text_value_3;
 
939
                    axis2_char_t *text_value_3_temp;
 
940
 
 
941
                    axis2_char_t text_value_4[64];
 
942
 
 
943
                    axis2_char_t text_value_5[64];
 
944
 
 
945
                    axis2_char_t text_value_6[64];
 
946
 
 
947
                    axis2_char_t text_value_7[64];
 
948
 
 
949
               axis2_char_t *start_input_str = NULL;
 
950
               axis2_char_t *end_input_str = NULL;
 
951
               unsigned int start_input_str_len = 0;
 
952
               unsigned int end_input_str_len = 0;
 
953
 
 
954
 
 
955
               axiom_data_source_t *data_source = NULL;
 
956
               axutil_stream_t *stream = NULL;
 
957
 
 
958
 
 
959
 
 
960
            AXIS2_ENV_CHECK(env, NULL);
 
961
            AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, NULL);
 
962
 
 
963
 
 
964
                    current_node = parent;
 
965
                    data_source = (axiom_data_source_t *)axiom_node_get_data_element(current_node, env);
 
966
                    if (!data_source)
 
967
                        return NULL;
 
968
                    stream = axiom_data_source_get_stream(data_source, env); /* assume parent is of type data source */
 
969
                    if (!stream)
 
970
                        return NULL;
 
971
 
 
972
            if(!parent_tag_closed)
 
973
            {
 
974
 
 
975
              string_to_stream = ">";
 
976
              axutil_stream_write(stream, env, string_to_stream, axutil_strlen(string_to_stream));
 
977
              tag_closed = 1;
 
978
 
 
979
            }
 
980
 
 
981
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
982
                       {
 
983
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
984
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
985
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
986
 
 
987
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
988
                                            "http://eucalyptus.ucsb.edu/",
 
989
                                            p_prefix));
 
990
                       }
 
991
 
 
992
 
 
993
                   if (!_describeNetworksResponseType->is_valid_correlationId)
 
994
                   {
 
995
 
 
996
                           /* no need to complain for minoccurs=0 element */
 
997
 
 
998
 
 
999
                   }
 
1000
                   else
 
1001
                   {
 
1002
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1003
                                 (4 + axutil_strlen(p_prefix) +
 
1004
                                  axutil_strlen("correlationId")));
 
1005
 
 
1006
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1007
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1008
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("correlationId")));
 
1009
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1010
 
 
1011
 
 
1012
 
 
1013
 
 
1014
 
 
1015
 
 
1016
                     /*
 
1017
                      * parsing correlationId element
 
1018
                      */
 
1019
 
 
1020
 
 
1021
 
 
1022
                            sprintf(start_input_str, "<%s%scorrelationId>",
 
1023
                                 p_prefix?p_prefix:"",
 
1024
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1025
 
 
1026
                        start_input_str_len = axutil_strlen(start_input_str);
 
1027
                        sprintf(end_input_str, "</%s%scorrelationId>",
 
1028
                                 p_prefix?p_prefix:"",
 
1029
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1030
                        end_input_str_len = axutil_strlen(end_input_str);
 
1031
 
 
1032
                           text_value_1 = _describeNetworksResponseType->property_correlationId;
 
1033
 
 
1034
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1035
 
 
1036
 
 
1037
                           text_value_1_temp = axutil_xml_quote_string(env, text_value_1, AXIS2_TRUE);
 
1038
                           if (text_value_1_temp)
 
1039
                           {
 
1040
                               axutil_stream_write(stream, env, text_value_1_temp, axutil_strlen(text_value_1_temp));
 
1041
                               AXIS2_FREE(env->allocator, text_value_1_temp);
 
1042
                           }
 
1043
                           else
 
1044
                           {
 
1045
                               axutil_stream_write(stream, env, text_value_1, axutil_strlen(text_value_1));
 
1046
                           }
 
1047
 
 
1048
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1049
 
 
1050
 
 
1051
                     AXIS2_FREE(env->allocator,start_input_str);
 
1052
                     AXIS2_FREE(env->allocator,end_input_str);
 
1053
                 }
 
1054
 
 
1055
 
 
1056
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
1057
                       {
 
1058
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
1059
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
1060
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
1061
 
 
1062
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
1063
                                            "http://eucalyptus.ucsb.edu/",
 
1064
                                            p_prefix));
 
1065
                       }
 
1066
 
 
1067
 
 
1068
                   if (!_describeNetworksResponseType->is_valid_userId)
 
1069
                   {
 
1070
 
 
1071
                           /* no need to complain for minoccurs=0 element */
 
1072
 
 
1073
 
 
1074
                   }
 
1075
                   else
 
1076
                   {
 
1077
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1078
                                 (4 + axutil_strlen(p_prefix) +
 
1079
                                  axutil_strlen("userId")));
 
1080
 
 
1081
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1082
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1083
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("userId")));
 
1084
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1085
 
 
1086
 
 
1087
 
 
1088
 
 
1089
 
 
1090
 
 
1091
                     /*
 
1092
                      * parsing userId element
 
1093
                      */
 
1094
 
 
1095
 
 
1096
 
 
1097
                            sprintf(start_input_str, "<%s%suserId>",
 
1098
                                 p_prefix?p_prefix:"",
 
1099
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1100
 
 
1101
                        start_input_str_len = axutil_strlen(start_input_str);
 
1102
                        sprintf(end_input_str, "</%s%suserId>",
 
1103
                                 p_prefix?p_prefix:"",
 
1104
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1105
                        end_input_str_len = axutil_strlen(end_input_str);
 
1106
 
 
1107
                           text_value_2 = _describeNetworksResponseType->property_userId;
 
1108
 
 
1109
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1110
 
 
1111
 
 
1112
                           text_value_2_temp = axutil_xml_quote_string(env, text_value_2, AXIS2_TRUE);
 
1113
                           if (text_value_2_temp)
 
1114
                           {
 
1115
                               axutil_stream_write(stream, env, text_value_2_temp, axutil_strlen(text_value_2_temp));
 
1116
                               AXIS2_FREE(env->allocator, text_value_2_temp);
 
1117
                           }
 
1118
                           else
 
1119
                           {
 
1120
                               axutil_stream_write(stream, env, text_value_2, axutil_strlen(text_value_2));
 
1121
                           }
 
1122
 
 
1123
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1124
 
 
1125
 
 
1126
                     AXIS2_FREE(env->allocator,start_input_str);
 
1127
                     AXIS2_FREE(env->allocator,end_input_str);
 
1128
                 }
 
1129
 
 
1130
 
 
1131
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
1132
                       {
 
1133
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
1134
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
1135
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
1136
 
 
1137
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
1138
                                            "http://eucalyptus.ucsb.edu/",
 
1139
                                            p_prefix));
 
1140
                       }
 
1141
 
 
1142
 
 
1143
                   if (!_describeNetworksResponseType->is_valid_statusMessage)
 
1144
                   {
 
1145
 
 
1146
                           /* no need to complain for minoccurs=0 element */
 
1147
 
 
1148
 
 
1149
                   }
 
1150
                   else
 
1151
                   {
 
1152
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1153
                                 (4 + axutil_strlen(p_prefix) +
 
1154
                                  axutil_strlen("statusMessage")));
 
1155
 
 
1156
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1157
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1158
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("statusMessage")));
 
1159
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1160
 
 
1161
 
 
1162
 
 
1163
 
 
1164
 
 
1165
 
 
1166
                     /*
 
1167
                      * parsing statusMessage element
 
1168
                      */
 
1169
 
 
1170
 
 
1171
 
 
1172
                            sprintf(start_input_str, "<%s%sstatusMessage>",
 
1173
                                 p_prefix?p_prefix:"",
 
1174
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1175
 
 
1176
                        start_input_str_len = axutil_strlen(start_input_str);
 
1177
                        sprintf(end_input_str, "</%s%sstatusMessage>",
 
1178
                                 p_prefix?p_prefix:"",
 
1179
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1180
                        end_input_str_len = axutil_strlen(end_input_str);
 
1181
 
 
1182
                           text_value_3 = _describeNetworksResponseType->property_statusMessage;
 
1183
 
 
1184
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1185
 
 
1186
 
 
1187
                           text_value_3_temp = axutil_xml_quote_string(env, text_value_3, AXIS2_TRUE);
 
1188
                           if (text_value_3_temp)
 
1189
                           {
 
1190
                               axutil_stream_write(stream, env, text_value_3_temp, axutil_strlen(text_value_3_temp));
 
1191
                               AXIS2_FREE(env->allocator, text_value_3_temp);
 
1192
                           }
 
1193
                           else
 
1194
                           {
 
1195
                               axutil_stream_write(stream, env, text_value_3, axutil_strlen(text_value_3));
 
1196
                           }
 
1197
 
 
1198
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1199
 
 
1200
 
 
1201
                     AXIS2_FREE(env->allocator,start_input_str);
 
1202
                     AXIS2_FREE(env->allocator,end_input_str);
 
1203
                 }
 
1204
 
 
1205
 
 
1206
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
1207
                       {
 
1208
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
1209
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
1210
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
1211
 
 
1212
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
1213
                                            "http://eucalyptus.ucsb.edu/",
 
1214
                                            p_prefix));
 
1215
                       }
 
1216
 
 
1217
 
 
1218
                   if (!_describeNetworksResponseType->is_valid_return)
 
1219
                   {
 
1220
 
 
1221
                           /* no need to complain for minoccurs=0 element */
 
1222
 
 
1223
 
 
1224
                   }
 
1225
                   else
 
1226
                   {
 
1227
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1228
                                 (4 + axutil_strlen(p_prefix) +
 
1229
                                  axutil_strlen("return")));
 
1230
 
 
1231
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1232
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1233
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("return")));
 
1234
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1235
 
 
1236
 
 
1237
 
 
1238
 
 
1239
 
 
1240
 
 
1241
                     /*
 
1242
                      * parsing return element
 
1243
                      */
 
1244
 
 
1245
 
 
1246
 
 
1247
                            sprintf(start_input_str, "<%s%sreturn>",
 
1248
                                 p_prefix?p_prefix:"",
 
1249
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1250
 
 
1251
                        start_input_str_len = axutil_strlen(start_input_str);
 
1252
                        sprintf(end_input_str, "</%s%sreturn>",
 
1253
                                 p_prefix?p_prefix:"",
 
1254
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1255
                        end_input_str_len = axutil_strlen(end_input_str);
 
1256
 
 
1257
                           strcpy(text_value_4, (_describeNetworksResponseType->property_return)?"true":"false");
 
1258
 
 
1259
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1260
 
 
1261
                           axutil_stream_write(stream, env, text_value_4, axutil_strlen(text_value_4));
 
1262
 
 
1263
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1264
 
 
1265
 
 
1266
                     AXIS2_FREE(env->allocator,start_input_str);
 
1267
                     AXIS2_FREE(env->allocator,end_input_str);
 
1268
                 }
 
1269
 
 
1270
 
 
1271
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
1272
                       {
 
1273
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
1274
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
1275
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
1276
 
 
1277
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
1278
                                            "http://eucalyptus.ucsb.edu/",
 
1279
                                            p_prefix));
 
1280
                       }
 
1281
 
 
1282
 
 
1283
                   if (!_describeNetworksResponseType->is_valid_mode)
 
1284
                   {
 
1285
 
 
1286
                           /* no need to complain for minoccurs=0 element */
 
1287
 
 
1288
 
 
1289
                   }
 
1290
                   else
 
1291
                   {
 
1292
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1293
                                 (4 + axutil_strlen(p_prefix) +
 
1294
                                  axutil_strlen("mode")));
 
1295
 
 
1296
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1297
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1298
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("mode")));
 
1299
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1300
 
 
1301
 
 
1302
 
 
1303
 
 
1304
 
 
1305
 
 
1306
                     /*
 
1307
                      * parsing mode element
 
1308
                      */
 
1309
 
 
1310
 
 
1311
 
 
1312
                            sprintf(start_input_str, "<%s%smode>",
 
1313
                                 p_prefix?p_prefix:"",
 
1314
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1315
 
 
1316
                        start_input_str_len = axutil_strlen(start_input_str);
 
1317
                        sprintf(end_input_str, "</%s%smode>",
 
1318
                                 p_prefix?p_prefix:"",
 
1319
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1320
                        end_input_str_len = axutil_strlen(end_input_str);
 
1321
 
 
1322
                               sprintf (text_value_5, AXIS2_PRINTF_INT32_FORMAT_SPECIFIER, _describeNetworksResponseType->property_mode);
 
1323
 
 
1324
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1325
 
 
1326
                           axutil_stream_write(stream, env, text_value_5, axutil_strlen(text_value_5));
 
1327
 
 
1328
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1329
 
 
1330
 
 
1331
                     AXIS2_FREE(env->allocator,start_input_str);
 
1332
                     AXIS2_FREE(env->allocator,end_input_str);
 
1333
                 }
 
1334
 
 
1335
 
 
1336
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
1337
                       {
 
1338
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
1339
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
1340
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
1341
 
 
1342
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
1343
                                            "http://eucalyptus.ucsb.edu/",
 
1344
                                            p_prefix));
 
1345
                       }
 
1346
 
 
1347
 
 
1348
                   if (!_describeNetworksResponseType->is_valid_addrsPerNet)
 
1349
                   {
 
1350
 
 
1351
                           /* no need to complain for minoccurs=0 element */
 
1352
 
 
1353
 
 
1354
                   }
 
1355
                   else
 
1356
                   {
 
1357
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1358
                                 (4 + axutil_strlen(p_prefix) +
 
1359
                                  axutil_strlen("addrsPerNet")));
 
1360
 
 
1361
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1362
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1363
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("addrsPerNet")));
 
1364
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1365
 
 
1366
 
 
1367
 
 
1368
 
 
1369
 
 
1370
 
 
1371
                     /*
 
1372
                      * parsing addrsPerNet element
 
1373
                      */
 
1374
 
 
1375
 
 
1376
 
 
1377
                            sprintf(start_input_str, "<%s%saddrsPerNet>",
 
1378
                                 p_prefix?p_prefix:"",
 
1379
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1380
 
 
1381
                        start_input_str_len = axutil_strlen(start_input_str);
 
1382
                        sprintf(end_input_str, "</%s%saddrsPerNet>",
 
1383
                                 p_prefix?p_prefix:"",
 
1384
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1385
                        end_input_str_len = axutil_strlen(end_input_str);
 
1386
 
 
1387
                               sprintf (text_value_6, AXIS2_PRINTF_INT32_FORMAT_SPECIFIER, _describeNetworksResponseType->property_addrsPerNet);
 
1388
 
 
1389
                           axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1390
 
 
1391
                           axutil_stream_write(stream, env, text_value_6, axutil_strlen(text_value_6));
 
1392
 
 
1393
                           axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1394
 
 
1395
 
 
1396
                     AXIS2_FREE(env->allocator,start_input_str);
 
1397
                     AXIS2_FREE(env->allocator,end_input_str);
 
1398
                 }
 
1399
 
 
1400
 
 
1401
                       if(!(p_prefix = (axis2_char_t*)axutil_hash_get(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING)))
 
1402
                       {
 
1403
                           p_prefix = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof (axis2_char_t) * ADB_DEFAULT_NAMESPACE_PREFIX_LIMIT);
 
1404
                           sprintf(p_prefix, "n%d", (*next_ns_index)++);
 
1405
                           axutil_hash_set(namespaces, "http://eucalyptus.ucsb.edu/", AXIS2_HASH_KEY_STRING, p_prefix);
 
1406
 
 
1407
                           axiom_element_declare_namespace_assume_param_ownership(parent_element, env, axiom_namespace_create (env,
 
1408
                                            "http://eucalyptus.ucsb.edu/",
 
1409
                                            p_prefix));
 
1410
                       }
 
1411
 
 
1412
 
 
1413
                   if (!_describeNetworksResponseType->is_valid_activeNetworks)
 
1414
                   {
 
1415
 
 
1416
                           /* no need to complain for minoccurs=0 element */
 
1417
 
 
1418
 
 
1419
                   }
 
1420
                   else
 
1421
                   {
 
1422
                     start_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1423
                                 (4 + axutil_strlen(p_prefix) +
 
1424
                                  axutil_strlen("activeNetworks")));
 
1425
 
 
1426
                                 /* axutil_strlen("<:>") + 1 = 4 */
 
1427
                     end_input_str = (axis2_char_t*)AXIS2_MALLOC(env->allocator, sizeof(axis2_char_t) *
 
1428
                                 (5 + axutil_strlen(p_prefix) + axutil_strlen("activeNetworks")));
 
1429
                                  /* axutil_strlen("</:>") + 1 = 5 */
 
1430
 
 
1431
 
 
1432
 
 
1433
 
 
1434
 
 
1435
                     /*
 
1436
                      * Parsing activeNetworks array
 
1437
                      */
 
1438
                     if (_describeNetworksResponseType->property_activeNetworks != NULL)
 
1439
                     {
 
1440
 
 
1441
 
 
1442
                            sprintf(start_input_str, "<%s%sactiveNetworks",
 
1443
                                 p_prefix?p_prefix:"",
 
1444
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1445
 
 
1446
                         start_input_str_len = axutil_strlen(start_input_str);
 
1447
 
 
1448
                         sprintf(end_input_str, "</%s%sactiveNetworks>",
 
1449
                                 p_prefix?p_prefix:"",
 
1450
                                 (p_prefix && axutil_strcmp(p_prefix, ""))?":":"");
 
1451
                         end_input_str_len = axutil_strlen(end_input_str);
 
1452
 
 
1453
                         count = axutil_array_list_size(_describeNetworksResponseType->property_activeNetworks, env);
 
1454
                         for(i = 0; i < count; i ++)
 
1455
                         {
 
1456
                            element = axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i);
 
1457
 
 
1458
                            if(NULL == element)
 
1459
                            {
 
1460
                                continue;
 
1461
                            }
 
1462
 
 
1463
 
 
1464
                     /*
 
1465
                      * parsing activeNetworks element
 
1466
                      */
 
1467
 
 
1468
 
 
1469
 
 
1470
                            if(!adb_networkType_is_particle())
 
1471
                            {
 
1472
                                axutil_stream_write(stream, env, start_input_str, start_input_str_len);
 
1473
                            }
 
1474
 
 
1475
                            adb_networkType_serialize((adb_networkType_t*)element,
 
1476
                                                                                 env, current_node, parent_element,
 
1477
                                                                                 adb_networkType_is_particle() || AXIS2_FALSE, namespaces, next_ns_index);
 
1478
 
 
1479
                            if(!adb_networkType_is_particle())
 
1480
                            {
 
1481
                                axutil_stream_write(stream, env, end_input_str, end_input_str_len);
 
1482
                            }
 
1483
 
 
1484
                         }
 
1485
                     }
 
1486
 
 
1487
 
 
1488
                     AXIS2_FREE(env->allocator,start_input_str);
 
1489
                     AXIS2_FREE(env->allocator,end_input_str);
 
1490
                 }
 
1491
 
 
1492
 
 
1493
 
 
1494
            return parent;
 
1495
        }
 
1496
 
 
1497
 
 
1498
 
 
1499
 
 
1500
            /**
 
1501
             * getter for correlationId.
 
1502
             */
 
1503
            axis2_char_t* AXIS2_CALL
 
1504
            adb_describeNetworksResponseType_get_correlationId(
 
1505
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1506
                    const axutil_env_t *env)
 
1507
             {
 
1508
 
 
1509
                    AXIS2_ENV_CHECK(env, NULL);
 
1510
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, NULL);
 
1511
 
 
1512
 
 
1513
                return _describeNetworksResponseType->property_correlationId;
 
1514
             }
 
1515
 
 
1516
            /**
 
1517
             * setter for correlationId
 
1518
             */
 
1519
            axis2_status_t AXIS2_CALL
 
1520
            adb_describeNetworksResponseType_set_correlationId(
 
1521
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1522
                    const axutil_env_t *env,
 
1523
                    const axis2_char_t*  arg_correlationId)
 
1524
             {
 
1525
 
 
1526
 
 
1527
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1528
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1529
 
 
1530
                if(_describeNetworksResponseType->is_valid_correlationId &&
 
1531
                        arg_correlationId == _describeNetworksResponseType->property_correlationId)
 
1532
                {
 
1533
 
 
1534
                    return AXIS2_SUCCESS;
 
1535
                }
 
1536
 
 
1537
                adb_describeNetworksResponseType_reset_correlationId(_describeNetworksResponseType, env);
 
1538
 
 
1539
 
 
1540
                if(NULL == arg_correlationId)
 
1541
                {
 
1542
                    /* We are already done */
 
1543
                    return AXIS2_SUCCESS;
 
1544
                }
 
1545
                _describeNetworksResponseType->property_correlationId = (axis2_char_t *)axutil_strdup(env, arg_correlationId);
 
1546
                        if(NULL == _describeNetworksResponseType->property_correlationId)
 
1547
                        {
 
1548
                            AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Error allocating memeory for correlationId");
 
1549
                            return AXIS2_FAILURE;
 
1550
                        }
 
1551
                        _describeNetworksResponseType->is_valid_correlationId = AXIS2_TRUE;
 
1552
 
 
1553
                return AXIS2_SUCCESS;
 
1554
             }
 
1555
 
 
1556
 
 
1557
 
 
1558
           /**
 
1559
            * resetter for correlationId
 
1560
            */
 
1561
           axis2_status_t AXIS2_CALL
 
1562
           adb_describeNetworksResponseType_reset_correlationId(
 
1563
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1564
                   const axutil_env_t *env)
 
1565
           {
 
1566
               int i = 0;
 
1567
               int count = 0;
 
1568
               void *element = NULL;
 
1569
 
 
1570
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1571
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1572
 
 
1573
 
 
1574
 
 
1575
 
 
1576
 
 
1577
                if(_describeNetworksResponseType->property_correlationId != NULL)
 
1578
                {
 
1579
 
 
1580
 
 
1581
                        AXIS2_FREE(env-> allocator, _describeNetworksResponseType->property_correlationId);
 
1582
                     _describeNetworksResponseType->property_correlationId = NULL;
 
1583
                }
 
1584
 
 
1585
 
 
1586
 
 
1587
                _describeNetworksResponseType->is_valid_correlationId = AXIS2_FALSE;
 
1588
               return AXIS2_SUCCESS;
 
1589
           }
 
1590
 
 
1591
           /**
 
1592
            * Check whether correlationId is nill
 
1593
            */
 
1594
           axis2_bool_t AXIS2_CALL
 
1595
           adb_describeNetworksResponseType_is_correlationId_nil(
 
1596
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1597
                   const axutil_env_t *env)
 
1598
           {
 
1599
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
1600
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
1601
 
 
1602
               return !_describeNetworksResponseType->is_valid_correlationId;
 
1603
           }
 
1604
 
 
1605
           /**
 
1606
            * Set correlationId to nill (currently the same as reset)
 
1607
            */
 
1608
           axis2_status_t AXIS2_CALL
 
1609
           adb_describeNetworksResponseType_set_correlationId_nil(
 
1610
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1611
                   const axutil_env_t *env)
 
1612
           {
 
1613
               return adb_describeNetworksResponseType_reset_correlationId(_describeNetworksResponseType, env);
 
1614
           }
 
1615
 
 
1616
 
 
1617
 
 
1618
            /**
 
1619
             * getter for userId.
 
1620
             */
 
1621
            axis2_char_t* AXIS2_CALL
 
1622
            adb_describeNetworksResponseType_get_userId(
 
1623
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1624
                    const axutil_env_t *env)
 
1625
             {
 
1626
 
 
1627
                    AXIS2_ENV_CHECK(env, NULL);
 
1628
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, NULL);
 
1629
 
 
1630
 
 
1631
                return _describeNetworksResponseType->property_userId;
 
1632
             }
 
1633
 
 
1634
            /**
 
1635
             * setter for userId
 
1636
             */
 
1637
            axis2_status_t AXIS2_CALL
 
1638
            adb_describeNetworksResponseType_set_userId(
 
1639
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1640
                    const axutil_env_t *env,
 
1641
                    const axis2_char_t*  arg_userId)
 
1642
             {
 
1643
 
 
1644
 
 
1645
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1646
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1647
 
 
1648
                if(_describeNetworksResponseType->is_valid_userId &&
 
1649
                        arg_userId == _describeNetworksResponseType->property_userId)
 
1650
                {
 
1651
 
 
1652
                    return AXIS2_SUCCESS;
 
1653
                }
 
1654
 
 
1655
                adb_describeNetworksResponseType_reset_userId(_describeNetworksResponseType, env);
 
1656
 
 
1657
 
 
1658
                if(NULL == arg_userId)
 
1659
                {
 
1660
                    /* We are already done */
 
1661
                    return AXIS2_SUCCESS;
 
1662
                }
 
1663
                _describeNetworksResponseType->property_userId = (axis2_char_t *)axutil_strdup(env, arg_userId);
 
1664
                        if(NULL == _describeNetworksResponseType->property_userId)
 
1665
                        {
 
1666
                            AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Error allocating memeory for userId");
 
1667
                            return AXIS2_FAILURE;
 
1668
                        }
 
1669
                        _describeNetworksResponseType->is_valid_userId = AXIS2_TRUE;
 
1670
 
 
1671
                return AXIS2_SUCCESS;
 
1672
             }
 
1673
 
 
1674
 
 
1675
 
 
1676
           /**
 
1677
            * resetter for userId
 
1678
            */
 
1679
           axis2_status_t AXIS2_CALL
 
1680
           adb_describeNetworksResponseType_reset_userId(
 
1681
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1682
                   const axutil_env_t *env)
 
1683
           {
 
1684
               int i = 0;
 
1685
               int count = 0;
 
1686
               void *element = NULL;
 
1687
 
 
1688
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1689
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1690
 
 
1691
 
 
1692
 
 
1693
 
 
1694
 
 
1695
                if(_describeNetworksResponseType->property_userId != NULL)
 
1696
                {
 
1697
 
 
1698
 
 
1699
                        AXIS2_FREE(env-> allocator, _describeNetworksResponseType->property_userId);
 
1700
                     _describeNetworksResponseType->property_userId = NULL;
 
1701
                }
 
1702
 
 
1703
 
 
1704
 
 
1705
                _describeNetworksResponseType->is_valid_userId = AXIS2_FALSE;
 
1706
               return AXIS2_SUCCESS;
 
1707
           }
 
1708
 
 
1709
           /**
 
1710
            * Check whether userId is nill
 
1711
            */
 
1712
           axis2_bool_t AXIS2_CALL
 
1713
           adb_describeNetworksResponseType_is_userId_nil(
 
1714
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1715
                   const axutil_env_t *env)
 
1716
           {
 
1717
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
1718
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
1719
 
 
1720
               return !_describeNetworksResponseType->is_valid_userId;
 
1721
           }
 
1722
 
 
1723
           /**
 
1724
            * Set userId to nill (currently the same as reset)
 
1725
            */
 
1726
           axis2_status_t AXIS2_CALL
 
1727
           adb_describeNetworksResponseType_set_userId_nil(
 
1728
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1729
                   const axutil_env_t *env)
 
1730
           {
 
1731
               return adb_describeNetworksResponseType_reset_userId(_describeNetworksResponseType, env);
 
1732
           }
 
1733
 
 
1734
 
 
1735
 
 
1736
            /**
 
1737
             * getter for statusMessage.
 
1738
             */
 
1739
            axis2_char_t* AXIS2_CALL
 
1740
            adb_describeNetworksResponseType_get_statusMessage(
 
1741
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1742
                    const axutil_env_t *env)
 
1743
             {
 
1744
 
 
1745
                    AXIS2_ENV_CHECK(env, NULL);
 
1746
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, NULL);
 
1747
 
 
1748
 
 
1749
                return _describeNetworksResponseType->property_statusMessage;
 
1750
             }
 
1751
 
 
1752
            /**
 
1753
             * setter for statusMessage
 
1754
             */
 
1755
            axis2_status_t AXIS2_CALL
 
1756
            adb_describeNetworksResponseType_set_statusMessage(
 
1757
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1758
                    const axutil_env_t *env,
 
1759
                    const axis2_char_t*  arg_statusMessage)
 
1760
             {
 
1761
 
 
1762
 
 
1763
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1764
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1765
 
 
1766
                if(_describeNetworksResponseType->is_valid_statusMessage &&
 
1767
                        arg_statusMessage == _describeNetworksResponseType->property_statusMessage)
 
1768
                {
 
1769
 
 
1770
                    return AXIS2_SUCCESS;
 
1771
                }
 
1772
 
 
1773
                adb_describeNetworksResponseType_reset_statusMessage(_describeNetworksResponseType, env);
 
1774
 
 
1775
 
 
1776
                if(NULL == arg_statusMessage)
 
1777
                {
 
1778
                    /* We are already done */
 
1779
                    return AXIS2_SUCCESS;
 
1780
                }
 
1781
                _describeNetworksResponseType->property_statusMessage = (axis2_char_t *)axutil_strdup(env, arg_statusMessage);
 
1782
                        if(NULL == _describeNetworksResponseType->property_statusMessage)
 
1783
                        {
 
1784
                            AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Error allocating memeory for statusMessage");
 
1785
                            return AXIS2_FAILURE;
 
1786
                        }
 
1787
                        _describeNetworksResponseType->is_valid_statusMessage = AXIS2_TRUE;
 
1788
 
 
1789
                return AXIS2_SUCCESS;
 
1790
             }
 
1791
 
 
1792
 
 
1793
 
 
1794
           /**
 
1795
            * resetter for statusMessage
 
1796
            */
 
1797
           axis2_status_t AXIS2_CALL
 
1798
           adb_describeNetworksResponseType_reset_statusMessage(
 
1799
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1800
                   const axutil_env_t *env)
 
1801
           {
 
1802
               int i = 0;
 
1803
               int count = 0;
 
1804
               void *element = NULL;
 
1805
 
 
1806
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1807
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1808
 
 
1809
 
 
1810
 
 
1811
 
 
1812
 
 
1813
                if(_describeNetworksResponseType->property_statusMessage != NULL)
 
1814
                {
 
1815
 
 
1816
 
 
1817
                        AXIS2_FREE(env-> allocator, _describeNetworksResponseType->property_statusMessage);
 
1818
                     _describeNetworksResponseType->property_statusMessage = NULL;
 
1819
                }
 
1820
 
 
1821
 
 
1822
 
 
1823
                _describeNetworksResponseType->is_valid_statusMessage = AXIS2_FALSE;
 
1824
               return AXIS2_SUCCESS;
 
1825
           }
 
1826
 
 
1827
           /**
 
1828
            * Check whether statusMessage is nill
 
1829
            */
 
1830
           axis2_bool_t AXIS2_CALL
 
1831
           adb_describeNetworksResponseType_is_statusMessage_nil(
 
1832
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1833
                   const axutil_env_t *env)
 
1834
           {
 
1835
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
1836
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
1837
 
 
1838
               return !_describeNetworksResponseType->is_valid_statusMessage;
 
1839
           }
 
1840
 
 
1841
           /**
 
1842
            * Set statusMessage to nill (currently the same as reset)
 
1843
            */
 
1844
           axis2_status_t AXIS2_CALL
 
1845
           adb_describeNetworksResponseType_set_statusMessage_nil(
 
1846
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1847
                   const axutil_env_t *env)
 
1848
           {
 
1849
               return adb_describeNetworksResponseType_reset_statusMessage(_describeNetworksResponseType, env);
 
1850
           }
 
1851
 
 
1852
 
 
1853
 
 
1854
            /**
 
1855
             * getter for return.
 
1856
             */
 
1857
            axis2_bool_t AXIS2_CALL
 
1858
            adb_describeNetworksResponseType_get_return(
 
1859
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1860
                    const axutil_env_t *env)
 
1861
             {
 
1862
 
 
1863
                    AXIS2_ENV_CHECK(env, (axis2_bool_t)0);
 
1864
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, (axis2_bool_t)0);
 
1865
 
 
1866
 
 
1867
                return _describeNetworksResponseType->property_return;
 
1868
             }
 
1869
 
 
1870
            /**
 
1871
             * setter for return
 
1872
             */
 
1873
            axis2_status_t AXIS2_CALL
 
1874
            adb_describeNetworksResponseType_set_return(
 
1875
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1876
                    const axutil_env_t *env,
 
1877
                    axis2_bool_t  arg_return)
 
1878
             {
 
1879
 
 
1880
 
 
1881
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1882
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1883
 
 
1884
                if(_describeNetworksResponseType->is_valid_return &&
 
1885
                        arg_return == _describeNetworksResponseType->property_return)
 
1886
                {
 
1887
 
 
1888
                    return AXIS2_SUCCESS;
 
1889
                }
 
1890
 
 
1891
                adb_describeNetworksResponseType_reset_return(_describeNetworksResponseType, env);
 
1892
 
 
1893
                _describeNetworksResponseType->property_return = arg_return;
 
1894
                        _describeNetworksResponseType->is_valid_return = AXIS2_TRUE;
 
1895
 
 
1896
                return AXIS2_SUCCESS;
 
1897
             }
 
1898
 
 
1899
 
 
1900
 
 
1901
           /**
 
1902
            * resetter for return
 
1903
            */
 
1904
           axis2_status_t AXIS2_CALL
 
1905
           adb_describeNetworksResponseType_reset_return(
 
1906
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1907
                   const axutil_env_t *env)
 
1908
           {
 
1909
               int i = 0;
 
1910
               int count = 0;
 
1911
               void *element = NULL;
 
1912
 
 
1913
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1914
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1915
 
 
1916
 
 
1917
               _describeNetworksResponseType->is_valid_return = AXIS2_FALSE;
 
1918
               return AXIS2_SUCCESS;
 
1919
           }
 
1920
 
 
1921
           /**
 
1922
            * Check whether return is nill
 
1923
            */
 
1924
           axis2_bool_t AXIS2_CALL
 
1925
           adb_describeNetworksResponseType_is_return_nil(
 
1926
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1927
                   const axutil_env_t *env)
 
1928
           {
 
1929
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
1930
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
1931
 
 
1932
               return !_describeNetworksResponseType->is_valid_return;
 
1933
           }
 
1934
 
 
1935
           /**
 
1936
            * Set return to nill (currently the same as reset)
 
1937
            */
 
1938
           axis2_status_t AXIS2_CALL
 
1939
           adb_describeNetworksResponseType_set_return_nil(
 
1940
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1941
                   const axutil_env_t *env)
 
1942
           {
 
1943
               return adb_describeNetworksResponseType_reset_return(_describeNetworksResponseType, env);
 
1944
           }
 
1945
 
 
1946
 
 
1947
 
 
1948
            /**
 
1949
             * getter for mode.
 
1950
             */
 
1951
            int AXIS2_CALL
 
1952
            adb_describeNetworksResponseType_get_mode(
 
1953
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1954
                    const axutil_env_t *env)
 
1955
             {
 
1956
 
 
1957
                    AXIS2_ENV_CHECK(env, (int)0);
 
1958
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, (int)0);
 
1959
 
 
1960
 
 
1961
                return _describeNetworksResponseType->property_mode;
 
1962
             }
 
1963
 
 
1964
            /**
 
1965
             * setter for mode
 
1966
             */
 
1967
            axis2_status_t AXIS2_CALL
 
1968
            adb_describeNetworksResponseType_set_mode(
 
1969
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
1970
                    const axutil_env_t *env,
 
1971
                    const int  arg_mode)
 
1972
             {
 
1973
 
 
1974
 
 
1975
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
1976
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
1977
 
 
1978
                if(_describeNetworksResponseType->is_valid_mode &&
 
1979
                        arg_mode == _describeNetworksResponseType->property_mode)
 
1980
                {
 
1981
 
 
1982
                    return AXIS2_SUCCESS;
 
1983
                }
 
1984
 
 
1985
                adb_describeNetworksResponseType_reset_mode(_describeNetworksResponseType, env);
 
1986
 
 
1987
                _describeNetworksResponseType->property_mode = arg_mode;
 
1988
                        _describeNetworksResponseType->is_valid_mode = AXIS2_TRUE;
 
1989
 
 
1990
                return AXIS2_SUCCESS;
 
1991
             }
 
1992
 
 
1993
 
 
1994
 
 
1995
           /**
 
1996
            * resetter for mode
 
1997
            */
 
1998
           axis2_status_t AXIS2_CALL
 
1999
           adb_describeNetworksResponseType_reset_mode(
 
2000
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2001
                   const axutil_env_t *env)
 
2002
           {
 
2003
               int i = 0;
 
2004
               int count = 0;
 
2005
               void *element = NULL;
 
2006
 
 
2007
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2008
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2009
 
 
2010
 
 
2011
               _describeNetworksResponseType->is_valid_mode = AXIS2_FALSE;
 
2012
               return AXIS2_SUCCESS;
 
2013
           }
 
2014
 
 
2015
           /**
 
2016
            * Check whether mode is nill
 
2017
            */
 
2018
           axis2_bool_t AXIS2_CALL
 
2019
           adb_describeNetworksResponseType_is_mode_nil(
 
2020
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2021
                   const axutil_env_t *env)
 
2022
           {
 
2023
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
2024
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
2025
 
 
2026
               return !_describeNetworksResponseType->is_valid_mode;
 
2027
           }
 
2028
 
 
2029
           /**
 
2030
            * Set mode to nill (currently the same as reset)
 
2031
            */
 
2032
           axis2_status_t AXIS2_CALL
 
2033
           adb_describeNetworksResponseType_set_mode_nil(
 
2034
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2035
                   const axutil_env_t *env)
 
2036
           {
 
2037
               return adb_describeNetworksResponseType_reset_mode(_describeNetworksResponseType, env);
 
2038
           }
 
2039
 
 
2040
 
 
2041
 
 
2042
            /**
 
2043
             * getter for addrsPerNet.
 
2044
             */
 
2045
            int AXIS2_CALL
 
2046
            adb_describeNetworksResponseType_get_addrsPerNet(
 
2047
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2048
                    const axutil_env_t *env)
 
2049
             {
 
2050
 
 
2051
                    AXIS2_ENV_CHECK(env, (int)0);
 
2052
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, (int)0);
 
2053
 
 
2054
 
 
2055
                return _describeNetworksResponseType->property_addrsPerNet;
 
2056
             }
 
2057
 
 
2058
            /**
 
2059
             * setter for addrsPerNet
 
2060
             */
 
2061
            axis2_status_t AXIS2_CALL
 
2062
            adb_describeNetworksResponseType_set_addrsPerNet(
 
2063
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2064
                    const axutil_env_t *env,
 
2065
                    const int  arg_addrsPerNet)
 
2066
             {
 
2067
 
 
2068
 
 
2069
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2070
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2071
 
 
2072
                if(_describeNetworksResponseType->is_valid_addrsPerNet &&
 
2073
                        arg_addrsPerNet == _describeNetworksResponseType->property_addrsPerNet)
 
2074
                {
 
2075
 
 
2076
                    return AXIS2_SUCCESS;
 
2077
                }
 
2078
 
 
2079
                adb_describeNetworksResponseType_reset_addrsPerNet(_describeNetworksResponseType, env);
 
2080
 
 
2081
                _describeNetworksResponseType->property_addrsPerNet = arg_addrsPerNet;
 
2082
                        _describeNetworksResponseType->is_valid_addrsPerNet = AXIS2_TRUE;
 
2083
 
 
2084
                return AXIS2_SUCCESS;
 
2085
             }
 
2086
 
 
2087
 
 
2088
 
 
2089
           /**
 
2090
            * resetter for addrsPerNet
 
2091
            */
 
2092
           axis2_status_t AXIS2_CALL
 
2093
           adb_describeNetworksResponseType_reset_addrsPerNet(
 
2094
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2095
                   const axutil_env_t *env)
 
2096
           {
 
2097
               int i = 0;
 
2098
               int count = 0;
 
2099
               void *element = NULL;
 
2100
 
 
2101
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2102
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2103
 
 
2104
 
 
2105
               _describeNetworksResponseType->is_valid_addrsPerNet = AXIS2_FALSE;
 
2106
               return AXIS2_SUCCESS;
 
2107
           }
 
2108
 
 
2109
           /**
 
2110
            * Check whether addrsPerNet is nill
 
2111
            */
 
2112
           axis2_bool_t AXIS2_CALL
 
2113
           adb_describeNetworksResponseType_is_addrsPerNet_nil(
 
2114
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2115
                   const axutil_env_t *env)
 
2116
           {
 
2117
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
2118
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
2119
 
 
2120
               return !_describeNetworksResponseType->is_valid_addrsPerNet;
 
2121
           }
 
2122
 
 
2123
           /**
 
2124
            * Set addrsPerNet to nill (currently the same as reset)
 
2125
            */
 
2126
           axis2_status_t AXIS2_CALL
 
2127
           adb_describeNetworksResponseType_set_addrsPerNet_nil(
 
2128
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2129
                   const axutil_env_t *env)
 
2130
           {
 
2131
               return adb_describeNetworksResponseType_reset_addrsPerNet(_describeNetworksResponseType, env);
 
2132
           }
 
2133
 
 
2134
 
 
2135
 
 
2136
            /**
 
2137
             * getter for activeNetworks.
 
2138
             */
 
2139
            axutil_array_list_t* AXIS2_CALL
 
2140
            adb_describeNetworksResponseType_get_activeNetworks(
 
2141
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2142
                    const axutil_env_t *env)
 
2143
             {
 
2144
 
 
2145
                    AXIS2_ENV_CHECK(env, NULL);
 
2146
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, NULL);
 
2147
 
 
2148
 
 
2149
                return _describeNetworksResponseType->property_activeNetworks;
 
2150
             }
 
2151
 
 
2152
            /**
 
2153
             * setter for activeNetworks
 
2154
             */
 
2155
            axis2_status_t AXIS2_CALL
 
2156
            adb_describeNetworksResponseType_set_activeNetworks(
 
2157
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2158
                    const axutil_env_t *env,
 
2159
                    axutil_array_list_t*  arg_activeNetworks)
 
2160
             {
 
2161
 
 
2162
                 int size = 0;
 
2163
                 int i = 0;
 
2164
                 axis2_bool_t non_nil_exists = AXIS2_FALSE;
 
2165
 
 
2166
 
 
2167
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2168
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2169
 
 
2170
                if(_describeNetworksResponseType->is_valid_activeNetworks &&
 
2171
                        arg_activeNetworks == _describeNetworksResponseType->property_activeNetworks)
 
2172
                {
 
2173
 
 
2174
                    return AXIS2_SUCCESS;
 
2175
                }
 
2176
 
 
2177
 
 
2178
                 size = axutil_array_list_size(arg_activeNetworks, env);
 
2179
 
 
2180
                 if (size < 0)
 
2181
                 {
 
2182
                     AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "activeNetworks has less than minOccurs(0)");
 
2183
                     return AXIS2_FAILURE;
 
2184
                 }
 
2185
                 for(i = 0; i < size; i ++ )
 
2186
                 {
 
2187
                     if(NULL != axutil_array_list_get(arg_activeNetworks, env, i))
 
2188
                     {
 
2189
                         non_nil_exists = AXIS2_TRUE;
 
2190
                         break;
 
2191
                     }
 
2192
                 }
 
2193
 
 
2194
                 adb_describeNetworksResponseType_reset_activeNetworks(_describeNetworksResponseType, env);
 
2195
 
 
2196
 
 
2197
                if(NULL == arg_activeNetworks)
 
2198
                {
 
2199
                    /* We are already done */
 
2200
                    return AXIS2_SUCCESS;
 
2201
                }
 
2202
                _describeNetworksResponseType->property_activeNetworks = arg_activeNetworks;
 
2203
                        if(non_nil_exists)
 
2204
                        {
 
2205
                            _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_TRUE;
 
2206
                        }
 
2207
 
 
2208
 
 
2209
                return AXIS2_SUCCESS;
 
2210
             }
 
2211
 
 
2212
 
 
2213
            /**
 
2214
             * Get ith element of activeNetworks.
 
2215
             */
 
2216
            adb_networkType_t* AXIS2_CALL
 
2217
            adb_describeNetworksResponseType_get_activeNetworks_at(
 
2218
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2219
                    const axutil_env_t *env, int i)
 
2220
            {
 
2221
                adb_networkType_t* ret_val;
 
2222
 
 
2223
 
 
2224
                    AXIS2_ENV_CHECK(env, NULL);
 
2225
                    AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, NULL);
 
2226
 
 
2227
 
 
2228
                if(_describeNetworksResponseType->property_activeNetworks == NULL)
 
2229
                {
 
2230
                    return (adb_networkType_t*)0;
 
2231
                }
 
2232
                ret_val = (adb_networkType_t*)axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i);
 
2233
 
 
2234
                    return ret_val;
 
2235
 
 
2236
            }
 
2237
 
 
2238
            /**
 
2239
             * Set the ith element of activeNetworks.
 
2240
             */
 
2241
            axis2_status_t AXIS2_CALL
 
2242
            adb_describeNetworksResponseType_set_activeNetworks_at(
 
2243
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2244
                    const axutil_env_t *env, int i,
 
2245
                    adb_networkType_t* arg_activeNetworks)
 
2246
            {
 
2247
                void *element = NULL;
 
2248
                int size = 0;
 
2249
                int j;
 
2250
                int k;
 
2251
                axis2_bool_t non_nil_exists = AXIS2_FALSE;
 
2252
 
 
2253
 
 
2254
 
 
2255
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2256
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2257
 
 
2258
                if( _describeNetworksResponseType->is_valid_activeNetworks &&
 
2259
                    _describeNetworksResponseType->property_activeNetworks &&
 
2260
 
 
2261
                    arg_activeNetworks == (adb_networkType_t*)axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i))
 
2262
 
 
2263
                {
 
2264
 
 
2265
                    return AXIS2_SUCCESS;
 
2266
                }
 
2267
 
 
2268
 
 
2269
                    if(NULL == arg_activeNetworks)
 
2270
                    {
 
2271
                        if(_describeNetworksResponseType->property_activeNetworks != NULL)
 
2272
                        {
 
2273
                            size = axutil_array_list_size(_describeNetworksResponseType->property_activeNetworks, env);
 
2274
                            for(j = 0, k = 0; j < size; j ++ )
 
2275
                            {
 
2276
                                if(i == j) continue;
 
2277
                                if(NULL != axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i))
 
2278
                                {
 
2279
                                    k ++;
 
2280
                                    non_nil_exists = AXIS2_TRUE;
 
2281
                                    if(k >= 0)
 
2282
                                    {
 
2283
                                        break;
 
2284
                                    }
 
2285
                                }
 
2286
                            }
 
2287
                        }
 
2288
                    }
 
2289
                    else
 
2290
                    {
 
2291
                        non_nil_exists = AXIS2_TRUE;
 
2292
                    }
 
2293
 
 
2294
                if( k < 0)
 
2295
                {
 
2296
                       AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Size of the array of activeNetworks is beinng set to be smaller than the specificed number of minOccurs(0)");
 
2297
                       return AXIS2_FAILURE;
 
2298
                }
 
2299
 
 
2300
                if(_describeNetworksResponseType->property_activeNetworks == NULL)
 
2301
                {
 
2302
                    _describeNetworksResponseType->property_activeNetworks = axutil_array_list_create(env, 10);
 
2303
                }
 
2304
 
 
2305
                /* check whether there already exist an element */
 
2306
                element = axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i);
 
2307
                if(NULL != element)
 
2308
                {
 
2309
 
 
2310
 
 
2311
 
 
2312
                        adb_networkType_free((adb_networkType_t*)element, env);
 
2313
 
 
2314
                }
 
2315
 
 
2316
 
 
2317
                    if(!non_nil_exists)
 
2318
                    {
 
2319
 
 
2320
                        _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_FALSE;
 
2321
                        axutil_array_list_set(_describeNetworksResponseType->property_activeNetworks , env, i, NULL);
 
2322
 
 
2323
                        return AXIS2_SUCCESS;
 
2324
                    }
 
2325
 
 
2326
                   axutil_array_list_set(_describeNetworksResponseType->property_activeNetworks , env, i, arg_activeNetworks);
 
2327
                  _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_TRUE;
 
2328
 
 
2329
                return AXIS2_SUCCESS;
 
2330
            }
 
2331
 
 
2332
            /**
 
2333
             * Add to activeNetworks.
 
2334
             */
 
2335
            axis2_status_t AXIS2_CALL
 
2336
            adb_describeNetworksResponseType_add_activeNetworks(
 
2337
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2338
                    const axutil_env_t *env,
 
2339
                    adb_networkType_t* arg_activeNetworks)
 
2340
             {
 
2341
 
 
2342
 
 
2343
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2344
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2345
 
 
2346
 
 
2347
                    if(NULL == arg_activeNetworks)
 
2348
                    {
 
2349
 
 
2350
                           return AXIS2_SUCCESS;
 
2351
 
 
2352
                    }
 
2353
 
 
2354
 
 
2355
                if(_describeNetworksResponseType->property_activeNetworks == NULL)
 
2356
                {
 
2357
                    _describeNetworksResponseType->property_activeNetworks = axutil_array_list_create(env, 10);
 
2358
                }
 
2359
                if(_describeNetworksResponseType->property_activeNetworks == NULL)
 
2360
                {
 
2361
                    AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Failed in allocatting memory for activeNetworks");
 
2362
                    return AXIS2_FAILURE;
 
2363
 
 
2364
                }
 
2365
 
 
2366
                   axutil_array_list_add(_describeNetworksResponseType->property_activeNetworks , env, arg_activeNetworks);
 
2367
                  _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_TRUE;
 
2368
                return AXIS2_SUCCESS;
 
2369
             }
 
2370
 
 
2371
            /**
 
2372
             * Get the size of the activeNetworks array.
 
2373
             */
 
2374
            int AXIS2_CALL
 
2375
            adb_describeNetworksResponseType_sizeof_activeNetworks(
 
2376
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2377
                    const axutil_env_t *env)
 
2378
            {
 
2379
                AXIS2_ENV_CHECK(env, -1);
 
2380
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, -1);
 
2381
                if(_describeNetworksResponseType->property_activeNetworks == NULL)
 
2382
                {
 
2383
                    return 0;
 
2384
                }
 
2385
                return axutil_array_list_size(_describeNetworksResponseType->property_activeNetworks, env);
 
2386
            }
 
2387
 
 
2388
            /**
 
2389
             * remove the ith element, same as set_nil_at.
 
2390
             */
 
2391
            axis2_status_t AXIS2_CALL
 
2392
            adb_describeNetworksResponseType_remove_activeNetworks_at(
 
2393
                    adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2394
                    const axutil_env_t *env, int i)
 
2395
            {
 
2396
                return adb_describeNetworksResponseType_set_activeNetworks_nil_at(_describeNetworksResponseType, env, i);
 
2397
            }
 
2398
 
 
2399
 
 
2400
 
 
2401
           /**
 
2402
            * resetter for activeNetworks
 
2403
            */
 
2404
           axis2_status_t AXIS2_CALL
 
2405
           adb_describeNetworksResponseType_reset_activeNetworks(
 
2406
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2407
                   const axutil_env_t *env)
 
2408
           {
 
2409
               int i = 0;
 
2410
               int count = 0;
 
2411
               void *element = NULL;
 
2412
 
 
2413
               AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2414
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2415
 
 
2416
 
 
2417
 
 
2418
                  if (_describeNetworksResponseType->property_activeNetworks != NULL)
 
2419
                  {
 
2420
                      count = axutil_array_list_size(_describeNetworksResponseType->property_activeNetworks, env);
 
2421
                      for(i = 0; i < count; i ++)
 
2422
                      {
 
2423
                         element = axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i);
 
2424
 
 
2425
 
 
2426
 
 
2427
                if(element != NULL)
 
2428
                {
 
2429
 
 
2430
 
 
2431
                        adb_networkType_free((adb_networkType_t*)element, env);
 
2432
                     element = NULL;
 
2433
                }
 
2434
 
 
2435
 
 
2436
 
 
2437
 
 
2438
                      }
 
2439
                      axutil_array_list_free(_describeNetworksResponseType->property_activeNetworks, env);
 
2440
                  }
 
2441
                _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_FALSE;
 
2442
               return AXIS2_SUCCESS;
 
2443
           }
 
2444
 
 
2445
           /**
 
2446
            * Check whether activeNetworks is nill
 
2447
            */
 
2448
           axis2_bool_t AXIS2_CALL
 
2449
           adb_describeNetworksResponseType_is_activeNetworks_nil(
 
2450
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2451
                   const axutil_env_t *env)
 
2452
           {
 
2453
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
2454
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
2455
 
 
2456
               return !_describeNetworksResponseType->is_valid_activeNetworks;
 
2457
           }
 
2458
 
 
2459
           /**
 
2460
            * Set activeNetworks to nill (currently the same as reset)
 
2461
            */
 
2462
           axis2_status_t AXIS2_CALL
 
2463
           adb_describeNetworksResponseType_set_activeNetworks_nil(
 
2464
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2465
                   const axutil_env_t *env)
 
2466
           {
 
2467
               return adb_describeNetworksResponseType_reset_activeNetworks(_describeNetworksResponseType, env);
 
2468
           }
 
2469
 
 
2470
 
 
2471
           /**
 
2472
            * Check whether activeNetworks is nill at i
 
2473
            */
 
2474
           axis2_bool_t AXIS2_CALL
 
2475
           adb_describeNetworksResponseType_is_activeNetworks_nil_at(
 
2476
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2477
                   const axutil_env_t *env, int i)
 
2478
           {
 
2479
               AXIS2_ENV_CHECK(env, AXIS2_TRUE);
 
2480
               AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_TRUE);
 
2481
 
 
2482
               return (_describeNetworksResponseType->is_valid_activeNetworks == AXIS2_FALSE ||
 
2483
                        NULL == _describeNetworksResponseType->property_activeNetworks ||
 
2484
                        NULL == axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i));
 
2485
           }
 
2486
 
 
2487
           /**
 
2488
            * Set activeNetworks to nill at i
 
2489
            */
 
2490
           axis2_status_t AXIS2_CALL
 
2491
           adb_describeNetworksResponseType_set_activeNetworks_nil_at(
 
2492
                   adb_describeNetworksResponseType_t* _describeNetworksResponseType,
 
2493
                   const axutil_env_t *env, int i)
 
2494
           {
 
2495
                void *element = NULL;
 
2496
                int size = 0;
 
2497
                int j;
 
2498
                axis2_bool_t non_nil_exists = AXIS2_FALSE;
 
2499
 
 
2500
                int k = 0;
 
2501
 
 
2502
                AXIS2_ENV_CHECK(env, AXIS2_FAILURE);
 
2503
                AXIS2_PARAM_CHECK(env->error, _describeNetworksResponseType, AXIS2_FAILURE);
 
2504
 
 
2505
                if(_describeNetworksResponseType->property_activeNetworks == NULL ||
 
2506
                            _describeNetworksResponseType->is_valid_activeNetworks == AXIS2_FALSE)
 
2507
                {
 
2508
 
 
2509
                    non_nil_exists = AXIS2_FALSE;
 
2510
                }
 
2511
                else
 
2512
                {
 
2513
                    size = axutil_array_list_size(_describeNetworksResponseType->property_activeNetworks, env);
 
2514
                    for(j = 0, k = 0; j < size; j ++ )
 
2515
                    {
 
2516
                        if(i == j) continue;
 
2517
                        if(NULL != axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i))
 
2518
                        {
 
2519
                            k ++;
 
2520
                            non_nil_exists = AXIS2_TRUE;
 
2521
                            if( k >= 0)
 
2522
                            {
 
2523
                                break;
 
2524
                            }
 
2525
                        }
 
2526
                    }
 
2527
                }
 
2528
 
 
2529
 
 
2530
                if( k < 0)
 
2531
                {
 
2532
                       AXIS2_LOG_ERROR(env->log, AXIS2_LOG_SI, "Size of the array of activeNetworks is beinng set to be smaller than the specificed number of minOccurs(0)");
 
2533
                       return AXIS2_FAILURE;
 
2534
                }
 
2535
 
 
2536
                if(_describeNetworksResponseType->property_activeNetworks == NULL)
 
2537
                {
 
2538
                    _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_FALSE;
 
2539
 
 
2540
                    return AXIS2_SUCCESS;
 
2541
                }
 
2542
 
 
2543
                /* check whether there already exist an element */
 
2544
                element = axutil_array_list_get(_describeNetworksResponseType->property_activeNetworks, env, i);
 
2545
                if(NULL != element)
 
2546
                {
 
2547
 
 
2548
 
 
2549
 
 
2550
                        adb_networkType_free((adb_networkType_t*)element, env);
 
2551
 
 
2552
                }
 
2553
 
 
2554
 
 
2555
                    if(!non_nil_exists)
 
2556
                    {
 
2557
 
 
2558
                        _describeNetworksResponseType->is_valid_activeNetworks = AXIS2_FALSE;
 
2559
                        axutil_array_list_set(_describeNetworksResponseType->property_activeNetworks , env, i, NULL);
 
2560
                        return AXIS2_SUCCESS;
 
2561
                    }
 
2562
 
 
2563
 
 
2564
 
 
2565
                axutil_array_list_set(_describeNetworksResponseType->property_activeNetworks , env, i, NULL);
 
2566
 
 
2567
                return AXIS2_SUCCESS;
 
2568
 
 
2569
           }
 
2570
 
 
2571
 
 
2572