ovirt-engine-sdk 4.1.2 → 4.1.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ddf0ca50c29a4459a5294f8c37b1fbb6259fdd45
4
- data.tar.gz: 63bd397c04570ce3619146fb25009e556798e18e
3
+ metadata.gz: 22a7c855a53c1b32e3b9df0d0bf25db956967687
4
+ data.tar.gz: 6c544a7ea75375a633031bd53e5a5be3619ac3b8
5
5
  SHA512:
6
- metadata.gz: bd72d1fdfb18d03aedd4a77cbef3a3f432eed016332c949930651ae19f43e538760bd2118e7814c5a82758feb8ca60b6270324f9608b6c8653882a75596cbb3c
7
- data.tar.gz: 203ab888e1e8eab72c64051e28161aa80a0b80b08b7a81ff5917619e243293d8d92d8cae858bbac2e8ae6890762cd2fa91fbe2d1f01679f0519146c951039739
6
+ metadata.gz: e6cd47aa648b9c8bc799388842c4f84aa4e87e8835c8d041f2745c9610890945cb16c0f188fc935fda7bf9b0a1aa799c268e3cb3b49b929e4b76c0820795f7c2
7
+ data.tar.gz: 220d61015ea7dda94db7d5a410c29f1b1187fc5a281d84a12b0832a6181243c7f6fdce434b94d81de43b66e81d892ac742bbeef3a0395cbb440e39925529e8e3
data/CHANGES.adoc CHANGED
@@ -2,6 +2,33 @@
2
2
 
3
3
  This document describes the relevant changes between releases of the SDK.
4
4
 
5
+ == 4.1.3 / Mar 2 2017
6
+
7
+ Update to model 4.1.31:
8
+
9
+ * Add `auto_storage_select` attribute to the `VmPool` type.
10
+
11
+ * Move `vnic_profile_mappings` and `reassign_bad_macs` from
12
+ the `import` operation to the `register` operation
13
+
14
+ * Add IPv6 details to the `NicConfiguration` type.
15
+
16
+ * Add NFS 4.2 support.
17
+
18
+ New features:
19
+
20
+ * Add support for custom headers and query parameters.
21
+
22
+ * Ignore unsupported enum values.
23
+
24
+ * Check that URL has been provided.
25
+
26
+ * Send INFO log messages with summaries of requests and responses.
27
+
28
+ Bug fixes:
29
+
30
+ * Fix writing of lists of structs.
31
+
5
32
  == 4.1.2 / Feb 9 2017
6
33
 
7
34
  Bug fixes:
@@ -19,6 +19,7 @@ limitations under the License.
19
19
 
20
20
  #include <ctype.h>
21
21
  #include <curl/curl.h>
22
+ #include <stdarg.h>
22
23
  #include <stdbool.h>
23
24
  #include <stdlib.h>
24
25
  #include <string.h>
@@ -48,6 +49,8 @@ static VALUE PROXY_PASSWORD_SYMBOL;
48
49
  /* Method identifiers: */
49
50
  static ID DEBUG_ID;
50
51
  static ID ENCODE_WWW_FORM_ID;
52
+ static ID INFO_ID;
53
+ static ID INFO_Q_ID;
51
54
  static ID READ_ID;
52
55
  static ID STRING_ID;
53
56
  static ID STRING_IO_ID;
@@ -549,6 +552,22 @@ static void ov_http_client_perform_cancel(void* data) {
549
552
  perform_context->cancel = true;
550
553
  }
551
554
 
