Class: Azure::ARM::Network::Models::FrontendIpConfigurationPropertiesFormat

Inherits:
Object
  • Object
show all
Includes:
MsRestAzure
Defined in:
lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb

Overview

Properties of Frontend IP Configuration of the load balancer

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#inbound_nat_rulesArray<SubResource>

this frontend IP

Returns:

  • (Array<SubResource>)

    Read only.Inbound rules URIs that use



36
37
38
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 36

def inbound_nat_rules
  @inbound_nat_rules
end

#load_balancing_rulesArray<SubResource>

this frontend IP

Returns:

  • (Array<SubResource>)

    Gets Load Balancing rules URIs that use



40
41
42
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 40

def load_balancing_rules
  @load_balancing_rules
end

#private_ipaddressString

is only specified if a specific private IP address shall be allocated from the subnet specified in subnetRef

Returns:

  • (String)

    Gets or sets the IP address of the Load Balancer.This



18
19
20
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 18

def private_ipaddress
  @private_ipaddress
end

#private_ipallocation_methodIpAllocationMethod

(Static/Dynamic). Possible values for this property include: ‘Static’, ‘Dynamic’.

Returns:



23
24
25
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 23

def private_ipallocation_method
  @private_ipallocation_method
end

#provisioning_stateString

resource Updating/Deleting/Failed

Returns:

  • (String)

    Gets or sets Provisioning state of the PublicIP



44
45
46
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 44

def provisioning_state
  @provisioning_state
end

#public_ipaddressSubResource

resource

Returns:

  • (SubResource)

    Gets or sets the reference of the PublicIP



32
33
34
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 32

def public_ipaddress
  @public_ipaddress
end

#subnetSubResource

resource.A subnet from wher the load balancer gets its private frontend address

Returns:

  • (SubResource)

    Gets or sets the reference of the subnet



28
29
30
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 28

def subnet
  @subnet
end

Class Method Details

.deserialize_object(object) ⇒ FrontendIpConfigurationPropertiesFormat

Deserializes given Ruby Hash into Model object.

Parameters:

  • object (Hash)

    Ruby Hash object to deserialize.

Returns:



120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 120

def self.deserialize_object(object)
  return if object.nil?
  output_object = FrontendIpConfigurationPropertiesFormat.new

  deserialized_property = object['privateIPAddress']
  output_object.private_ipaddress = deserialized_property

  deserialized_property = object['privateIPAllocationMethod']
  if (!deserialized_property.nil? && !deserialized_property.empty?)
    enum_is_valid = IpAllocationMethod.constants.any? { |e| IpAllocationMethod.const_get(e).to_s.downcase == deserialized_property.downcase }
    fail MsRest::DeserializationError.new('Error occured while deserializing the enum', nil, nil, nil) unless enum_is_valid
  end
  output_object.private_ipallocation_method = deserialized_property

  deserialized_property = object['subnet']
  unless deserialized_property.nil?
    deserialized_property = SubResource.deserialize_object(deserialized_property)
  end
  output_object.subnet = deserialized_property

  deserialized_property = object['publicIPAddress']
  unless deserialized_property.nil?
    deserialized_property = SubResource.deserialize_object(deserialized_property)
  end
  output_object.public_ipaddress = deserialized_property

  deserialized_property = object['inboundNatRules']
  unless deserialized_property.nil?
    deserializedArray = [];
    deserialized_property.each do |element2|
      unless element2.nil?
        element2 = SubResource.deserialize_object(element2)
      end
      deserializedArray.push(element2);
    end
    deserialized_property = deserializedArray;
  end
  output_object.inbound_nat_rules = deserialized_property

  deserialized_property = object['loadBalancingRules']
  unless deserialized_property.nil?
    deserializedArray = [];
    deserialized_property.each do |element3|
      unless element3.nil?
        element3 = SubResource.deserialize_object(element3)
      end
      deserializedArray.push(element3);
    end
    deserialized_property = deserializedArray;
  end
  output_object.load_balancing_rules = deserialized_property

  deserialized_property = object['provisioningState']
  output_object.provisioning_state = deserialized_property

  output_object.validate

  output_object
end

.serialize_object(object) ⇒ Hash

Serializes given Model object into Ruby Hash.

Parameters:

  • object

    Model object to serialize.

Returns:

  • (Hash)

    Serialized object in form of Ruby Hash.



61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
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
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 61

def self.serialize_object(object)
  object.validate
  output_object = {}

  serialized_property = object.private_ipaddress
  output_object['privateIPAddress'] = serialized_property unless serialized_property.nil?

  serialized_property = object.private_ipallocation_method
  output_object['privateIPAllocationMethod'] = serialized_property unless serialized_property.nil?

  serialized_property = object.subnet
  unless serialized_property.nil?
    serialized_property = SubResource.serialize_object(serialized_property)
  end
  output_object['subnet'] = serialized_property unless serialized_property.nil?

  serialized_property = object.public_ipaddress
  unless serialized_property.nil?
    serialized_property = SubResource.serialize_object(serialized_property)
  end
  output_object['publicIPAddress'] = serialized_property unless serialized_property.nil?

  serialized_property = object.inbound_nat_rules
  unless serialized_property.nil?
    serializedArray = []
    serialized_property.each do |element|
      unless element.nil?
        element = SubResource.serialize_object(element)
      end
      serializedArray.push(element)
    end
    serialized_property = serializedArray
  end
  output_object['inboundNatRules'] = serialized_property unless serialized_property.nil?

  serialized_property = object.load_balancing_rules
  unless serialized_property.nil?
    serializedArray = []
    serialized_property.each do |element1|
      unless element1.nil?
        element1 = SubResource.serialize_object(element1)
      end
      serializedArray.push(element1)
    end
    serialized_property = serializedArray
  end
  output_object['loadBalancingRules'] = serialized_property unless serialized_property.nil?

  serialized_property = object.provisioning_state
  output_object['provisioningState'] = serialized_property unless serialized_property.nil?

  output_object
end

Instance Method Details

#validateObject

Validate the object. Throws ValidationError if validation fails.



49
50
51
52
53
54
# File 'lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb', line 49

def validate
  @subnet.validate unless @subnet.nil?
  @public_ipaddress.validate unless @public_ipaddress.nil?
  @inbound_nat_rules.each{ |e| e.validate if e.respond_to?(:validate) } unless @inbound_nat_rules.nil?
  @load_balancing_rules.each{ |e| e.validate if e.respond_to?(:validate) } unless @load_balancing_rules.nil?
end