azure_mgmt_compute 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +10 -0
- data/.rspec +3 -0
- data/.travis.yml +3 -0
- data/Gemfile +17 -0
- data/LICENSE.txt +21 -0
- data/README.md +139 -0
- data/Rakefile +5 -0
- data/azure_mgmt_compute.gemspec +39 -0
- data/lib/azure_mgmt_compute.rb +103 -0
- data/lib/azure_mgmt_compute/Models/additional_unattend_content.rb +108 -0
- data/lib/azure_mgmt_compute/Models/api_error.rb +121 -0
- data/lib/azure_mgmt_compute/Models/api_error_base.rb +76 -0
- data/lib/azure_mgmt_compute/Models/availability_set.rb +94 -0
- data/lib/azure_mgmt_compute/Models/availability_set_list_result.rb +79 -0
- data/lib/azure_mgmt_compute/Models/availability_set_properties.rb +130 -0
- data/lib/azure_mgmt_compute/Models/caching_types.rb +17 -0
- data/lib/azure_mgmt_compute/Models/component_names.rb +15 -0
- data/lib/azure_mgmt_compute/Models/compute_long_running_operation_properties.rb +58 -0
- data/lib/azure_mgmt_compute/Models/compute_long_running_operation_result.rb +126 -0
- data/lib/azure_mgmt_compute/Models/compute_operation_status.rb +18 -0
- data/lib/azure_mgmt_compute/Models/data_disk.rb +142 -0
- data/lib/azure_mgmt_compute/Models/data_disk_image.rb +62 -0
- data/lib/azure_mgmt_compute/Models/delete_operation_result.rb +109 -0
- data/lib/azure_mgmt_compute/Models/disk_create_option_types.rb +17 -0
- data/lib/azure_mgmt_compute/Models/disk_instance_view.rb +88 -0
- data/lib/azure_mgmt_compute/Models/hardware_profile.rb +67 -0
- data/lib/azure_mgmt_compute/Models/image_reference.rb +87 -0
- data/lib/azure_mgmt_compute/Models/inner_error.rb +68 -0
- data/lib/azure_mgmt_compute/Models/instance_view_status.rb +102 -0
- data/lib/azure_mgmt_compute/Models/linux_configuration.rb +75 -0
- data/lib/azure_mgmt_compute/Models/list_usages_result.rb +78 -0
- data/lib/azure_mgmt_compute/Models/network_interface_reference.rb +70 -0
- data/lib/azure_mgmt_compute/Models/network_interface_reference_properties.rb +59 -0
- data/lib/azure_mgmt_compute/Models/network_profile.rb +79 -0
- data/lib/azure_mgmt_compute/Models/operating_system_types.rb +16 -0
- data/lib/azure_mgmt_compute/Models/operation_status.rb +17 -0
- data/lib/azure_mgmt_compute/Models/osdisk.rb +135 -0
- data/lib/azure_mgmt_compute/Models/osdisk_image.rb +63 -0
- data/lib/azure_mgmt_compute/Models/osprofile.rb +149 -0
- data/lib/azure_mgmt_compute/Models/pass_names.rb +15 -0
- data/lib/azure_mgmt_compute/Models/plan.rb +85 -0
- data/lib/azure_mgmt_compute/Models/protocol_types.rb +16 -0
- data/lib/azure_mgmt_compute/Models/purchase_plan.rb +77 -0
- data/lib/azure_mgmt_compute/Models/setting_names.rb +16 -0
- data/lib/azure_mgmt_compute/Models/ssh_configuration.rb +79 -0
- data/lib/azure_mgmt_compute/Models/ssh_public_key.rb +72 -0
- data/lib/azure_mgmt_compute/Models/status_level_types.rb +17 -0
- data/lib/azure_mgmt_compute/Models/storage_profile.rb +110 -0
- data/lib/azure_mgmt_compute/Models/usage.rb +98 -0
- data/lib/azure_mgmt_compute/Models/usage_name.rb +68 -0
- data/lib/azure_mgmt_compute/Models/usage_unit.rb +15 -0
- data/lib/azure_mgmt_compute/Models/vault_certificate.rb +70 -0
- data/lib/azure_mgmt_compute/Models/vault_secret_group.rb +96 -0
- data/lib/azure_mgmt_compute/Models/virtual_hard_disk.rb +59 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine.rb +142 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_agent_instance_view.rb +119 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_capture_parameters.rb +78 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_extension.rb +94 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_extension_handler_instance_view.rb +85 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_extension_image.rb +99 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_extension_image_properties.rb +102 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_extension_instance_view.rb +139 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_extension_properties.rb +133 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_image.rb +99 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_image_properties.rb +110 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_image_resource.rb +83 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_instance_view.rb +188 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_list_result.rb +89 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_properties.rb +156 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_size.rb +111 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_size_list_result.rb +79 -0
- data/lib/azure_mgmt_compute/Models/virtual_machine_size_types.rb +34 -0
- data/lib/azure_mgmt_compute/Models/win_rmconfiguration.rb +79 -0
- data/lib/azure_mgmt_compute/Models/win_rmlistener.rb +73 -0
- data/lib/azure_mgmt_compute/Models/windows_configuration.rb +126 -0
- data/lib/azure_mgmt_compute/availability_sets.rb +473 -0
- data/lib/azure_mgmt_compute/compute_management_client.rb +85 -0
- data/lib/azure_mgmt_compute/module_definition.rb +6 -0
- data/lib/azure_mgmt_compute/usage_operations.rb +113 -0
- data/lib/azure_mgmt_compute/version.rb +6 -0
- data/lib/azure_mgmt_compute/virtual_machine_extension_images.rb +325 -0
- data/lib/azure_mgmt_compute/virtual_machine_extensions.rb +384 -0
- data/lib/azure_mgmt_compute/virtual_machine_images.rb +525 -0
- data/lib/azure_mgmt_compute/virtual_machine_sizes.rb +114 -0
- data/lib/azure_mgmt_compute/virtual_machines.rb +1412 -0
- metadata +303 -0
@@ -0,0 +1,121 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator 0.11.0.0
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::ARM::Compute
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Api error.
|
10
|
+
#
|
11
|
+
class ApiError
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [Array<ApiErrorBase>] Gets or sets the Api error details
|
16
|
+
attr_accessor :details
|
17
|
+
|
18
|
+
# @return [InnerError] Gets or sets the Api inner error
|
19
|
+
attr_accessor :innererror
|
20
|
+
|
21
|
+
# @return [String] Gets or sets the error code.
|
22
|
+
attr_accessor :code
|
23
|
+
|
24
|
+
# @return [String] Gets or sets the target of the particular error.
|
25
|
+
attr_accessor :target
|
26
|
+
|
27
|
+
# @return [String] Gets or sets the error message.
|
28
|
+
attr_accessor :message
|
29
|
+
|
30
|
+
#
|
31
|
+
# Validate the object. Throws ValidationError if validation fails.
|
32
|
+
#
|
33
|
+
def validate
|
34
|
+
@details.each{ |e| e.validate if e.respond_to?(:validate) } unless @details.nil?
|
35
|
+
@innererror.validate unless @innererror.nil?
|
36
|
+
end
|
37
|
+
|
38
|
+
#
|
39
|
+
# Serializes given Model object into Ruby Hash.
|
40
|
+
# @param object Model object to serialize.
|
41
|
+
# @return [Hash] Serialized object in form of Ruby Hash.
|
42
|
+
#
|
43
|
+
def self.serialize_object(object)
|
44
|
+
object.validate
|
45
|
+
output_object = {}
|
46
|
+
|
47
|
+
serialized_property = object.details
|
48
|
+
unless serialized_property.nil?
|
49
|
+
serializedArray = []
|
50
|
+
serialized_property.each do |element|
|
51
|
+
unless element.nil?
|
52
|
+
element = ApiErrorBase.serialize_object(element)
|
53
|
+
end
|
54
|
+
serializedArray.push(element)
|
55
|
+
end
|
56
|
+
serialized_property = serializedArray
|
57
|
+
end
|
58
|
+
output_object['details'] = serialized_property unless serialized_property.nil?
|
59
|
+
|
60
|
+
serialized_property = object.innererror
|
61
|
+
unless serialized_property.nil?
|
62
|
+
serialized_property = InnerError.serialize_object(serialized_property)
|
63
|
+
end
|
64
|
+
output_object['innererror'] = serialized_property unless serialized_property.nil?
|
65
|
+
|
66
|
+
serialized_property = object.code
|
67
|
+
output_object['code'] = serialized_property unless serialized_property.nil?
|
68
|
+
|
69
|
+
serialized_property = object.target
|
70
|
+
output_object['target'] = serialized_property unless serialized_property.nil?
|
71
|
+
|
72
|
+
serialized_property = object.message
|
73
|
+
output_object['message'] = serialized_property unless serialized_property.nil?
|
74
|
+
|
75
|
+
output_object
|
76
|
+
end
|
77
|
+
|
78
|
+
#
|
79
|
+
# Deserializes given Ruby Hash into Model object.
|
80
|
+
# @param object [Hash] Ruby Hash object to deserialize.
|
81
|
+
# @return [ApiError] Deserialized object.
|
82
|
+
#
|
83
|
+
def self.deserialize_object(object)
|
84
|
+
return if object.nil?
|
85
|
+
output_object = ApiError.new
|
86
|
+
|
87
|
+
deserialized_property = object['details']
|
88
|
+
unless deserialized_property.nil?
|
89
|
+
deserializedArray = [];
|
90
|
+
deserialized_property.each do |element1|
|
91
|
+
unless element1.nil?
|
92
|
+
element1 = ApiErrorBase.deserialize_object(element1)
|
93
|
+
end
|
94
|
+
deserializedArray.push(element1);
|
95
|
+
end
|
96
|
+
deserialized_property = deserializedArray;
|
97
|
+
end
|
98
|
+
output_object.details = deserialized_property
|
99
|
+
|
100
|
+
deserialized_property = object['innererror']
|
101
|
+
unless deserialized_property.nil?
|
102
|
+
deserialized_property = InnerError.deserialize_object(deserialized_property)
|
103
|
+
end
|
104
|
+
output_object.innererror = deserialized_property
|
105
|
+
|
106
|
+
deserialized_property = object['code']
|
107
|
+
output_object.code = deserialized_property
|
108
|
+
|
109
|
+
deserialized_property = object['target']
|
110
|
+
output_object.target = deserialized_property
|
111
|
+
|
112
|
+
deserialized_property = object['message']
|
113
|
+
output_object.message = deserialized_property
|
114
|
+
|
115
|
+
output_object.validate
|
116
|
+
|
117
|
+
output_object
|
118
|
+
end
|
119
|
+
end
|
120
|
+
end
|
121
|
+
end
|
@@ -0,0 +1,76 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator 0.11.0.0
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::ARM::Compute
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Api error base.
|
10
|
+
#
|
11
|
+
class ApiErrorBase
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [String] Gets or sets the error code.
|
16
|
+
attr_accessor :code
|
17
|
+
|
18
|
+
# @return [String] Gets or sets the target of the particular error.
|
19
|
+
attr_accessor :target
|
20
|
+
|
21
|
+
# @return [String] Gets or sets the error message.
|
22
|
+
attr_accessor :message
|
23
|
+
|
24
|
+
#
|
25
|
+
# Validate the object. Throws ValidationError if validation fails.
|
26
|
+
#
|
27
|
+
def validate
|
28
|
+
# Nothing to validate
|
29
|
+
end
|
30
|
+
|
31
|
+
#
|
32
|
+
# Serializes given Model object into Ruby Hash.
|
33
|
+
# @param object Model object to serialize.
|
34
|
+
# @return [Hash] Serialized object in form of Ruby Hash.
|
35
|
+
#
|
36
|
+
def self.serialize_object(object)
|
37
|
+
object.validate
|
38
|
+
output_object = {}
|
39
|
+
|
40
|
+
serialized_property = object.code
|
41
|
+
output_object['code'] = serialized_property unless serialized_property.nil?
|
42
|
+
|
43
|
+
serialized_property = object.target
|
44
|
+
output_object['target'] = serialized_property unless serialized_property.nil?
|
45
|
+
|
46
|
+
serialized_property = object.message
|
47
|
+
output_object['message'] = serialized_property unless serialized_property.nil?
|
48
|
+
|
49
|
+
output_object
|
50
|
+
end
|
51
|
+
|
52
|
+
#
|
53
|
+
# Deserializes given Ruby Hash into Model object.
|
54
|
+
# @param object [Hash] Ruby Hash object to deserialize.
|
55
|
+
# @return [ApiErrorBase] Deserialized object.
|
56
|
+
#
|
57
|
+
def self.deserialize_object(object)
|
58
|
+
return if object.nil?
|
59
|
+
output_object = ApiErrorBase.new
|
60
|
+
|
61
|
+
deserialized_property = object['code']
|
62
|
+
output_object.code = deserialized_property
|
63
|
+
|
64
|
+
deserialized_property = object['target']
|
65
|
+
output_object.target = deserialized_property
|
66
|
+
|
67
|
+
deserialized_property = object['message']
|
68
|
+
output_object.message = deserialized_property
|
69
|
+
|
70
|
+
output_object.validate
|
71
|
+
|
72
|
+
output_object
|
73
|
+
end
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
@@ -0,0 +1,94 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator 0.11.0.0
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::ARM::Compute
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Create or update Availability Set parameters.
|
10
|
+
#
|
11
|
+
class AvailabilitySet < MsRestAzure::Resource
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [AvailabilitySetProperties]
|
16
|
+
attr_accessor :properties
|
17
|
+
|
18
|
+
#
|
19
|
+
# Validate the object. Throws ValidationError if validation fails.
|
20
|
+
#
|
21
|
+
def validate
|
22
|
+
@properties.validate unless @properties.nil?
|
23
|
+
end
|
24
|
+
|
25
|
+
#
|
26
|
+
# Serializes given Model object into Ruby Hash.
|
27
|
+
# @param object Model object to serialize.
|
28
|
+
# @return [Hash] Serialized object in form of Ruby Hash.
|
29
|
+
#
|
30
|
+
def self.serialize_object(object)
|
31
|
+
object.validate
|
32
|
+
output_object = {}
|
33
|
+
|
34
|
+
serialized_property = object.location
|
35
|
+
output_object['location'] = serialized_property unless serialized_property.nil?
|
36
|
+
|
37
|
+
serialized_property = object.id
|
38
|
+
output_object['id'] = serialized_property unless serialized_property.nil?
|
39
|
+
|
40
|
+
serialized_property = object.name
|
41
|
+
output_object['name'] = serialized_property unless serialized_property.nil?
|
42
|
+
|
43
|
+
serialized_property = object.type
|
44
|
+
output_object['type'] = serialized_property unless serialized_property.nil?
|
45
|
+
|
46
|
+
serialized_property = object.tags
|
47
|
+
output_object['tags'] = serialized_property unless serialized_property.nil?
|
48
|
+
|
49
|
+
serialized_property = object.properties
|
50
|
+
unless serialized_property.nil?
|
51
|
+
serialized_property = AvailabilitySetProperties.serialize_object(serialized_property)
|
52
|
+
end
|
53
|
+
output_object['properties'] = serialized_property unless serialized_property.nil?
|
54
|
+
|
55
|
+
output_object
|
56
|
+
end
|
57
|
+
|
58
|
+
#
|
59
|
+
# Deserializes given Ruby Hash into Model object.
|
60
|
+
# @param object [Hash] Ruby Hash object to deserialize.
|
61
|
+
# @return [AvailabilitySet] Deserialized object.
|
62
|
+
#
|
63
|
+
def self.deserialize_object(object)
|
64
|
+
return if object.nil?
|
65
|
+
output_object = AvailabilitySet.new
|
66
|
+
|
67
|
+
deserialized_property = object['location']
|
68
|
+
output_object.location = deserialized_property
|
69
|
+
|
70
|
+
deserialized_property = object['id']
|
71
|
+
output_object.id = deserialized_property
|
72
|
+
|
73
|
+
deserialized_property = object['name']
|
74
|
+
output_object.name = deserialized_property
|
75
|
+
|
76
|
+
deserialized_property = object['type']
|
77
|
+
output_object.type = deserialized_property
|
78
|
+
|
79
|
+
deserialized_property = object['tags']
|
80
|
+
output_object.tags = deserialized_property
|
81
|
+
|
82
|
+
deserialized_property = object['properties']
|
83
|
+
unless deserialized_property.nil?
|
84
|
+
deserialized_property = AvailabilitySetProperties.deserialize_object(deserialized_property)
|
85
|
+
end
|
86
|
+
output_object.properties = deserialized_property
|
87
|
+
|
88
|
+
output_object.validate
|
89
|
+
|
90
|
+
output_object
|
91
|
+
end
|
92
|
+
end
|
93
|
+
end
|
94
|
+
end
|
@@ -0,0 +1,79 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator 0.11.0.0
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::ARM::Compute
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# The List Availability Set operation response.
|
10
|
+
#
|
11
|
+
class AvailabilitySetListResult
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [Array<AvailabilitySet>] Gets or sets the list of availability
|
16
|
+
# sets
|
17
|
+
attr_accessor :value
|
18
|
+
|
19
|
+
#
|
20
|
+
# Validate the object. Throws ValidationError if validation fails.
|
21
|
+
#
|
22
|
+
def validate
|
23
|
+
@value.each{ |e| e.validate if e.respond_to?(:validate) } unless @value.nil?
|
24
|
+
end
|
25
|
+
|
26
|
+
#
|
27
|
+
# Serializes given Model object into Ruby Hash.
|
28
|
+
# @param object Model object to serialize.
|
29
|
+
# @return [Hash] Serialized object in form of Ruby Hash.
|
30
|
+
#
|
31
|
+
def self.serialize_object(object)
|
32
|
+
object.validate
|
33
|
+
output_object = {}
|
34
|
+
|
35
|
+
serialized_property = object.value
|
36
|
+
unless serialized_property.nil?
|
37
|
+
serializedArray = []
|
38
|
+
serialized_property.each do |element|
|
39
|
+
unless element.nil?
|
40
|
+
element = AvailabilitySet.serialize_object(element)
|
41
|
+
end
|
42
|
+
serializedArray.push(element)
|
43
|
+
end
|
44
|
+
serialized_property = serializedArray
|
45
|
+
end
|
46
|
+
output_object['value'] = serialized_property unless serialized_property.nil?
|
47
|
+
|
48
|
+
output_object
|
49
|
+
end
|
50
|
+
|
51
|
+
#
|
52
|
+
# Deserializes given Ruby Hash into Model object.
|
53
|
+
# @param object [Hash] Ruby Hash object to deserialize.
|
54
|
+
# @return [AvailabilitySetListResult] Deserialized object.
|
55
|
+
#
|
56
|
+
def self.deserialize_object(object)
|
57
|
+
return if object.nil?
|
58
|
+
output_object = AvailabilitySetListResult.new
|
59
|
+
|
60
|
+
deserialized_property = object['value']
|
61
|
+
unless deserialized_property.nil?
|
62
|
+
deserializedArray = [];
|
63
|
+
deserialized_property.each do |element1|
|
64
|
+
unless element1.nil?
|
65
|
+
element1 = AvailabilitySet.deserialize_object(element1)
|
66
|
+
end
|
67
|
+
deserializedArray.push(element1);
|
68
|
+
end
|
69
|
+
deserialized_property = deserializedArray;
|
70
|
+
end
|
71
|
+
output_object.value = deserialized_property
|
72
|
+
|
73
|
+
output_object.validate
|
74
|
+
|
75
|
+
output_object
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
79
|
+
end
|
@@ -0,0 +1,130 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator 0.11.0.0
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::ARM::Compute
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# The instance view of a resource.
|
10
|
+
#
|
11
|
+
class AvailabilitySetProperties
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [Integer] Gets or sets Update Domain count.
|
16
|
+
attr_accessor :platform_update_domain_count
|
17
|
+
|
18
|
+
# @return [Integer] Gets or sets Fault Domain count.
|
19
|
+
attr_accessor :platform_fault_domain_count
|
20
|
+
|
21
|
+
# @return [Array<SubResource>] Gets or sets a list containing reference
|
22
|
+
# to all Virtual Machines created under this Availability Set.
|
23
|
+
attr_accessor :virtual_machines
|
24
|
+
|
25
|
+
# @return [Array<InstanceViewStatus>] Gets or sets the resource status
|
26
|
+
# information.
|
27
|
+
attr_accessor :statuses
|
28
|
+
|
29
|
+
#
|
30
|
+
# Validate the object. Throws ValidationError if validation fails.
|
31
|
+
#
|
32
|
+
def validate
|
33
|
+
@virtual_machines.each{ |e| e.validate if e.respond_to?(:validate) } unless @virtual_machines.nil?
|
34
|
+
@statuses.each{ |e| e.validate if e.respond_to?(:validate) } unless @statuses.nil?
|
35
|
+
end
|
36
|
+
|
37
|
+
#
|
38
|
+
# Serializes given Model object into Ruby Hash.
|
39
|
+
# @param object Model object to serialize.
|
40
|
+
# @return [Hash] Serialized object in form of Ruby Hash.
|
41
|
+
#
|
42
|
+
def self.serialize_object(object)
|
43
|
+
object.validate
|
44
|
+
output_object = {}
|
45
|
+
|
46
|
+
serialized_property = object.platform_update_domain_count
|
47
|
+
output_object['platformUpdateDomainCount'] = serialized_property unless serialized_property.nil?
|
48
|
+
|
49
|
+
serialized_property = object.platform_fault_domain_count
|
50
|
+
output_object['platformFaultDomainCount'] = serialized_property unless serialized_property.nil?
|
51
|
+
|
52
|
+
serialized_property = object.virtual_machines
|
53
|
+
unless serialized_property.nil?
|
54
|
+
serializedArray = []
|
55
|
+
serialized_property.each do |element|
|
56
|
+
unless element.nil?
|
57
|
+
element = SubResource.serialize_object(element)
|
58
|
+
end
|
59
|
+
serializedArray.push(element)
|
60
|
+
end
|
61
|
+
serialized_property = serializedArray
|
62
|
+
end
|
63
|
+
output_object['virtualMachines'] = serialized_property unless serialized_property.nil?
|
64
|
+
|
65
|
+
serialized_property = object.statuses
|
66
|
+
unless serialized_property.nil?
|
67
|
+
serializedArray = []
|
68
|
+
serialized_property.each do |element1|
|
69
|
+
unless element1.nil?
|
70
|
+
element1 = InstanceViewStatus.serialize_object(element1)
|
71
|
+
end
|
72
|
+
serializedArray.push(element1)
|
73
|
+
end
|
74
|
+
serialized_property = serializedArray
|
75
|
+
end
|
76
|
+
output_object['statuses'] = serialized_property unless serialized_property.nil?
|
77
|
+
|
78
|
+
output_object
|
79
|
+
end
|
80
|
+
|
81
|
+
#
|
82
|
+
# Deserializes given Ruby Hash into Model object.
|
83
|
+
# @param object [Hash] Ruby Hash object to deserialize.
|
84
|
+
# @return [AvailabilitySetProperties] Deserialized object.
|
85
|
+
#
|
86
|
+
def self.deserialize_object(object)
|
87
|
+
return if object.nil?
|
88
|
+
output_object = AvailabilitySetProperties.new
|
89
|
+
|
90
|
+
deserialized_property = object['platformUpdateDomainCount']
|
91
|
+
deserialized_property = Integer(deserialized_property) unless deserialized_property.to_s.empty?
|
92
|
+
output_object.platform_update_domain_count = deserialized_property
|
93
|
+
|
94
|
+
deserialized_property = object['platformFaultDomainCount']
|
95
|
+
deserialized_property = Integer(deserialized_property) unless deserialized_property.to_s.empty?
|
96
|
+
output_object.platform_fault_domain_count = deserialized_property
|
97
|
+
|
98
|
+
deserialized_property = object['virtualMachines']
|
99
|
+
unless deserialized_property.nil?
|
100
|
+
deserializedArray = [];
|
101
|
+
deserialized_property.each do |element2|
|
102
|
+
unless element2.nil?
|
103
|
+
element2 = SubResource.deserialize_object(element2)
|
104
|
+
end
|
105
|
+
deserializedArray.push(element2);
|
106
|
+
end
|
107
|
+
deserialized_property = deserializedArray;
|
108
|
+
end
|
109
|
+
output_object.virtual_machines = deserialized_property
|
110
|
+
|
111
|
+
deserialized_property = object['statuses']
|
112
|
+
unless deserialized_property.nil?
|
113
|
+
deserializedArray = [];
|
114
|
+
deserialized_property.each do |element3|
|
115
|
+
unless element3.nil?
|
116
|
+
element3 = InstanceViewStatus.deserialize_object(element3)
|
117
|
+
end
|
118
|
+
deserializedArray.push(element3);
|
119
|
+
end
|
120
|
+
deserialized_property = deserializedArray;
|
121
|
+
end
|
122
|
+
output_object.statuses = deserialized_property
|
123
|
+
|
124
|
+
output_object.validate
|
125
|
+
|
126
|
+
output_object
|
127
|
+
end
|
128
|
+
end
|
129
|
+
end
|
130
|
+
end
|