azure_mgmt_network 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (123) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +10 -0
  3. data/.rspec +3 -0
  4. data/.travis.yml +3 -0
  5. data/Gemfile +15 -0
  6. data/LICENSE.txt +21 -0
  7. data/README.md +131 -0
  8. data/Rakefile +5 -0
  9. data/azure_mgmt_network.gemspec +39 -0
  10. data/lib/azure_mgmt_network.rb +139 -0
  11. data/lib/azure_mgmt_network/Models/address_space.rb +60 -0
  12. data/lib/azure_mgmt_network/Models/application_gateway.rb +104 -0
  13. data/lib/azure_mgmt_network/Models/application_gateway_backend_address.rb +67 -0
  14. data/lib/azure_mgmt_network/Models/application_gateway_backend_address_pool.rb +90 -0
  15. data/lib/azure_mgmt_network/Models/application_gateway_backend_address_pool_properties_format.rb +121 -0
  16. data/lib/azure_mgmt_network/Models/application_gateway_backend_http_settings.rb +90 -0
  17. data/lib/azure_mgmt_network/Models/application_gateway_backend_http_settings_properties_format.rb +98 -0
  18. data/lib/azure_mgmt_network/Models/application_gateway_cookie_based_affinity.rb +16 -0
  19. data/lib/azure_mgmt_network/Models/application_gateway_frontend_ip_configuration.rb +91 -0
  20. data/lib/azure_mgmt_network/Models/application_gateway_frontend_ip_configuration_properties_format.rb +117 -0
  21. data/lib/azure_mgmt_network/Models/application_gateway_frontend_port.rb +90 -0
  22. data/lib/azure_mgmt_network/Models/application_gateway_frontend_port_properties_format.rb +70 -0
  23. data/lib/azure_mgmt_network/Models/application_gateway_http_listener.rb +90 -0
  24. data/lib/azure_mgmt_network/Models/application_gateway_http_listener_properties_format.rb +124 -0
  25. data/lib/azure_mgmt_network/Models/application_gateway_ip_configuration.rb +90 -0
  26. data/lib/azure_mgmt_network/Models/application_gateway_ip_configuration_properties_format.rb +77 -0
  27. data/lib/azure_mgmt_network/Models/application_gateway_list_result.rb +88 -0
  28. data/lib/azure_mgmt_network/Models/application_gateway_operational_state.rb +18 -0
  29. data/lib/azure_mgmt_network/Models/application_gateway_properties_format.rb +338 -0
  30. data/lib/azure_mgmt_network/Models/application_gateway_protocol.rb +16 -0
  31. data/lib/azure_mgmt_network/Models/application_gateway_request_routing_rule.rb +90 -0
  32. data/lib/azure_mgmt_network/Models/application_gateway_request_routing_rule_properties_format.rb +124 -0
  33. data/lib/azure_mgmt_network/Models/application_gateway_request_routing_rule_type.rb +15 -0
  34. data/lib/azure_mgmt_network/Models/application_gateway_sku.rb +88 -0
  35. data/lib/azure_mgmt_network/Models/application_gateway_sku_name.rb +17 -0
  36. data/lib/azure_mgmt_network/Models/application_gateway_ssl_certificate.rb +90 -0
  37. data/lib/azure_mgmt_network/Models/application_gateway_ssl_certificate_properties_format.rb +87 -0
  38. data/lib/azure_mgmt_network/Models/application_gateway_tier.rb +15 -0
  39. data/lib/azure_mgmt_network/Models/azure_async_operation_result.rb +85 -0
  40. data/lib/azure_mgmt_network/Models/backend_address_pool.rb +90 -0
  41. data/lib/azure_mgmt_network/Models/backend_address_pool_properties_format.rb +120 -0
  42. data/lib/azure_mgmt_network/Models/connection_reset_shared_key.rb +64 -0
  43. data/lib/azure_mgmt_network/Models/connection_reset_shared_key_properties_format.rb +60 -0
  44. data/lib/azure_mgmt_network/Models/connection_shared_key.rb +58 -0
  45. data/lib/azure_mgmt_network/Models/dhcp_options.rb +60 -0
  46. data/lib/azure_mgmt_network/Models/dns_name_availability_result.rb +58 -0
  47. data/lib/azure_mgmt_network/Models/error.rb +114 -0
  48. data/lib/azure_mgmt_network/Models/error_details.rb +76 -0
  49. data/lib/azure_mgmt_network/Models/frontend_ip_configuration.rb +90 -0
  50. data/lib/azure_mgmt_network/Models/frontend_ip_configuration_properties_format.rb +181 -0
  51. data/lib/azure_mgmt_network/Models/inbound_nat_rule.rb +90 -0
  52. data/lib/azure_mgmt_network/Models/inbound_nat_rule_properties_format.rb +163 -0
  53. data/lib/azure_mgmt_network/Models/ip_allocation_method.rb +16 -0
  54. data/lib/azure_mgmt_network/Models/load_balancer.rb +104 -0
  55. data/lib/azure_mgmt_network/Models/load_balancer_list_result.rb +88 -0
  56. data/lib/azure_mgmt_network/Models/load_balancer_properties_format.rb +210 -0
  57. data/lib/azure_mgmt_network/Models/load_balancing_rule.rb +90 -0
  58. data/lib/azure_mgmt_network/Models/load_balancing_rule_properties_format.rb +195 -0
  59. data/lib/azure_mgmt_network/Models/load_distribution.rb +17 -0
  60. data/lib/azure_mgmt_network/Models/local_network_gateway.rb +104 -0
  61. data/lib/azure_mgmt_network/Models/local_network_gateway_list_result.rb +88 -0
  62. data/lib/azure_mgmt_network/Models/local_network_gateway_properties_format.rb +83 -0
  63. data/lib/azure_mgmt_network/Models/network_interface.rb +104 -0
  64. data/lib/azure_mgmt_network/Models/network_interface_dns_settings.rb +89 -0
  65. data/lib/azure_mgmt_network/Models/network_interface_ip_configuration.rb +90 -0
  66. data/lib/azure_mgmt_network/Models/network_interface_ip_configuration_properties_format.rb +179 -0
  67. data/lib/azure_mgmt_network/Models/network_interface_list_result.rb +88 -0
  68. data/lib/azure_mgmt_network/Models/network_interface_properties_format.rb +158 -0
  69. data/lib/azure_mgmt_network/Models/network_security_group.rb +104 -0
  70. data/lib/azure_mgmt_network/Models/network_security_group_list_result.rb +88 -0
  71. data/lib/azure_mgmt_network/Models/network_security_group_properties_format.rb +181 -0
  72. data/lib/azure_mgmt_network/Models/operation_status.rb +17 -0
  73. data/lib/azure_mgmt_network/Models/probe.rb +90 -0
  74. data/lib/azure_mgmt_network/Models/probe_properties_format.rb +157 -0
  75. data/lib/azure_mgmt_network/Models/probe_protocol.rb +16 -0
  76. data/lib/azure_mgmt_network/Models/public_ip_address.rb +104 -0
  77. data/lib/azure_mgmt_network/Models/public_ip_address_dns_settings.rb +85 -0
  78. data/lib/azure_mgmt_network/Models/public_ip_address_list_result.rb +88 -0
  79. data/lib/azure_mgmt_network/Models/public_ip_address_properties_format.rb +126 -0
  80. data/lib/azure_mgmt_network/Models/security_rule.rb +90 -0
  81. data/lib/azure_mgmt_network/Models/security_rule_access.rb +16 -0
  82. data/lib/azure_mgmt_network/Models/security_rule_direction.rb +16 -0
  83. data/lib/azure_mgmt_network/Models/security_rule_list_result.rb +89 -0
  84. data/lib/azure_mgmt_network/Models/security_rule_properties_format.rb +174 -0
  85. data/lib/azure_mgmt_network/Models/security_rule_protocol.rb +17 -0
  86. data/lib/azure_mgmt_network/Models/subnet.rb +90 -0
  87. data/lib/azure_mgmt_network/Models/subnet_list_result.rb +88 -0
  88. data/lib/azure_mgmt_network/Models/subnet_properties_format.rb +115 -0
  89. data/lib/azure_mgmt_network/Models/transport_protocol.rb +16 -0
  90. data/lib/azure_mgmt_network/Models/usage.rb +98 -0
  91. data/lib/azure_mgmt_network/Models/usage_name.rb +68 -0
  92. data/lib/azure_mgmt_network/Models/usage_unit.rb +15 -0
  93. data/lib/azure_mgmt_network/Models/usages_list_result.rb +78 -0
  94. data/lib/azure_mgmt_network/Models/virtual_network.rb +104 -0
  95. data/lib/azure_mgmt_network/Models/virtual_network_gateway.rb +104 -0
  96. data/lib/azure_mgmt_network/Models/virtual_network_gateway_connection.rb +104 -0
  97. data/lib/azure_mgmt_network/Models/virtual_network_gateway_connection_list_result.rb +89 -0
  98. data/lib/azure_mgmt_network/Models/virtual_network_gateway_connection_properties_format.rb +141 -0
  99. data/lib/azure_mgmt_network/Models/virtual_network_gateway_connection_type.rb +18 -0
  100. data/lib/azure_mgmt_network/Models/virtual_network_gateway_ip_configuration.rb +90 -0
  101. data/lib/azure_mgmt_network/Models/virtual_network_gateway_ip_configuration_properties_format.rb +117 -0
  102. data/lib/azure_mgmt_network/Models/virtual_network_gateway_list_result.rb +88 -0
  103. data/lib/azure_mgmt_network/Models/virtual_network_gateway_properties_format.rb +126 -0
  104. data/lib/azure_mgmt_network/Models/virtual_network_gateway_type.rb +15 -0
  105. data/lib/azure_mgmt_network/Models/virtual_network_list_result.rb +88 -0
  106. data/lib/azure_mgmt_network/Models/virtual_network_properties_format.rb +123 -0
  107. data/lib/azure_mgmt_network/Models/vpn_type.rb +16 -0
  108. data/lib/azure_mgmt_network/application_gateways.rb +915 -0
  109. data/lib/azure_mgmt_network/load_balancers.rb +709 -0
  110. data/lib/azure_mgmt_network/local_network_gateways.rb +550 -0
  111. data/lib/azure_mgmt_network/module_definition.rb +6 -0
  112. data/lib/azure_mgmt_network/network_interfaces.rb +709 -0
  113. data/lib/azure_mgmt_network/network_resource_provider_client.rb +195 -0
  114. data/lib/azure_mgmt_network/network_security_groups.rb +718 -0
  115. data/lib/azure_mgmt_network/public_ip_addresses.rb +711 -0
  116. data/lib/azure_mgmt_network/security_rules.rb +563 -0
  117. data/lib/azure_mgmt_network/subnets.rb +552 -0
  118. data/lib/azure_mgmt_network/usages.rb +113 -0
  119. data/lib/azure_mgmt_network/version.rb +6 -0
  120. data/lib/azure_mgmt_network/virtual_network_gateway_connections.rb +945 -0
  121. data/lib/azure_mgmt_network/virtual_network_gateways.rb +686 -0
  122. data/lib/azure_mgmt_network/virtual_networks.rb +707 -0
  123. metadata +311 -0
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 7aa40067657d2f4ebd3795f70aa729483422c950
4
+ data.tar.gz: df4e530daa9b9578ba536834928210c29a9626ef
5
+ SHA512:
6
+ metadata.gz: 619a68b4c358d0a584b4f0740620ebc42b1f50800c5c323d04f95f7d96ef3d18028a7a0fed223370f782b097c0d0a31ef2f23c7326df780a66052cb73c6fb557
7
+ data.tar.gz: 13df49bf1a95948c596664854c2b3042d13d7b2ce2a11621d67237fc6b8060fa0ccea0c8e90bb540567a7aba710369738d35a35193dc357e57274d5b4eafb52b
@@ -0,0 +1,10 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /resource_management/azure_mgmt_network/spec/reports/
9
+ /tmp/
10
+ /.idea/
data/.rspec ADDED
@@ -0,0 +1,3 @@
1
+ --require spec_helper
2
+ --color
3
+ --format documentation
@@ -0,0 +1,3 @@
1
+ language: ruby
2
+ rvm:
3
+ - 2.1.5
data/Gemfile ADDED
@@ -0,0 +1,15 @@
1
+ # encoding: utf-8
2
+ # Copyright (c) Microsoft Corporation. All rights reserved.
3
+ # Licensed under the MIT License. See License.txt in the project root for license information.
4
+
5
+ source 'https://rubygems.org'
6
+
7
+ gemspec
8
+
9
+ group :development do
10
+ gem 'azure_mgmt_resources', path: '../azure_mgmt_resources'
11
+ end
12
+
13
+ group :test do
14
+ gem 'rspec'
15
+ end
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 Microsoft Corporation
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
@@ -0,0 +1,131 @@
1
+ # Intro
2
+
3
+ This project provides a Ruby gem for easy access to the Azure ARM Network API. With this gem you can create/update/list/delete virtual networks, subnets, load balancers and network interfaces. Application gateways, virtual network gateways and virtual network gateway connections aren't properly supported yet - it's a known issue that will be resolved soon.
4
+
5
+ # Supported Ruby Versions
6
+
7
+ * Ruby 2+
8
+
9
+ Note: x64 Ruby for Windows is known to have some compatibility issues.
10
+
11
+ # Getting started
12
+
13
+ ## Setting up the service principal
14
+
15
+ First of all to start interacting with the ARM network you will need to setup a service principal. Service principal is an Azure application which allows you to authenticate to Azure and access Azure services. The detailed steps of how to setup a service principal can be found in this article: http://aka.ms/cli-service-principal. In the result of setting up service principal you will get tenant id, client id and client secret data.
16
+
17
+ ## Installation
18
+
19
+ install the appropriate gem:
20
+
21
+ ```
22
+ gem install azure_mgmt_network
23
+ ```
24
+
25
+ and reference it in your code:
26
+
27
+ ```Ruby
28
+ require 'azure_mgmt_network'
29
+ ```
30
+
31
+ After that you should be ready to start using SDK!
32
+
33
+ ## Authentication
34
+
35
+ ```Ruby
36
+ # Create authentication objects
37
+ token_provider = MsRestAzure::ApplicationTokenProvider.new(tenant_id, client_id, secret)
38
+ credentials = MsRest::TokenCredentials.new(token_provider)
39
+ ```
40
+
41
+ To get tenant_id, client_id and secret for your Azure application visit Azure portal or copy them from the powershell script from the article mentioned above.
42
+
43
+ ## Creating new virtual network
44
+
45
+ ```Ruby
46
+ # Include SDK modules to ease access to network classes.
47
+ include Azure::ARM::Network
48
+ include Azure::ARM::Network::Models
49
+
50
+ # Create a client - a point of access to the API and set the subscription id
51
+ client = NetworkManagementClient.new(credentials)
52
+ client.subscription_id = subscription_id
53
+
54
+ # Create a model for new virtual network
55
+ props = VirtualNetworkPropertiesFormat.new
56
+
57
+ address_space = AddressSpace.new
58
+ address_space.address_prefixes = ['10.0.0.0/16']
59
+ props.address_space = address_space
60
+
61
+ dhcp_options = DhcpOptions.new
62
+ dhcp_options.dns_servers = %w(10.1.1.1 10.1.2.4)
63
+ props.dhcp_options = dhcp_options
64
+
65
+ sub_prop = SubnetPropertiesFormat.new
66
+ sub_prop.address_prefix = '10.0.2.0/24'
67
+
68
+ sub = Subnet.new
69
+ sub.name = 'new_subnet'
70
+ sub.properties = sub_prop
71
+
72
+ props.subnets = [sub]
73
+
74
+ params = VirtualNetwork.new
75
+ params.location = 'westus'
76
+ params.properties = props
77
+
78
+ promise = client.virtual_networks.create_or_update('existing_resource_group', 'new_vn', params)
79
+ ```
80
+
81
+ The SDK method returns a promise which you can utilize depending on your needs. E.g. if you need to get result immediately via sync blocking call - do the following:
82
+
83
+ ```Ruby
84
+ result = promise.value!
85
+ ```
86
+
87
+ If you need to follow async flow - provide a block which will be executed in off main thread:
88
+
89
+ ```Ruby
90
+ promise = promise.then do |result|
91
+ # Handle the result
92
+ end
93
+ ```
94
+
95
+ In both cases you're returned an instance of MsRestAzure::AzureOperationResponse which contains HTTP requests/response objects and response body. Response body is a deserialized object representing the received information. In case of code above - newly created virtual network. To get data from it:
96
+
97
+ ```Ruby
98
+ virtual_network = result.body
99
+
100
+ p virtual_network.name # name of the new vn
101
+ p virtual_network.id # id of the new vn
102
+ ```
103
+
104
+ Congrats, you've create new virtual network. We encourage you to try more stuff and let us know your feedback!
105
+ For advanced SDK usage please reference to the spec files.
106
+
107
+ # Running tests
108
+
109
+ ## Adding env variables
110
+
111
+ To run the tests you would need to set the following environment variables with your real Azure data:
112
+
113
+ * azure_tenant_id
114
+ * azure_client_id
115
+ * azure_client_secret
116
+ * subscription_id
117
+
118
+ * run_long_tasks - set this to '1' only if you would like to run time consuming tests like VM creation.
119
+
120
+ ## Starting tests
121
+
122
+ Just run 'rspec' command from the current gem folder.
123
+
124
+ # Contribution
125
+
126
+ All the SDK code was generated by tool 'AutoRest' - https://github.com/Azure/autorest
127
+ So if you have found a bug or have an idea for a new feature - suggest, discuss and contribute it into the AutoRest repository. After that SDK maintainers will update the sources and the gem.
128
+
129
+ # Provide feedback
130
+
131
+ Send email to the azsdkteam@microsoft.com or file new issue in this repository.
@@ -0,0 +1,5 @@
1
+ # encoding: utf-8
2
+ # Copyright (c) Microsoft Corporation. All rights reserved.
3
+ # Licensed under the MIT License. See License.txt in the project root for license information.
4
+
5
+ require "bundler/gem_tasks"
@@ -0,0 +1,39 @@
1
+ # encoding: utf-8
2
+ # Copyright (c) Microsoft Corporation. All rights reserved.
3
+ # Licensed under the MIT License. See License.txt in the project root for license information.
4
+
5
+ lib = File.expand_path('../lib', __FILE__)
6
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
7
+
8
+ require 'azure_mgmt_network/module_definition'
9
+ require 'azure_mgmt_network/version'
10
+
11
+ Gem::Specification.new do |spec|
12
+ spec.name = 'azure_mgmt_network'
13
+ spec.version = Azure::ARM::Network::VERSION
14
+ spec.authors = 'Microsoft Corporation'
15
+ spec.email = 'azsdkteam@microsoft.com'
16
+ spec.description = 'Microsoft Azure Network Management Client Library for Ruby'
17
+ spec.summary = 'Official ruby client library to consume Microsoft Azure Network Management services.'
18
+ spec.homepage = 'http://github.com/azure/azure-sdk-for-ruby'
19
+ spec.license = 'MIT'
20
+
21
+ spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
22
+ spec.bindir = 'bin'
23
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
24
+ spec.require_paths = ['lib']
25
+
26
+ spec.required_ruby_version = '>= 1.9.3'
27
+
28
+ spec.add_development_dependency 'bundler', '~> 1.9'
29
+ spec.add_development_dependency 'rake', '~> 10'
30
+ spec.add_development_dependency 'rspec', '~> 3'
31
+ spec.add_development_dependency 'dotenv', '~> 2'
32
+ spec.add_development_dependency 'azure_mgmt_resources', '~> 0.1'
33
+
34
+ spec.add_runtime_dependency 'json', '~> 1.8'
35
+ spec.add_runtime_dependency 'concurrent-ruby', ['>= 1.0.0.pre1', '<2']
36
+ spec.add_runtime_dependency 'faraday', '~> 0.9'
37
+ spec.add_runtime_dependency 'faraday-cookie_jar', '~> 0.0.6'
38
+ spec.add_runtime_dependency 'ms_rest_azure', '~> 0.1'
39
+ end
@@ -0,0 +1,139 @@
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
+
7
+ require 'uri'
8
+ require 'cgi'
9
+ require 'date'
10
+ require 'json'
11
+ require 'base64'
12
+ require 'erb'
13
+ require 'securerandom'
14
+ require 'time'
15
+ require 'timeliness'
16
+ require 'faraday'
17
+ require 'faraday-cookie_jar'
18
+ require 'concurrent'
19
+ require 'ms_rest'
20
+ require 'ms_rest_azure'
21
+
22
+ require 'azure_mgmt_network/module_definition'
23
+ require 'azure_mgmt_network/version'
24
+
25
+ module Azure::ARM::Network
26
+ autoload :ApplicationGateways, 'azure_mgmt_network/application_gateways.rb'
27
+ autoload :LoadBalancers, 'azure_mgmt_network/load_balancers.rb'
28
+ autoload :LocalNetworkGateways, 'azure_mgmt_network/local_network_gateways.rb'
29
+ autoload :NetworkInterfaces, 'azure_mgmt_network/network_interfaces.rb'
30
+ autoload :NetworkSecurityGroups, 'azure_mgmt_network/network_security_groups.rb'
31
+ autoload :PublicIpAddresses, 'azure_mgmt_network/public_ip_addresses.rb'
32
+ autoload :SecurityRules, 'azure_mgmt_network/security_rules.rb'
33
+ autoload :Subnets, 'azure_mgmt_network/subnets.rb'
34
+ autoload :Usages, 'azure_mgmt_network/usages.rb'
35
+ autoload :VirtualNetworkGatewayConnections, 'azure_mgmt_network/virtual_network_gateway_connections.rb'
36
+ autoload :VirtualNetworkGateways, 'azure_mgmt_network/virtual_network_gateways.rb'
37
+ autoload :VirtualNetworks, 'azure_mgmt_network/virtual_networks.rb'
38
+ autoload :NetworkResourceProviderClient, 'azure_mgmt_network/network_resource_provider_client.rb'
39
+
40
+ module Models
41
+ autoload :ApplicationGatewaySku, 'azure_mgmt_network/models/application_gateway_sku.rb'
42
+ autoload :ApplicationGatewayIpConfigurationPropertiesFormat, 'azure_mgmt_network/models/application_gateway_ip_configuration_properties_format.rb'
43
+ autoload :ApplicationGatewaySslCertificatePropertiesFormat, 'azure_mgmt_network/models/application_gateway_ssl_certificate_properties_format.rb'
44
+ autoload :ApplicationGatewayFrontendIpConfigurationPropertiesFormat, 'azure_mgmt_network/models/application_gateway_frontend_ip_configuration_properties_format.rb'
45
+ autoload :ApplicationGatewayFrontendPortPropertiesFormat, 'azure_mgmt_network/models/application_gateway_frontend_port_properties_format.rb'
46
+ autoload :ApplicationGatewayBackendAddress, 'azure_mgmt_network/models/application_gateway_backend_address.rb'
47
+ autoload :ApplicationGatewayBackendAddressPoolPropertiesFormat, 'azure_mgmt_network/models/application_gateway_backend_address_pool_properties_format.rb'
48
+ autoload :ApplicationGatewayBackendHttpSettingsPropertiesFormat, 'azure_mgmt_network/models/application_gateway_backend_http_settings_properties_format.rb'
49
+ autoload :ApplicationGatewayHttpListenerPropertiesFormat, 'azure_mgmt_network/models/application_gateway_http_listener_properties_format.rb'
50
+ autoload :ApplicationGatewayRequestRoutingRulePropertiesFormat, 'azure_mgmt_network/models/application_gateway_request_routing_rule_properties_format.rb'
51
+ autoload :ApplicationGatewayPropertiesFormat, 'azure_mgmt_network/models/application_gateway_properties_format.rb'
52
+ autoload :ApplicationGatewayListResult, 'azure_mgmt_network/models/application_gateway_list_result.rb'
53
+ autoload :FrontendIpConfigurationPropertiesFormat, 'azure_mgmt_network/models/frontend_ip_configuration_properties_format.rb'
54
+ autoload :BackendAddressPoolPropertiesFormat, 'azure_mgmt_network/models/backend_address_pool_properties_format.rb'
55
+ autoload :LoadBalancingRulePropertiesFormat, 'azure_mgmt_network/models/load_balancing_rule_properties_format.rb'
56
+ autoload :ProbePropertiesFormat, 'azure_mgmt_network/models/probe_properties_format.rb'
57
+ autoload :InboundNatRulePropertiesFormat, 'azure_mgmt_network/models/inbound_nat_rule_properties_format.rb'
58
+ autoload :LoadBalancerPropertiesFormat, 'azure_mgmt_network/models/load_balancer_properties_format.rb'
59
+ autoload :LoadBalancerListResult, 'azure_mgmt_network/models/load_balancer_list_result.rb'
60
+ autoload :AddressSpace, 'azure_mgmt_network/models/address_space.rb'
61
+ autoload :LocalNetworkGatewayPropertiesFormat, 'azure_mgmt_network/models/local_network_gateway_properties_format.rb'
62
+ autoload :LocalNetworkGatewayListResult, 'azure_mgmt_network/models/local_network_gateway_list_result.rb'
63
+ autoload :NetworkInterfaceIpConfigurationPropertiesFormat, 'azure_mgmt_network/models/network_interface_ip_configuration_properties_format.rb'
64
+ autoload :NetworkInterfaceDnsSettings, 'azure_mgmt_network/models/network_interface_dns_settings.rb'
65
+ autoload :NetworkInterfacePropertiesFormat, 'azure_mgmt_network/models/network_interface_properties_format.rb'
66
+ autoload :NetworkInterfaceListResult, 'azure_mgmt_network/models/network_interface_list_result.rb'
67
+ autoload :SecurityRulePropertiesFormat, 'azure_mgmt_network/models/security_rule_properties_format.rb'
68
+ autoload :NetworkSecurityGroupPropertiesFormat, 'azure_mgmt_network/models/network_security_group_properties_format.rb'
69
+ autoload :NetworkSecurityGroupListResult, 'azure_mgmt_network/models/network_security_group_list_result.rb'
70
+ autoload :PublicIpAddressDnsSettings, 'azure_mgmt_network/models/public_ip_address_dns_settings.rb'
71
+ autoload :PublicIpAddressPropertiesFormat, 'azure_mgmt_network/models/public_ip_address_properties_format.rb'
72
+ autoload :PublicIpAddressListResult, 'azure_mgmt_network/models/public_ip_address_list_result.rb'
73
+ autoload :SecurityRuleListResult, 'azure_mgmt_network/models/security_rule_list_result.rb'
74
+ autoload :SubnetPropertiesFormat, 'azure_mgmt_network/models/subnet_properties_format.rb'
75
+ autoload :SubnetListResult, 'azure_mgmt_network/models/subnet_list_result.rb'
76
+ autoload :UsageName, 'azure_mgmt_network/models/usage_name.rb'
77
+ autoload :Usage, 'azure_mgmt_network/models/usage.rb'
78
+ autoload :UsagesListResult, 'azure_mgmt_network/models/usages_list_result.rb'
79
+ autoload :VirtualNetworkGatewayIpConfigurationPropertiesFormat, 'azure_mgmt_network/models/virtual_network_gateway_ip_configuration_properties_format.rb'
80
+ autoload :VirtualNetworkGatewayPropertiesFormat, 'azure_mgmt_network/models/virtual_network_gateway_properties_format.rb'
81
+ autoload :VirtualNetworkGatewayConnectionPropertiesFormat, 'azure_mgmt_network/models/virtual_network_gateway_connection_properties_format.rb'
82
+ autoload :ConnectionSharedKey, 'azure_mgmt_network/models/connection_shared_key.rb'
83
+ autoload :VirtualNetworkGatewayConnectionListResult, 'azure_mgmt_network/models/virtual_network_gateway_connection_list_result.rb'
84
+ autoload :ConnectionResetSharedKeyPropertiesFormat, 'azure_mgmt_network/models/connection_reset_shared_key_properties_format.rb'
85
+ autoload :ConnectionResetSharedKey, 'azure_mgmt_network/models/connection_reset_shared_key.rb'
86
+ autoload :VirtualNetworkGatewayListResult, 'azure_mgmt_network/models/virtual_network_gateway_list_result.rb'
87
+ autoload :DhcpOptions, 'azure_mgmt_network/models/dhcp_options.rb'
88
+ autoload :VirtualNetworkPropertiesFormat, 'azure_mgmt_network/models/virtual_network_properties_format.rb'
89
+ autoload :VirtualNetworkListResult, 'azure_mgmt_network/models/virtual_network_list_result.rb'
90
+ autoload :DnsNameAvailabilityResult, 'azure_mgmt_network/models/dns_name_availability_result.rb'
91
+ autoload :ErrorDetails, 'azure_mgmt_network/models/error_details.rb'
92
+ autoload :Error, 'azure_mgmt_network/models/error.rb'
93
+ autoload :AzureAsyncOperationResult, 'azure_mgmt_network/models/azure_async_operation_result.rb'
94
+ autoload :ApplicationGatewayIpConfiguration, 'azure_mgmt_network/models/application_gateway_ip_configuration.rb'
95
+ autoload :ApplicationGatewaySslCertificate, 'azure_mgmt_network/models/application_gateway_ssl_certificate.rb'
96
+ autoload :ApplicationGatewayFrontendIpConfiguration, 'azure_mgmt_network/models/application_gateway_frontend_ip_configuration.rb'
97
+ autoload :ApplicationGatewayFrontendPort, 'azure_mgmt_network/models/application_gateway_frontend_port.rb'
98
+ autoload :ApplicationGatewayBackendAddressPool, 'azure_mgmt_network/models/application_gateway_backend_address_pool.rb'
99
+ autoload :ApplicationGatewayBackendHttpSettings, 'azure_mgmt_network/models/application_gateway_backend_http_settings.rb'
100
+ autoload :ApplicationGatewayHttpListener, 'azure_mgmt_network/models/application_gateway_http_listener.rb'
101
+ autoload :ApplicationGatewayRequestRoutingRule, 'azure_mgmt_network/models/application_gateway_request_routing_rule.rb'
102
+ autoload :ApplicationGateway, 'azure_mgmt_network/models/application_gateway.rb'
103
+ autoload :FrontendIpConfiguration, 'azure_mgmt_network/models/frontend_ip_configuration.rb'
104
+ autoload :BackendAddressPool, 'azure_mgmt_network/models/backend_address_pool.rb'
105
+ autoload :LoadBalancingRule, 'azure_mgmt_network/models/load_balancing_rule.rb'
106
+ autoload :Probe, 'azure_mgmt_network/models/probe.rb'
107
+ autoload :InboundNatRule, 'azure_mgmt_network/models/inbound_nat_rule.rb'
108
+ autoload :LoadBalancer, 'azure_mgmt_network/models/load_balancer.rb'
109
+ autoload :LocalNetworkGateway, 'azure_mgmt_network/models/local_network_gateway.rb'
110
+ autoload :NetworkInterfaceIpConfiguration, 'azure_mgmt_network/models/network_interface_ip_configuration.rb'
111
+ autoload :NetworkInterface, 'azure_mgmt_network/models/network_interface.rb'
112
+ autoload :SecurityRule, 'azure_mgmt_network/models/security_rule.rb'
113
+ autoload :NetworkSecurityGroup, 'azure_mgmt_network/models/network_security_group.rb'
114
+ autoload :PublicIpAddress, 'azure_mgmt_network/models/public_ip_address.rb'
115
+ autoload :Subnet, 'azure_mgmt_network/models/subnet.rb'
116
+ autoload :VirtualNetworkGatewayIpConfiguration, 'azure_mgmt_network/models/virtual_network_gateway_ip_configuration.rb'
117
+ autoload :VirtualNetworkGateway, 'azure_mgmt_network/models/virtual_network_gateway.rb'
118
+ autoload :VirtualNetworkGatewayConnection, 'azure_mgmt_network/models/virtual_network_gateway_connection.rb'
119
+ autoload :VirtualNetwork, 'azure_mgmt_network/models/virtual_network.rb'
120
+ autoload :ApplicationGatewaySkuName, 'azure_mgmt_network/models/application_gateway_sku_name.rb'
121
+ autoload :ApplicationGatewayTier, 'azure_mgmt_network/models/application_gateway_tier.rb'
122
+ autoload :IpAllocationMethod, 'azure_mgmt_network/models/ip_allocation_method.rb'
123
+ autoload :ApplicationGatewayProtocol, 'azure_mgmt_network/models/application_gateway_protocol.rb'
124
+ autoload :ApplicationGatewayCookieBasedAffinity, 'azure_mgmt_network/models/application_gateway_cookie_based_affinity.rb'
125
+ autoload :ApplicationGatewayRequestRoutingRuleType, 'azure_mgmt_network/models/application_gateway_request_routing_rule_type.rb'
126
+ autoload :ApplicationGatewayOperationalState, 'azure_mgmt_network/models/application_gateway_operational_state.rb'
127
+ autoload :TransportProtocol, 'azure_mgmt_network/models/transport_protocol.rb'
128
+ autoload :LoadDistribution, 'azure_mgmt_network/models/load_distribution.rb'
129
+ autoload :ProbeProtocol, 'azure_mgmt_network/models/probe_protocol.rb'
130
+ autoload :SecurityRuleProtocol, 'azure_mgmt_network/models/security_rule_protocol.rb'
131
+ autoload :SecurityRuleAccess, 'azure_mgmt_network/models/security_rule_access.rb'
132
+ autoload :SecurityRuleDirection, 'azure_mgmt_network/models/security_rule_direction.rb'
133
+ autoload :UsageUnit, 'azure_mgmt_network/models/usage_unit.rb'
134
+ autoload :VirtualNetworkGatewayType, 'azure_mgmt_network/models/virtual_network_gateway_type.rb'
135
+ autoload :VpnType, 'azure_mgmt_network/models/vpn_type.rb'
136
+ autoload :VirtualNetworkGatewayConnectionType, 'azure_mgmt_network/models/virtual_network_gateway_connection_type.rb'
137
+ autoload :OperationStatus, 'azure_mgmt_network/models/operation_status.rb'
138
+ end
139
+ end
@@ -0,0 +1,60 @@
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::Network
7
+ module Models
8
+ #
9
+ # AddressSpace contains an array of IP address ranges that can be used by
10
+ # subnets
11
+ #
12
+ class AddressSpace
13
+
14
+ include MsRestAzure
15
+
16
+ # @return [Array<String>] Gets or sets List of address blocks reserved
17
+ # for this virtual network in CIDR notation
18
+ attr_accessor :address_prefixes
19
+
20
+ #
21
+ # Validate the object. Throws ValidationError if validation fails.
22
+ #
23
+ def validate
24
+ @address_prefixes.each{ |e| e.validate if e.respond_to?(:validate) } unless @address_prefixes.nil?
25
+ end
26
+
27
+ #
28
+ # Serializes given Model object into Ruby Hash.
29
+ # @param object Model object to serialize.
30
+ # @return [Hash] Serialized object in form of Ruby Hash.
31
+ #
32
+ def self.serialize_object(object)
33
+ object.validate
34
+ output_object = {}
35
+
36
+ serialized_property = object.address_prefixes
37
+ output_object['addressPrefixes'] = serialized_property unless serialized_property.nil?
38
+
39
+ output_object
40
+ end
41
+
42
+ #
43
+ # Deserializes given Ruby Hash into Model object.
44
+ # @param object [Hash] Ruby Hash object to deserialize.
45
+ # @return [AddressSpace] Deserialized object.
46
+ #
47
+ def self.deserialize_object(object)
48
+ return if object.nil?
49
+ output_object = AddressSpace.new
50
+
51
+ deserialized_property = object['addressPrefixes']
52
+ output_object.address_prefixes = deserialized_property
53
+
54
+ output_object.validate
55
+
56
+ output_object
57
+ end
58
+ end
59
+ end
60
+ end