Class: Azure::ARM::Web::Models::NetworkAccessControlEntry
- Inherits:
-
Object
- Object
- Azure::ARM::Web::Models::NetworkAccessControlEntry
- Includes:
- MsRestAzure
- Defined in:
- lib/azure_mgmt_web/models/network_access_control_entry.rb
Overview
Model object.
Instance Attribute Summary collapse
-
#action ⇒ AccessControlEntryAction
‘Deny’.
- #description ⇒ String
- #order ⇒ Integer
- #remote_subnet ⇒ String
Class Method Summary collapse
-
.deserialize_object(object) ⇒ NetworkAccessControlEntry
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
#action ⇒ AccessControlEntryAction
‘Deny’
17 18 19 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 17 def action @action end |
#description ⇒ String
20 21 22 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 20 def description @description end |
#order ⇒ Integer
23 24 25 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 23 def order @order end |
#remote_subnet ⇒ String
26 27 28 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 26 def remote_subnet @remote_subnet end |
Class Method Details
.deserialize_object(object) ⇒ NetworkAccessControlEntry
Deserializes given Ruby Hash into Model object.
63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 63 def self.deserialize_object(object) return if object.nil? output_object = NetworkAccessControlEntry.new deserialized_property = object['action'] if (!deserialized_property.nil? && !deserialized_property.empty?) enum_is_valid = AccessControlEntryAction.constants.any? { |e| AccessControlEntryAction.const_get(e).to_s.downcase == deserialized_property.downcase } warn 'Enum AccessControlEntryAction does not contain ' + deserialized_property.downcase + ', but was received from the server.' unless enum_is_valid end output_object.action = deserialized_property deserialized_property = object['description'] output_object.description = deserialized_property deserialized_property = object['order'] deserialized_property = Integer(deserialized_property) unless deserialized_property.to_s.empty? output_object.order = deserialized_property deserialized_property = object['remoteSubnet'] output_object.remote_subnet = deserialized_property output_object end |
.serialize_object(object) ⇒ Hash
Serializes given Model object into Ruby Hash.
39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 39 def self.serialize_object(object) object.validate output_object = {} serialized_property = object.action output_object['action'] = serialized_property unless serialized_property.nil? serialized_property = object.description output_object['description'] = serialized_property unless serialized_property.nil? serialized_property = object.order output_object['order'] = serialized_property unless serialized_property.nil? serialized_property = object.remote_subnet output_object['remoteSubnet'] = serialized_property unless serialized_property.nil? output_object end |
Instance Method Details
#validate ⇒ Object
Validate the object. Throws ValidationError if validation fails.
31 32 |
# File 'lib/azure_mgmt_web/models/network_access_control_entry.rb', line 31 def validate end |