555
+ static void ov_http_client_log_info(VALUE log, const char* format, ...) {
556
+ VALUE enabled;
557
+ VALUE message;
558
+ va_list args;
559
+
560
+ if (!NIL_P(log)) {
561
+ enabled = rb_funcall(log, INFO_Q_ID, 0);
562
+ if (RTEST(enabled)) {
563
+ va_start(args, format);
564
+ message = rb_vsprintf(format, args);
565
+ rb_funcall(log, INFO_ID, 1, message);
566
+ va_end(args);
567
+ }
568
+ }
569
+ }
570
+
552
571
  static VALUE ov_http_client_send(VALUE self, VALUE request, VALUE response) {
553
572
  VALUE header;
554
573
  VALUE url;
@@ -626,6 +645,14 @@ static VALUE ov_http_client_send(VALUE self, VALUE request, VALUE response) {
626
645
  }
627
646
  curl_easy_setopt(object->curl, CURLOPT_HTTPHEADER, headers);
628
647
 
648
+ /* Send a summary of the request to the log: */
649
+ ov_http_client_log_info(
650
+ object->log,
651
+ "Sending '%"PRIsVALUE"' request to URL '%"PRIsVALUE"'.",
652
+ request_object->method,
653
+ url
654
+ );
655
+
629
656
  /* Performing the request is a potentially lengthy and blocking operation, so we need to make sure that it runs
630
657
  without the global interpreter lock acquired as much as possible: */
631
658
  perform_context.object = object;
@@ -674,6 +701,13 @@ static VALUE ov_http_client_send(VALUE self, VALUE request, VALUE response) {
674
701
  /* Get the response body: */
675
702
  response_object->body = rb_funcall(perform_context.out, STRING_ID, 0);
676
703
 
704
+ /* Send a summary of the response to the log: */
705
+ ov_http_client_log_info(
706
+ object->log,
707
+ "Received response code '%"PRIsVALUE"'.",
708
+ response_object->code
709
+ );
710
+
677
711
  return Qnil;
678
712
  }
679
713
 
@@ -712,6 +746,8 @@ void ov_http_client_define(void) {
712
746
  /* Define the method identifiers: */
713
747
  DEBUG_ID = rb_intern("debug");
714
748
  ENCODE_WWW_FORM_ID = rb_intern("encode_www_form");
749
+ INFO_ID = rb_intern("info");
750
+ INFO_Q_ID = rb_intern("info?");
715
751
  READ_ID = rb_intern("read");
716
752
  STRING_ID = rb_intern("string");
717
753
  STRING_IO_ID = rb_intern("StringIO");
@@ -92,6 +92,11 @@ module OvirtSDK4
92
92
  #
93
93
  # @option opts [String] :proxy_password The password of the user to authenticate to the proxy server.
94
94
  #
95
+ # @option opts [Hash] :headers Custom HTTP headers to send with all requests. The keys of the hash can be
96
+ # strings of symbols, and they will be used as the names of the headers. The values of the hash will be used
97
+ # as the names of the headers. If the same header is provided here and in the `headers` parameter of a specific
98
+ # method call, then the `headers` parameter of the specific method call will have precendence.
99
+ #
95
100
  def initialize(opts = {})
96
101
  # Get the values of the parameters and assign default values:
97
102
  @url = opts[:url]
@@ -109,6 +114,10 @@ module OvirtSDK4
109
114
  @proxy_url = opts[:proxy_url]
110
115
  @proxy_username = opts[:proxy_username]
111
116
  @proxy_password = opts[:proxy_password]
117
+ @headers = opts[:headers]
118
+
119
+ # Check that the URL has been provided:
120
+ raise ArgumentError, "The 'url' option is mandatory" unless @url
112
121
 
113
122
  # Automatically disable compression when debug is enabled, as otherwise the debug output generated by
114
123
  # libcurl is also compressed, and that isn't useful for debugging:
@@ -192,6 +201,9 @@ module OvirtSDK4
192
201
  request.headers['All-Content'] = all_content unless all_content.nil?
193
202
  end
194
203
 
204
+ # Add the global headers, but without replacing the values that may already exist:
205
+ request.headers.merge!(@headers) { |_name, local, _global| local } if @headers
206
+
195
207
  # Set the authentication token:
196
208
  @token ||= create_access_token
197
209
  request.token = @token
@@ -272,6 +284,9 @@ module OvirtSDK4
272
284
  body: URI.encode_www_form(parameters)
273
285
  )
274
286
 
287
+ # Add the global headers:
288
+ request.headers.merge!(@headers) if @headers
289
+
275
290
  # Create an empty response:
276
291
  response = HttpResponse.new
277
292
 
@@ -189,6 +189,46 @@ module OvirtSDK4
189
189
  reader.read_elements.map { |text| Reader.parse_date(text) }
190
190
  end
191
191
 
192
+ #
193
+ # Converts the given text to an enum.
194
+ #
195
+ # @param enum_type [module]
196
+ # @param text [String]
197
+ # @return [String]
198
+ #
199
+ def self.parse_enum(enum_type, text)
200
+ return nil unless text
201
+ begin
202
+ text if enum_type.constants.map(&:downcase).include?(text.to_sym)
203
+ rescue
204
+ nil
205
+ end
206
+ end
207
+
208
+ #
209
+ # Reads a enum value, assuming that the cursor is positioned at the
210
+ # start element that contains the value.
211
+ #
212
+ # @param enum_type [module]
213
+ # @param reader [XmlReader]
214
+ # @return [Array<String>]
215
+ #
216
+ def self.read_enum(enum_type, reader)
217
+ Reader.parse_enum(enum_type, reader.read_element)
218
+ end
219
+
220
+ #
221
+ # Reads a list of enum values, assuming that the cursor is positioned
222
+ # at the start element of the element that contains the first value.
223
+ #
224
+ # @param enum_type [module]
225
+ # @param reader [XmlReader]
226
+ # @return [Array<String>]
227
+ #
228
+ def self.read_enums(enum_type, reader)
229
+ reader.read_elements.map { |text| Reader.parse_enum(enum_type, text) }
230
+ end
231
+
192
232
  #
193
233
  # This hash stores for each known tag a reference to the method that read the object corresponding for that tag. For
194
234
  # example, for the `vm` tag it will contain a reference to the `VmReader.read_one` method, and for the `vms` tag
@@ -708,7 +708,7 @@ module OvirtSDK4
708
708
  when 'address'
709
709
  object.address = Reader.read_string(reader)
710
710
  when 'broker_type'
711
- object.broker_type = Reader.read_string(reader)
711
+ object.broker_type = Reader.read_enum(BrokerType, reader)
712
712
  when 'network_mappings'
713
713
  object.network_mappings = Reader.read_string(reader)
714
714
  when 'password'
@@ -1474,7 +1474,7 @@ module OvirtSDK4
1474
1474
  while reader.forward do
1475
1475
  case reader.node_name
1476
1476
  when 'devices'
1477
- object.devices = Reader.read_strings(reader)
1477
+ object.devices = Reader.read_enums(BootDevice, reader)
1478
1478
  else
1479
1479
  reader.next_element
1480
1480
  end
@@ -1989,13 +1989,13 @@ module OvirtSDK4
1989
1989
  when 'optional_reason'
1990
1990
  object.optional_reason = Reader.read_boolean(reader)
1991
1991
  when 'required_rng_sources'
1992
- object.required_rng_sources = Reader.read_strings(reader)
1992
+ object.required_rng_sources = Reader.read_enums(RngSource, reader)
1993
1993
  when 'serial_number'
1994
1994
  object.serial_number = SerialNumberReader.read_one(reader)
1995
1995
  when 'supported_versions'
1996
1996
  object.supported_versions = VersionReader.read_many(reader)
1997
1997
  when 'switch_type'
1998
- object.switch_type = Reader.read_string(reader)
1998
+ object.switch_type = Reader.read_enum(SwitchType, reader)
1999
1999
  when 'threads_as_cores'
2000
2000
  object.threads_as_cores = Reader.read_boolean(reader)
2001
2001
  when 'trusted_service'
@@ -2202,7 +2202,7 @@ module OvirtSDK4
2202
2202
  when 'data'
2203
2203
  object.data = Reader.read_string(reader)
2204
2204
  when 'type'
2205
- object.type = Reader.read_string(reader)
2205
+ object.type = Reader.read_enum(Type, reader)
2206
2206
  else
2207
2207
  reader.next_element
2208
2208
  end
@@ -2402,7 +2402,7 @@ module OvirtSDK4
2402
2402
  while reader.forward do
2403
2403
  case reader.node_name
2404
2404
  when 'architecture'
2405
- object.architecture = Reader.read_string(reader)
2405
+ object.architecture = Reader.read_enum(Architecture, reader)
2406
2406
  when 'cores'
2407
2407
  object.cores = CoreReader.read_many(reader)
2408
2408
  when 'cpu_tune'
@@ -2410,7 +2410,7 @@ module OvirtSDK4
2410
2410
  when 'level'
2411
2411
  object.level = Reader.read_integer(reader)
2412
2412
  when 'mode'
2413
- object.mode = Reader.read_string(reader)
2413
+ object.mode = Reader.read_enum(Mode, reader)
2414
2414
  when 'name'
2415
2415
  object.name = Reader.read_string(reader)
2416
2416
  when 'speed'
@@ -2713,7 +2713,7 @@ module OvirtSDK4
2713
2713
  while reader.forward do
2714
2714
  case reader.node_name
2715
2715
  when 'architecture'
2716
- object.architecture = Reader.read_string(reader)
2716
+ object.architecture = Reader.read_enum(Architecture, reader)
2717
2717
  when 'level'
2718
2718
  object.level = Reader.read_integer(reader)
2719
2719
  when 'name'
@@ -2873,11 +2873,11 @@ module OvirtSDK4
2873
2873
  when 'name'
2874
2874
  object.name = Reader.read_string(reader)
2875
2875
  when 'quota_mode'
2876
- object.quota_mode = Reader.read_string(reader)
2876
+ object.quota_mode = Reader.read_enum(QuotaMode, reader)
2877
2877
  when 'status'
2878
- object.status = Reader.read_string(reader)
2878
+ object.status = Reader.read_enum(Status, reader)
2879
2879
  when 'storage_format'
2880
- object.storage_format = Reader.read_string(reader)
2880
+ object.storage_format = Reader.read_enum(StorageFormat, reader)
2881
2881
  when 'supported_versions'
2882
2882
  object.supported_versions = VersionReader.read_many(reader)
2883
2883
  when 'version'
@@ -3149,7 +3149,7 @@ module OvirtSDK4
3149
3149
  when 'description'
3150
3150
  object.description = Reader.read_string(reader)
3151
3151
  when 'format'
3152
- object.format = Reader.read_string(reader)
3152
+ object.format = Reader.read_enum(Format, reader)
3153
3153
  when 'id'
3154
3154
  object.id = Reader.read_string(reader)
3155
3155
  when 'image_id'
@@ -3157,7 +3157,7 @@ module OvirtSDK4
3157
3157
  when 'initial_size'
3158
3158
  object.initial_size = Reader.read_integer(reader)
3159
3159
  when 'interface'
3160
- object.interface = Reader.read_string(reader)
3160
+ object.interface = Reader.read_enum(Interface, reader)
3161
3161
  when 'logical_name'
3162
3162
  object.logical_name = Reader.read_string(reader)
3163
3163
  when 'lun_storage'
@@ -3169,19 +3169,19 @@ module OvirtSDK4
3169
3169
  when 'provisioned_size'
3170
3170
  object.provisioned_size = Reader.read_integer(reader)
3171
3171
  when 'qcow_version'
3172
- object.qcow_version = Reader.read_string(reader)
3172
+ object.qcow_version = Reader.read_enum(QcowVersion, reader)
3173
3173
  when 'read_only'
3174
3174
  object.read_only = Reader.read_boolean(reader)
3175
3175
  when 'sgio'
3176
- object.sgio = Reader.read_string(reader)
3176
+ object.sgio = Reader.read_enum(Sgio, reader)
3177
3177
  when 'shareable'
3178
3178
  object.shareable = Reader.read_boolean(reader)
3179
3179
  when 'sparse'
3180
3180
  object.sparse = Reader.read_boolean(reader)
3181
3181
  when 'status'
3182
- object.status = Reader.read_string(reader)
3182
+ object.status = Reader.read_enum(Status, reader)
3183
3183
  when 'storage_type'
3184
- object.storage_type = Reader.read_string(reader)
3184
+ object.storage_type = Reader.read_enum(StorageType, reader)
3185
3185
  when 'uses_scsi_reservation'
3186
3186
  object.uses_scsi_reservation = Reader.read_boolean(reader)
3187
3187
  when 'wipe_after_delete'
@@ -3324,7 +3324,7 @@ module OvirtSDK4
3324
3324
  when 'id'
3325
3325
  object.id = Reader.read_string(reader)
3326
3326
  when 'interface'
3327
- object.interface = Reader.read_string(reader)
3327
+ object.interface = Reader.read_enum(Interface, reader)
3328
3328
  when 'logical_name'
3329
3329
  object.logical_name = Reader.read_string(reader)
3330
3330
  when 'name'
@@ -3557,7 +3557,7 @@ module OvirtSDK4
3557
3557
  when 'description'
3558
3558
  object.description = Reader.read_string(reader)
3559
3559
  when 'format'
3560
- object.format = Reader.read_string(reader)
3560
+ object.format = Reader.read_enum(Format, reader)
3561
3561
  when 'id'
3562
3562
  object.id = Reader.read_string(reader)
3563
3563
  when 'image_id'
@@ -3565,7 +3565,7 @@ module OvirtSDK4
3565
3565
  when 'initial_size'
3566
3566
  object.initial_size = Reader.read_integer(reader)
3567
3567
  when 'interface'
3568
- object.interface = Reader.read_string(reader)
3568
+ object.interface = Reader.read_enum(Interface, reader)
3569
3569
  when 'logical_name'
3570
3570
  object.logical_name = Reader.read_string(reader)
3571
3571
  when 'lun_storage'
@@ -3577,19 +3577,19 @@ module OvirtSDK4
3577
3577
  when 'provisioned_size'
3578
3578
  object.provisioned_size = Reader.read_integer(reader)
3579
3579
  when 'qcow_version'
3580
- object.qcow_version = Reader.read_string(reader)
3580
+ object.qcow_version = Reader.read_enum(QcowVersion, reader)
3581
3581
  when 'read_only'
3582
3582
  object.read_only = Reader.read_boolean(reader)
3583
3583
  when 'sgio'
3584
- object.sgio = Reader.read_string(reader)
3584
+ object.sgio = Reader.read_enum(Sgio, reader)
3585
3585
  when 'shareable'
3586
3586
  object.shareable = Reader.read_boolean(reader)
3587
3587
  when 'sparse'
3588
3588
  object.sparse = Reader.read_boolean(reader)
3589
3589
  when 'status'
3590
- object.status = Reader.read_string(reader)
3590
+ object.status = Reader.read_enum(Status, reader)
3591
3591
  when 'storage_type'
3592
- object.storage_type = Reader.read_string(reader)
3592
+ object.storage_type = Reader.read_enum(StorageType, reader)
3593
3593
  when 'uses_scsi_reservation'
3594
3594
  object.uses_scsi_reservation = Reader.read_boolean(reader)
3595
3595
  when 'wipe_after_delete'
@@ -3756,7 +3756,7 @@ module OvirtSDK4
3756
3756
  when 'smartcard_enabled'
3757
3757
  object.smartcard_enabled = Reader.read_boolean(reader)
3758
3758
  when 'type'
3759
- object.type = Reader.read_string(reader)
3759
+ object.type = Reader.read_enum(Type, reader)
3760
3760
  else
3761
3761
  reader.next_element
3762
3762
  end
@@ -4101,7 +4101,7 @@ module OvirtSDK4
4101
4101
  while reader.forward do
4102
4102
  case reader.node_name
4103
4103
  when 'on_error'
4104
- object.on_error = Reader.read_string(reader)
4104
+ object.on_error = Reader.read_enum(OnError, reader)
4105
4105
  else
4106
4106
  reader.next_element
4107
4107
  end
@@ -4205,7 +4205,7 @@ module OvirtSDK4
4205
4205
  when 'origin'
4206
4206
  object.origin = Reader.read_string(reader)
4207
4207
  when 'severity'
4208
- object.severity = Reader.read_string(reader)
4208
+ object.severity = Reader.read_enum(Severity, reader)
4209
4209
  when 'time'
4210
4210
  object.time = Reader.read_date(reader)
4211
4211
  when 'cluster'
@@ -4878,7 +4878,7 @@ module OvirtSDK4
4878
4878
  when 'password'
4879
4879
  object.password = Reader.read_string(reader)
4880
4880
  when 'provider'
4881
- object.provider = Reader.read_string(reader)
4881
+ object.provider = Reader.read_enum(Provider, reader)
4882
4882
  when 'sparse'
4883
4883
  object.sparse = Reader.read_boolean(reader)
4884
4884
  when 'url'
@@ -5479,7 +5479,7 @@ module OvirtSDK4
5479
5479
  when 'server_id'
5480
5480
  object.server_id = Reader.read_string(reader)
5481
5481
  when 'status'
5482
- object.status = Reader.read_string(reader)
5482
+ object.status = Reader.read_enum(Status, reader)
5483
5483
  when 'gluster_volume'
5484
5484
  object.gluster_volume = GlusterVolumeReader.read_one(reader)
5485
5485
  when 'instance_type'
@@ -5865,7 +5865,7 @@ module OvirtSDK4
5865
5865
  when 'content'
5866
5866
  object.content = Reader.read_string(reader)
5867
5867
  when 'content_type'
5868
- object.content_type = Reader.read_string(reader)
5868
+ object.content_type = Reader.read_enum(ContentType, reader)
5869
5869
  when 'description'
5870
5870
  object.description = Reader.read_string(reader)
5871
5871
  when 'gluster_command'
@@ -5875,9 +5875,9 @@ module OvirtSDK4
5875
5875
  when 'name'
5876
5876
  object.name = Reader.read_string(reader)
5877
5877
  when 'stage'
5878
- object.stage = Reader.read_string(reader)
5878
+ object.stage = Reader.read_enum(Stage, reader)
5879
5879
  when 'status'
5880
- object.status = Reader.read_string(reader)
5880
+ object.status = Reader.read_enum(Status, reader)
5881
5881
  when 'cluster'
5882
5882
  object.cluster = ClusterReader.read_one(reader)
5883
5883
  when 'server_hooks'
@@ -6084,7 +6084,7 @@ module OvirtSDK4
6084
6084
  when 'comment'
6085
6085
  object.comment = Reader.read_string(reader)
6086
6086
  when 'content_type'
6087
- object.content_type = Reader.read_string(reader)
6087
+ object.content_type = Reader.read_enum(ContentType, reader)
6088
6088
  when 'description'
6089
6089
  object.description = Reader.read_string(reader)
6090
6090
  when 'id'
@@ -6092,7 +6092,7 @@ module OvirtSDK4
6092
6092
  when 'name'
6093
6093
  object.name = Reader.read_string(reader)
6094
6094
  when 'status'
6095
- object.status = Reader.read_string(reader)
6095
+ object.status = Reader.read_enum(Status, reader)
6096
6096
  when 'host'
6097
6097
  object.host = HostReader.read_one(reader)
6098
6098
  else
@@ -6190,13 +6190,13 @@ module OvirtSDK4
6190
6190
  when 'replica_count'
6191
6191
  object.replica_count = Reader.read_integer(reader)
6192
6192
  when 'status'
6193
- object.status = Reader.read_string(reader)
6193
+ object.status = Reader.read_enum(Status, reader)
6194
6194
  when 'stripe_count'
6195
6195
  object.stripe_count = Reader.read_integer(reader)
6196
6196
  when 'transport_types'
6197
- object.transport_types = Reader.read_strings(reader)
6197
+ object.transport_types = Reader.read_enums(TransportType, reader)
6198
6198
  when 'volume_type'
6199
- object.volume_type = Reader.read_string(reader)
6199
+ object.volume_type = Reader.read_enum(VolumeType, reader)
6200
6200
  when 'bricks'
6201
6201
  object.bricks = GlusterBrickReader.read_many(reader)
6202
6202
  when 'cluster'
@@ -6451,7 +6451,7 @@ module OvirtSDK4
6451
6451
  when 'port'
6452
6452
  object.port = Reader.read_integer(reader)
6453
6453
  when 'protocol'
6454
- object.protocol = Reader.read_string(reader)
6454
+ object.protocol = Reader.read_enum(Protocol, reader)
6455
6455
  when 'tls_port'
6456
6456
  object.tls_port = Reader.read_integer(reader)
6457
6457
  when 'instance_type'
@@ -6730,7 +6730,7 @@ module OvirtSDK4
6730
6730
  when 'serial_number'
6731
6731
  object.serial_number = Reader.read_string(reader)
6732
6732
  when 'supported_rng_sources'
6733
- object.supported_rng_sources = Reader.read_strings(reader)
6733
+ object.supported_rng_sources = Reader.read_enums(RngSource, reader)
6734
6734
  when 'uuid'
6735
6735
  object.uuid = Reader.read_string(reader)
6736
6736
  when 'version'
@@ -6984,7 +6984,7 @@ module OvirtSDK4
6984
6984
  when 'address'
6985
6985
  object.address = Reader.read_string(reader)
6986
6986
  when 'auto_numa_status'
6987
- object.auto_numa_status = Reader.read_string(reader)
6987
+ object.auto_numa_status = Reader.read_enum(AutoNumaStatus, reader)
6988
6988
  when 'certificate'
6989
6989
  object.certificate = CertificateReader.read_one(reader)
6990
6990
  when 'comment'
@@ -6998,7 +6998,7 @@ module OvirtSDK4
6998
6998
  when 'display'
6999
6999
  object.display = DisplayReader.read_one(reader)
7000
7000
  when 'external_status'
7001
- object.external_status = Reader.read_string(reader)
7001
+ object.external_status = Reader.read_enum(ExternalStatus, reader)
7002
7002
  when 'hardware_information'
7003
7003
  object.hardware_information = HardwareInformationReader.read_one(reader)
7004
7004
  when 'hosted_engine'
@@ -7008,7 +7008,7 @@ module OvirtSDK4
7008
7008
  when 'iscsi'
7009
7009
  object.iscsi = IscsiDetailsReader.read_one(reader)
7010
7010
  when 'kdump_status'
7011
- object.kdump_status = Reader.read_string(reader)
7011
+ object.kdump_status = Reader.read_enum(KdumpStatus, reader)
7012
7012
  when 'ksm'
7013
7013
  object.ksm = KsmReader.read_one(reader)
7014
7014
  when 'libvirt_version'
@@ -7030,7 +7030,7 @@ module OvirtSDK4
7030
7030
  when 'power_management'
7031
7031
  object.power_management = PowerManagementReader.read_one(reader)
7032
7032
  when 'protocol'
7033
- object.protocol = Reader.read_string(reader)
7033
+ object.protocol = Reader.read_enum(Protocol, reader)
7034
7034
  when 'root_password'
7035
7035
  object.root_password = Reader.read_string(reader)
7036
7036
  when 'se_linux'
@@ -7040,7 +7040,7 @@ module OvirtSDK4
7040
7040
  when 'ssh'
7041
7041
  object.ssh = SshReader.read_one(reader)
7042
7042
  when 'status'
7043
- object.status = Reader.read_string(reader)
7043
+ object.status = Reader.read_enum(Status, reader)
7044
7044
  when 'status_detail'
7045
7045
  object.status_detail = Reader.read_string(reader)
7046
7046
  when 'summary'
@@ -7048,7 +7048,7 @@ module OvirtSDK4
7048
7048
  when 'transparent_hugepages'
7049
7049
  object.transparent_huge_pages = TransparentHugePagesReader.read_one(reader)
7050
7050
  when 'type'
7051
- object.type = Reader.read_string(reader)
7051
+ object.type = Reader.read_enum(Type, reader)
7052
7052
  when 'update_available'
7053
7053
  object.update_available = Reader.read_boolean(reader)
7054
7054
  when 'version'
@@ -7389,7 +7389,7 @@ module OvirtSDK4
7389
7389
  when 'bonding'
7390
7390
  object.bonding = BondingReader.read_one(reader)
7391
7391
  when 'boot_protocol'
7392
- object.boot_protocol = Reader.read_string(reader)
7392
+ object.boot_protocol = Reader.read_enum(BootProtocol, reader)
7393
7393
  when 'bridged'
7394
7394
  object.bridged = Reader.read_boolean(reader)
7395
7395
  when 'check_connectivity'
@@ -7407,7 +7407,7 @@ module OvirtSDK4
7407
7407
  when 'ipv6'
7408
7408
  object.ipv6 = IpReader.read_one(reader)
7409
7409
  when 'ipv6_boot_protocol'
7410
- object.ipv6_boot_protocol = Reader.read_string(reader)
7410
+ object.ipv6_boot_protocol = Reader.read_enum(Ipv6BootProtocol, reader)
7411
7411
  when 'mac'
7412
7412
  object.mac = MacReader.read_one(reader)
7413
7413
  when 'mtu'
@@ -7425,7 +7425,7 @@ module OvirtSDK4
7425
7425
  when 'statistics'
7426
7426
  object.statistics = StatisticReader.read_many(reader)
7427
7427
  when 'status'
7428
- object.status = Reader.read_string(reader)
7428
+ object.status = Reader.read_enum(Status, reader)
7429
7429
  when 'virtual_functions_configuration'
7430
7430
  object.virtual_functions_configuration = HostNicVirtualFunctionsConfigurationReader.read_one(reader)
7431
7431
  when 'vlan'
@@ -7621,7 +7621,7 @@ module OvirtSDK4
7621
7621
  when 'nfs_timeo'
7622
7622
  object.nfs_timeo = Reader.read_integer(reader)
7623
7623
  when 'nfs_version'
7624
- object.nfs_version = Reader.read_string(reader)
7624
+ object.nfs_version = Reader.read_enum(NfsVersion, reader)
7625
7625
  when 'override_luns'
7626
7626
  object.override_luns = Reader.read_boolean(reader)
7627
7627
  when 'password'
@@ -7635,7 +7635,7 @@ module OvirtSDK4
7635
7635
  when 'target'
7636
7636
  object.target = Reader.read_string(reader)
7637
7637
  when 'type'
7638
- object.type = Reader.read_string(reader)
7638
+ object.type = Reader.read_enum(Type, reader)
7639
7639
  when 'username'
7640
7640
  object.username = Reader.read_string(reader)
7641
7641
  when 'vfs_type'
@@ -8033,13 +8033,13 @@ module OvirtSDK4
8033
8033
  when 'description'
8034
8034
  object.description = Reader.read_string(reader)
8035
8035
  when 'direction'
8036
- object.direction = Reader.read_string(reader)
8036
+ object.direction = Reader.read_enum(Direction, reader)
8037
8037
  when 'id'
8038
8038
  object.id = Reader.read_string(reader)
8039
8039
  when 'name'
8040
8040
  object.name = Reader.read_string(reader)
8041
8041
  when 'phase'
8042
- object.phase = Reader.read_string(reader)
8042
+ object.phase = Reader.read_enum(Phase, reader)
8043
8043
  when 'proxy_url'
8044
8044
  object.proxy_url = Reader.read_string(reader)
8045
8045
  when 'signed_ticket'
@@ -8347,13 +8347,13 @@ module OvirtSDK4
8347
8347
  when 'stateless'
8348
8348
  object.stateless = Reader.read_boolean(reader)
8349
8349
  when 'status'
8350
- object.status = Reader.read_string(reader)
8350
+ object.status = Reader.read_enum(Status, reader)
8351
8351
  when 'time_zone'
8352
8352
  object.time_zone = TimeZoneReader.read_one(reader)
8353
8353
  when 'tunnel_migration'
8354
8354
  object.tunnel_migration = Reader.read_boolean(reader)
8355
8355
  when 'type'
8356
- object.type = Reader.read_string(reader)
8356
+ object.type = Reader.read_enum(Type, reader)
8357
8357
  when 'usb'
8358
8358
  object.usb = UsbReader.read_one(reader)
8359
8359
  when 'version'
@@ -8550,7 +8550,7 @@ module OvirtSDK4
8550
8550
  when 'netmask'
8551
8551
  object.netmask = Reader.read_string(reader)
8552
8552
  when 'version'
8553
- object.version = Reader.read_string(reader)
8553
+ object.version = Reader.read_enum(Version, reader)
8554
8554
  else
8555
8555
  reader.next_element
8556
8556
  end
@@ -8612,7 +8612,7 @@ module OvirtSDK4
8612
8612
  while reader.forward do
8613
8613
  case reader.node_name
8614
8614
  when 'assignment_method'
8615
- object.assignment_method = Reader.read_string(reader)
8615
+ object.assignment_method = Reader.read_enum(AssignmentMethod, reader)
8616
8616
  when 'ip'
8617
8617
  object.ip = IpReader.read_one(reader)
8618
8618
  else
@@ -8939,7 +8939,7 @@ module OvirtSDK4
8939
8939
  when 'start_time'
8940
8940
  object.start_time = Reader.read_date(reader)
8941
8941
  when 'status'
8942
- object.status = Reader.read_string(reader)
8942
+ object.status = Reader.read_enum(Status, reader)
8943
8943
  when 'owner'
8944
8944
  object.owner = UserReader.read_one(reader)
8945
8945
  when 'steps'
@@ -9316,7 +9316,7 @@ module OvirtSDK4
9316
9316
  when 'size'
9317
9317
  object.size = Reader.read_integer(reader)
9318
9318
  when 'status'
9319
- object.status = Reader.read_string(reader)
9319
+ object.status = Reader.read_enum(Status, reader)
9320
9320
  when 'storage_domain_id'
9321
9321
  object.storage_domain_id = Reader.read_string(reader)
9322
9322
  when 'target'
@@ -9670,7 +9670,7 @@ module OvirtSDK4
9670
9670
  while reader.forward do
9671
9671
  case reader.node_name
9672
9672
  when 'id'
9673
- object.id = Reader.read_string(reader)
9673
+ object.id = Reader.read_enum(Id, reader)
9674
9674
  else
9675
9675
  reader.next_element
9676
9676
  end
@@ -9734,7 +9734,7 @@ module OvirtSDK4
9734
9734
  while reader.forward do
9735
9735
  case reader.node_name
9736
9736
  when 'assignment_method'
9737
- object.assignment_method = Reader.read_string(reader)
9737
+ object.assignment_method = Reader.read_enum(AssignmentMethod, reader)
9738
9738
  when 'custom_value'
9739
9739
  object.custom_value = Reader.read_integer(reader)
9740
9740
  else
@@ -9800,11 +9800,11 @@ module OvirtSDK4
9800
9800
  while reader.forward do
9801
9801
  case reader.node_name
9802
9802
  when 'auto_converge'
9803
- object.auto_converge = Reader.read_string(reader)
9803
+ object.auto_converge = Reader.read_enum(AutoConverge, reader)
9804
9804
  when 'bandwidth'
9805
9805
  object.bandwidth = MigrationBandwidthReader.read_one(reader)
9806
9806
  when 'compressed'
9807
- object.compressed = Reader.read_string(reader)
9807
+ object.compressed = Reader.read_enum(Compressed, reader)
9808
9808
  when 'policy'
9809
9809
  object.policy = MigrationPolicyReader.read_one(reader)
9810
9810
  else
@@ -9980,11 +9980,11 @@ module OvirtSDK4
9980
9980
  when 'required'
9981
9981
  object.required = Reader.read_boolean(reader)
9982
9982
  when 'status'
9983
- object.status = Reader.read_string(reader)
9983
+ object.status = Reader.read_enum(Status, reader)
9984
9984
  when 'stp'
9985
9985
  object.stp = Reader.read_boolean(reader)
9986
9986
  when 'usages'
9987
- object.usages = Reader.read_strings(reader)
9987
+ object.usages = Reader.read_enums(NetworkUsage, reader)
9988
9988
  when 'vlan'
9989
9989
  object.vlan = VlanReader.read_one(reader)
9990
9990
  when 'cluster'
@@ -10473,7 +10473,7 @@ module OvirtSDK4
10473
10473
  while reader.forward do
10474
10474
  case reader.node_name
10475
10475
  when 'boot_protocol'
10476
- object.boot_protocol = Reader.read_string(reader)
10476
+ object.boot_protocol = Reader.read_enum(BootProtocol, reader)
10477
10477
  when 'comment'
10478
10478
  object.comment = Reader.read_string(reader)
10479
10479
  when 'description'
@@ -10481,7 +10481,7 @@ module OvirtSDK4
10481
10481
  when 'id'
10482
10482
  object.id = Reader.read_string(reader)
10483
10483
  when 'interface'
10484
- object.interface = Reader.read_string(reader)
10484
+ object.interface = Reader.read_enum(Interface, reader)
10485
10485
  when 'linked'
10486
10486
  object.linked = Reader.read_boolean(reader)
10487
10487
  when 'mac'
@@ -10612,7 +10612,7 @@ module OvirtSDK4
10612
10612
  while reader.forward do
10613
10613
  case reader.node_name
10614
10614
  when 'boot_protocol'
10615
- object.boot_protocol = Reader.read_string(reader)
10615
+ object.boot_protocol = Reader.read_enum(BootProtocol, reader)
10616
10616
  when 'ip'
10617
10617
  object.ip = IpReader.read_one(reader)
10618
10618
  when 'name'
@@ -11174,7 +11174,7 @@ module OvirtSDK4
11174
11174
  when 'password'
11175
11175
  object.password = Reader.read_string(reader)
11176
11176
  when 'plugin_type'
11177
- object.plugin_type = Reader.read_string(reader)
11177
+ object.plugin_type = Reader.read_enum(PluginType, reader)
11178
11178
  when 'properties'
11179
11179
  object.properties = PropertyReader.read_many(reader)
11180
11180
  when 'read_only'
@@ -11184,7 +11184,7 @@ module OvirtSDK4
11184
11184
  when 'tenant_name'
11185
11185
  object.tenant_name = Reader.read_string(reader)
11186
11186
  when 'type'
11187
- object.type = Reader.read_string(reader)
11187
+ object.type = Reader.read_enum(Type, reader)
11188
11188
  when 'url'
11189
11189
  object.url = Reader.read_string(reader)
11190
11190
  when 'username'
@@ -11702,7 +11702,7 @@ module OvirtSDK4
11702
11702
  when 'name'
11703
11703
  object.name = Reader.read_string(reader)
11704
11704
  when 'usage_type'
11705
- object.usage_type = Reader.read_string(reader)
11705
+ object.usage_type = Reader.read_enum(UsageType, reader)
11706
11706
  when 'uuid'
11707
11707
  object.uuid = Reader.read_string(reader)
11708
11708
  when 'value'
@@ -12070,7 +12070,7 @@ module OvirtSDK4
12070
12070
  when 'files'
12071
12071
  object.files = FileReader.read_many(reader)
12072
12072
  when 'type'
12073
- object.type = Reader.read_string(reader)
12073
+ object.type = Reader.read_enum(Type, reader)
12074
12074
  when 'volume_id'
12075
12075
  object.volume_id = Reader.read_string(reader)
12076
12076
  else
@@ -12310,7 +12310,7 @@ module OvirtSDK4
12310
12310
  while reader.forward do
12311
12311
  case reader.node_name
12312
12312
  when 'type'
12313
- object.type = Reader.read_string(reader)
12313
+ object.type = Reader.read_enum(Type, reader)
12314
12314
  else
12315
12315
  reader.next_element
12316
12316
  end
@@ -12455,7 +12455,7 @@ module OvirtSDK4
12455
12455
  when 'pm_proxies'
12456
12456
  object.pm_proxies = PmProxyReader.read_many(reader)
12457
12457
  when 'status'
12458
- object.status = Reader.read_string(reader)
12458
+ object.status = Reader.read_enum(Status, reader)
12459
12459
  when 'type'
12460
12460
  object.type = Reader.read_string(reader)
12461
12461
  when 'username'
@@ -12943,7 +12943,7 @@ module OvirtSDK4
12943
12943
  when 'outbound_peak'
12944
12944
  object.outbound_peak = Reader.read_integer(reader)
12945
12945
  when 'type'
12946
- object.type = Reader.read_string(reader)
12946
+ object.type = Reader.read_enum(Type, reader)
12947
12947
  when 'data_center'
12948
12948
  object.data_center = DataCenterReader.read_one(reader)
12949
12949
  else
@@ -13540,7 +13540,7 @@ module OvirtSDK4
13540
13540
  when 'name'
13541
13541
  object.name = Reader.read_string(reader)
13542
13542
  when 'type'
13543
- object.type = Reader.read_string(reader)
13543
+ object.type = Reader.read_enum(Type, reader)
13544
13544
  when 'vm'
13545
13545
  object.vm = VmReader.read_one(reader)
13546
13546
  else
@@ -13606,7 +13606,7 @@ module OvirtSDK4
13606
13606
  when 'rate'
13607
13607
  object.rate = RateReader.read_one(reader)
13608
13608
  when 'source'
13609
- object.source = Reader.read_string(reader)
13609
+ object.source = Reader.read_enum(Source, reader)
13610
13610
  else
13611
13611
  reader.next_element
13612
13612
  end
@@ -13912,7 +13912,7 @@ module OvirtSDK4
13912
13912
  when 'properties'
13913
13913
  object.properties = PropertyReader.read_many(reader)
13914
13914
  when 'type'
13915
- object.type = Reader.read_string(reader)
13915
+ object.type = Reader.read_enum(Type, reader)
13916
13916
  else
13917
13917
  reader.next_element
13918
13918
  end
@@ -13974,7 +13974,7 @@ module OvirtSDK4
13974
13974
  while reader.forward do
13975
13975
  case reader.node_name
13976
13976
  when 'mode'
13977
- object.mode = Reader.read_string(reader)
13977
+ object.mode = Reader.read_enum(Mode, reader)
13978
13978
  else
13979
13979
  reader.next_element
13980
13980
  end
@@ -14038,7 +14038,7 @@ module OvirtSDK4
14038
14038
  while reader.forward do
14039
14039
  case reader.node_name
14040
14040
  when 'policy'
14041
- object.policy = Reader.read_string(reader)
14041
+ object.policy = Reader.read_enum(Policy, reader)
14042
14042
  when 'value'
14043
14043
  object.value = Reader.read_string(reader)
14044
14044
  else
@@ -14438,7 +14438,7 @@ module OvirtSDK4
14438
14438
  when 'next_run_configuration_exists'
14439
14439
  object.next_run_configuration_exists = Reader.read_boolean(reader)
14440
14440
  when 'numa_tune_mode'
14441
- object.numa_tune_mode = Reader.read_string(reader)
14441
+ object.numa_tune_mode = Reader.read_enum(NumaTuneMode, reader)
14442
14442
  when 'origin'
14443
14443
  object.origin = Reader.read_string(reader)
14444
14444
  when 'os'
@@ -14458,9 +14458,9 @@ module OvirtSDK4
14458
14458
  when 'small_icon'
14459
14459
  object.small_icon = IconReader.read_one(reader)
14460
14460
  when 'snapshot_status'
14461
- object.snapshot_status = Reader.read_string(reader)
14461
+ object.snapshot_status = Reader.read_enum(SnapshotStatus, reader)
14462
14462
  when 'snapshot_type'
14463
- object.snapshot_type = Reader.read_string(reader)
14463
+ object.snapshot_type = Reader.read_enum(SnapshotType, reader)
14464
14464
  when 'soundcard_enabled'
14465
14465
  object.soundcard_enabled = Reader.read_boolean(reader)
14466
14466
  when 'sso'
@@ -14472,7 +14472,7 @@ module OvirtSDK4
14472
14472
  when 'stateless'
14473
14473
  object.stateless = Reader.read_boolean(reader)
14474
14474
  when 'status'
14475
- object.status = Reader.read_string(reader)
14475
+ object.status = Reader.read_enum(Status, reader)
14476
14476
  when 'status_detail'
14477
14477
  object.status_detail = Reader.read_string(reader)
14478
14478
  when 'stop_reason'
@@ -14484,7 +14484,7 @@ module OvirtSDK4
14484
14484
  when 'tunnel_migration'
14485
14485
  object.tunnel_migration = Reader.read_boolean(reader)
14486
14486
  when 'type'
14487
- object.type = Reader.read_string(reader)
14487
+ object.type = Reader.read_enum(Type, reader)
14488
14488
  when 'usb'
14489
14489
  object.usb = UsbReader.read_one(reader)
14490
14490
  when 'use_latest_template_version'
@@ -14725,7 +14725,7 @@ module OvirtSDK4
14725
14725
  when 'priority'
14726
14726
  object.priority = Reader.read_integer(reader)
14727
14727
  when 'status'
14728
- object.status = Reader.read_string(reader)
14728
+ object.status = Reader.read_enum(Status, reader)
14729
14729
  else
14730
14730
  reader.next_element
14731
14731
  end
@@ -14799,7 +14799,7 @@ module OvirtSDK4
14799
14799
  while reader.forward do
14800
14800
  case reader.node_name
14801
14801
  when 'authentication_method'
14802
- object.authentication_method = Reader.read_string(reader)
14802
+ object.authentication_method = Reader.read_enum(AuthenticationMethod, reader)
14803
14803
  when 'comment'
14804
14804
  object.comment = Reader.read_string(reader)
14805
14805
  when 'description'
@@ -15033,13 +15033,13 @@ module OvirtSDK4
15033
15033
  when 'id'
15034
15034
  object.id = Reader.read_string(reader)
15035
15035
  when 'kind'
15036
- object.kind = Reader.read_string(reader)
15036
+ object.kind = Reader.read_enum(Kind, reader)
15037
15037
  when 'name'
15038
15038
  object.name = Reader.read_string(reader)
15039
15039
  when 'type'
15040
- object.type = Reader.read_string(reader)
15040
+ object.type = Reader.read_enum(Type, reader)
15041
15041
  when 'unit'
15042
- object.unit = Reader.read_string(reader)
15042
+ object.unit = Reader.read_enum(Unit, reader)
15043
15043
  when 'values'
15044
15044
  object.values = ValueReader.read_many(reader)
15045
15045
  when 'brick'
@@ -15151,7 +15151,7 @@ module OvirtSDK4
15151
15151
  when 'external'
15152
15152
  object.external = Reader.read_boolean(reader)
15153
15153
  when 'external_type'
15154
- object.external_type = Reader.read_string(reader)
15154
+ object.external_type = Reader.read_enum(ExternalType, reader)
15155
15155
  when 'id'
15156
15156
  object.id = Reader.read_string(reader)
15157
15157
  when 'name'
@@ -15163,9 +15163,9 @@ module OvirtSDK4
15163
15163
  when 'start_time'
15164
15164
  object.start_time = Reader.read_date(reader)
15165
15165
  when 'status'
15166
- object.status = Reader.read_string(reader)
15166
+ object.status = Reader.read_enum(Status, reader)
15167
15167
  when 'type'
15168
- object.type = Reader.read_string(reader)
15168
+ object.type = Reader.read_enum(Type, reader)
15169
15169
  when 'execution_host'
15170
15170
  object.execution_host = HostReader.read_one(reader)
15171
15171
  when 'job'
@@ -15302,7 +15302,7 @@ module OvirtSDK4
15302
15302
  when 'nfs_timeo'
15303
15303
  object.nfs_timeo = Reader.read_integer(reader)
15304
15304
  when 'nfs_version'
15305
- object.nfs_version = Reader.read_string(reader)
15305
+ object.nfs_version = Reader.read_enum(NfsVersion, reader)
15306
15306
  when 'password'
15307
15307
  object.password = Reader.read_string(reader)
15308
15308
  when 'path'
@@ -15314,7 +15314,7 @@ module OvirtSDK4
15314
15314
  when 'target'
15315
15315
  object.target = Reader.read_string(reader)
15316
15316
  when 'type'
15317
- object.type = Reader.read_string(reader)
15317
+ object.type = Reader.read_enum(Type, reader)
15318
15318
  when 'username'
15319
15319
  object.username = Reader.read_string(reader)
15320
15320
  when 'vfs_type'
@@ -15518,7 +15518,7 @@ module OvirtSDK4
15518
15518
  when 'discard_after_delete'
15519
15519
  object.discard_after_delete = Reader.read_boolean(reader)
15520
15520
  when 'external_status'
15521
- object.external_status = Reader.read_string(reader)
15521
+ object.external_status = Reader.read_enum(ExternalStatus, reader)
15522
15522
  when 'id'
15523
15523
  object.id = Reader.read_string(reader)
15524
15524
  when 'import'
@@ -15528,17 +15528,17 @@ module OvirtSDK4
15528
15528
  when 'name'
15529
15529
  object.name = Reader.read_string(reader)
15530
15530
  when 'status'
15531
- object.status = Reader.read_string(reader)
15531
+ object.status = Reader.read_enum(Status, reader)
15532
15532
  when 'storage'
15533
15533
  object.storage = HostStorageReader.read_one(reader)
15534
15534
  when 'storage_format'
15535
- object.storage_format = Reader.read_string(reader)
15535
+ object.storage_format = Reader.read_enum(StorageFormat, reader)
15536
15536
  when 'supports_discard'
15537
15537
  object.supports_discard = Reader.read_boolean(reader)
15538
15538
  when 'supports_discard_zeroes_data'
15539
15539
  object.supports_discard_zeroes_data = Reader.read_boolean(reader)
15540
15540
  when 'type'
15541
- object.type = Reader.read_string(reader)
15541
+ object.type = Reader.read_enum(Type, reader)
15542
15542
  when 'used'
15543
15543
  object.used = Reader.read_integer(reader)
15544
15544
  when 'warning_low_space_indicator'
@@ -15915,13 +15915,13 @@ module OvirtSDK4
15915
15915
  when 'stateless'
15916
15916
  object.stateless = Reader.read_boolean(reader)
15917
15917
  when 'status'
15918
- object.status = Reader.read_string(reader)
15918
+ object.status = Reader.read_enum(Status, reader)
15919
15919
  when 'time_zone'
15920
15920
  object.time_zone = TimeZoneReader.read_one(reader)
15921
15921
  when 'tunnel_migration'
15922
15922
  object.tunnel_migration = Reader.read_boolean(reader)
15923
15923
  when 'type'
15924
- object.type = Reader.read_string(reader)
15924
+ object.type = Reader.read_enum(Type, reader)
15925
15925
  when 'usb'
15926
15926
  object.usb = UsbReader.read_one(reader)
15927
15927
  when 'version'
@@ -16388,7 +16388,7 @@ module OvirtSDK4
16388
16388
  when 'enabled'
16389
16389
  object.enabled = Reader.read_boolean(reader)
16390
16390
  when 'type'
16391
- object.type = Reader.read_string(reader)
16391
+ object.type = Reader.read_enum(Type, reader)
16392
16392
  else
16393
16393
  reader.next_element
16394
16394
  end
@@ -17248,7 +17248,7 @@ module OvirtSDK4
17248
17248
  when 'next_run_configuration_exists'
17249
17249
  object.next_run_configuration_exists = Reader.read_boolean(reader)
17250
17250
  when 'numa_tune_mode'
17251
- object.numa_tune_mode = Reader.read_string(reader)
17251
+ object.numa_tune_mode = Reader.read_enum(NumaTuneMode, reader)
17252
17252
  when 'origin'
17253
17253
  object.origin = Reader.read_string(reader)
17254
17254
  when 'os'
@@ -17276,7 +17276,7 @@ module OvirtSDK4
17276
17276
  when 'stateless'
17277
17277
  object.stateless = Reader.read_boolean(reader)
17278
17278
  when 'status'
17279
- object.status = Reader.read_string(reader)
17279
+ object.status = Reader.read_enum(Status, reader)
17280
17280
  when 'status_detail'
17281
17281
  object.status_detail = Reader.read_string(reader)
17282
17282
  when 'stop_reason'
@@ -17288,7 +17288,7 @@ module OvirtSDK4
17288
17288
  when 'tunnel_migration'
17289
17289
  object.tunnel_migration = Reader.read_boolean(reader)
17290
17290
  when 'type'
17291
- object.type = Reader.read_string(reader)
17291
+ object.type = Reader.read_enum(Type, reader)
17292
17292
  when 'usb'
17293
17293
  object.usb = UsbReader.read_one(reader)
17294
17294
  when 'use_latest_template_version'
@@ -17565,7 +17565,7 @@ module OvirtSDK4
17565
17565
  when 'tunnel_migration'
17566
17566
  object.tunnel_migration = Reader.read_boolean(reader)
17567
17567
  when 'type'
17568
- object.type = Reader.read_string(reader)
17568
+ object.type = Reader.read_enum(Type, reader)
17569
17569
  when 'usb'
17570
17570
  object.usb = UsbReader.read_one(reader)
17571
17571
  when 'virtio_scsi'
@@ -17639,7 +17639,7 @@ module OvirtSDK4
17639
17639
  while reader.forward do
17640
17640
  case reader.node_name
17641
17641
  when 'affinity'
17642
- object.affinity = Reader.read_string(reader)
17642
+ object.affinity = Reader.read_enum(Affinity, reader)
17643
17643
  when 'hosts'
17644
17644
  object.hosts = HostReader.read_many(reader)
17645
17645
  when 'link'
@@ -17710,6 +17710,8 @@ module OvirtSDK4
17710
17710
 
17711
17711
  # Process the attributes:
17712
17712
  object.href = reader.get_attribute('href')
17713
+ value = reader.get_attribute('auto_storage_select')
17714
+ object.auto_storage_select = value if not value.nil?
17713
17715
  value = reader.get_attribute('comment')
17714
17716
  object.comment = value if not value.nil?
17715
17717
  value = reader.get_attribute('description')
@@ -17741,6 +17743,8 @@ module OvirtSDK4
17741
17743
  # Process the inner elements:
17742
17744
  while reader.forward do
17743
17745
  case reader.node_name
17746
+ when 'auto_storage_select'
17747
+ object.auto_storage_select = Reader.read_boolean(reader)
17744
17748
  when 'comment'
17745
17749
  object.comment = Reader.read_string(reader)
17746
17750
  when 'description'
@@ -17764,7 +17768,7 @@ module OvirtSDK4
17764
17768
  when 'stateful'
17765
17769
  object.stateful = Reader.read_boolean(reader)
17766
17770
  when 'type'
17767
- object.type = Reader.read_string(reader)
17771
+ object.type = Reader.read_enum(Type, reader)
17768
17772
  when 'use_latest_template_version'
17769
17773
  object.use_latest_template_version = Reader.read_boolean(reader)
17770
17774
  when 'cluster'
@@ -17927,7 +17931,7 @@ module OvirtSDK4
17927
17931
  while reader.forward do
17928
17932
  case reader.node_name
17929
17933
  when 'mode'
17930
- object.mode = Reader.read_string(reader)
17934
+ object.mode = Reader.read_enum(Mode, reader)
17931
17935
  else
17932
17936
  reader.next_element
17933
17937
  end
@@ -18248,7 +18252,7 @@ module OvirtSDK4
18248
18252
  while reader.forward do
18249
18253
  case reader.node_name
18250
18254
  when 'action'
18251
- object.action = Reader.read_string(reader)
18255
+ object.action = Reader.read_enum(Action, reader)
18252
18256
  when 'comment'
18253
18257
  object.comment = Reader.read_string(reader)
18254
18258
  when 'description'
@@ -18256,7 +18260,7 @@ module OvirtSDK4
18256
18260
  when 'id'
18257
18261
  object.id = Reader.read_string(reader)
18258
18262
  when 'model'
18259
- object.model = Reader.read_string(reader)
18263
+ object.model = Reader.read_enum(Model, reader)
18260
18264
  when 'name'
18261
18265
  object.name = Reader.read_string(reader)
18262
18266
  when 'instance_type'