Class: Azure::ARM::Compute::Models::WindowsConfiguration
- Inherits:
-
Object
- Object
- Azure::ARM::Compute::Models::WindowsConfiguration
- Includes:
- MsRestAzure
- Defined in:
- lib/azure_mgmt_compute/models/windows_configuration.rb
Overview
Describes Windows Configuration of the OS Profile.
Instance Attribute Summary collapse
-
#additional_unattend_content ⇒ Array<AdditionalUnattendContent>
base-64 encoded XML formatted information that can be included in the Unattend.xml file.
-
#enable_automatic_updates ⇒ Boolean
automatically installed on the VM.
-
#provision_vmagent ⇒ Boolean
on the Virtual Machine.
-
#time_zone ⇒ String
Gets or sets the Time Zone of the VM.
-
#win_rm ⇒ WinRMConfiguration
Management configuration of the VM.
Class Method Summary collapse
-
.deserialize_object(object) ⇒ WindowsConfiguration
Deserializes given Ruby Hash into Model object.
-
.serialize_object(object) ⇒ Hash
Serializes given Model object into Ruby Hash.
Instance Method Summary collapse
-
#validate ⇒ Object
Validate the object.
Instance Attribute Details
#additional_unattend_content ⇒ Array<AdditionalUnattendContent>
base-64 encoded XML formatted information that can be included in the Unattend.xml file.
29 30 31 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 29 def additional_unattend_content @additional_unattend_content end |
#enable_automatic_updates ⇒ Boolean
automatically installed on the VM
21 22 23 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 21 def enable_automatic_updates @enable_automatic_updates end |
#provision_vmagent ⇒ Boolean
on the Virtual Machine.
17 18 19 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 17 def provision_vmagent @provision_vmagent end |
#time_zone ⇒ String
Returns Gets or sets the Time Zone of the VM.
24 25 26 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 24 def time_zone @time_zone end |
#win_rm ⇒ WinRMConfiguration
Management configuration of the VM
33 34 35 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 33 def win_rm @win_rm end |
Class Method Details
.deserialize_object(object) ⇒ WindowsConfiguration
Deserializes given Ruby Hash into Model object.
88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 88 def self.deserialize_object(object) return if object.nil? output_object = WindowsConfiguration.new deserialized_property = object['provisionVMAgent'] output_object.provision_vmagent = deserialized_property deserialized_property = object['enableAutomaticUpdates'] output_object.enable_automatic_updates = deserialized_property deserialized_property = object['timeZone'] output_object.time_zone = deserialized_property deserialized_property = object['additionalUnattendContent'] unless deserialized_property.nil? deserializedArray = []; deserialized_property.each do |element1| unless element1.nil? element1 = AdditionalUnattendContent.deserialize_object(element1) end deserializedArray.push(element1); end deserialized_property = deserializedArray; end output_object.additional_unattend_content = deserialized_property deserialized_property = object['winRM'] unless deserialized_property.nil? deserialized_property = WinRMConfiguration.deserialize_object(deserialized_property) end output_object.win_rm = deserialized_property output_object.validate output_object end |
.serialize_object(object) ⇒ Hash
Serializes given Model object into Ruby Hash.
48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 48 def self.serialize_object(object) object.validate output_object = {} serialized_property = object.provision_vmagent output_object['provisionVMAgent'] = serialized_property unless serialized_property.nil? serialized_property = object.enable_automatic_updates output_object['enableAutomaticUpdates'] = serialized_property unless serialized_property.nil? serialized_property = object.time_zone output_object['timeZone'] = serialized_property unless serialized_property.nil? serialized_property = object.additional_unattend_content unless serialized_property.nil? serializedArray = [] serialized_property.each do |element| unless element.nil? element = AdditionalUnattendContent.serialize_object(element) end serializedArray.push(element) end serialized_property = serializedArray end output_object['additionalUnattendContent'] = serialized_property unless serialized_property.nil? serialized_property = object.win_rm unless serialized_property.nil? serialized_property = WinRMConfiguration.serialize_object(serialized_property) end output_object['winRM'] = serialized_property unless serialized_property.nil? output_object end |
Instance Method Details
#validate ⇒ Object
Validate the object. Throws ValidationError if validation fails.
38 39 40 41 |
# File 'lib/azure_mgmt_compute/models/windows_configuration.rb', line 38 def validate @additional_unattend_content.each{ |e| e.validate if e.respond_to?(:validate) } unless @additional_unattend_content.nil? @win_rm.validate unless @win_rm.nil? end |