Skip to content
This repository has been archived by the owner on Jan 11, 2023. It is now read-only.

Commit

Permalink
[AutoPR] network/resource-manager (#1327)
Browse files Browse the repository at this point in the history
* Generated from 5f0be8e7d15826d0a75d882f827363c62b7739e8 (#1325)

moved 2018-05-01 progress to April folder

* Generated from 5f0be8e7d15826d0a75d882f827363c62b7739e8 (#1328)

moved 2018-05-01 progress to April folder

* Generated from 4272bde8d3dc5bf0cba4fc8947c0154889075efa (#1356)

added primary flag to the NetworkInterfaceIPConfigurationPropertiesFormat object of networkInterface.json definition of Network 2015-06-15 spec
  • Loading branch information
AutorestCI authored and sarangan12 committed Jun 13, 2018
1 parent 5ee329c commit ef5fd9a
Show file tree
Hide file tree
Showing 2,032 changed files with 15,387 additions and 29,315 deletions.
482 changes: 243 additions & 239 deletions azure_sdk/lib/latest/modules/network_profile_module.rb

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -31,8 +31,8 @@ def initialize(client)
# @param custom_headers [Hash{String => String}] A hash of custom headers that
# will be added to the HTTP request.
#
def delete(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
response = delete_async(resource_group_name, circuit_name, authorization_name, custom_headers:custom_headers).value!
def delete(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
response = delete_async(resource_group_name, circuit_name, authorization_name, custom_headers).value!
nil
end

Expand All @@ -46,9 +46,9 @@ def delete(resource_group_name, circuit_name, authorization_name, custom_headers
# @return [Concurrent::Promise] promise which provides async access to http
# response.
#
def delete_async(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
def delete_async(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
# Send request
promise = begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers:custom_headers)
promise = begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers)

promise = promise.then do |response|
# Defining deserialization method.
Expand All @@ -74,8 +74,8 @@ def delete_async(resource_group_name, circuit_name, authorization_name, custom_h
#
# @return [ExpressRouteCircuitAuthorization] operation results.
#
def get(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
response = get_async(resource_group_name, circuit_name, authorization_name, custom_headers:custom_headers).value!
def get(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
response = get_async(resource_group_name, circuit_name, authorization_name, custom_headers).value!
response.body unless response.nil?
end

Expand All @@ -91,8 +91,8 @@ def get(resource_group_name, circuit_name, authorization_name, custom_headers:ni
#
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
#
def get_with_http_info(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
get_async(resource_group_name, circuit_name, authorization_name, custom_headers:custom_headers).value!
def get_with_http_info(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
get_async(resource_group_name, circuit_name, authorization_name, custom_headers).value!
end

#
Expand All @@ -107,7 +107,7 @@ def get_with_http_info(resource_group_name, circuit_name, authorization_name, cu
#
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
#
def get_async(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
def get_async(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
fail ArgumentError, 'circuit_name is nil' if circuit_name.nil?
fail ArgumentError, 'authorization_name is nil' if authorization_name.nil?
Expand All @@ -116,7 +116,6 @@ def get_async(resource_group_name, circuit_name, authorization_name, custom_head


request_headers = {}
request_headers['Content-Type'] = 'application/json; charset=utf-8'

# Set Headers
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
Expand Down Expand Up @@ -175,8 +174,8 @@ def get_async(resource_group_name, circuit_name, authorization_name, custom_head
#
# @return [ExpressRouteCircuitAuthorization] operation results.
#
def create_or_update(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:nil)
response = create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:custom_headers).value!
def create_or_update(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers = nil)
response = create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers).value!
response.body unless response.nil?
end

Expand All @@ -192,9 +191,9 @@ def create_or_update(resource_group_name, circuit_name, authorization_name, auth
# @return [Concurrent::Promise] promise which provides async access to http
# response.
#
def create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:nil)
def create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers = nil)
# Send request
promise = begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:custom_headers)
promise = begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers)

promise = promise.then do |response|
# Defining deserialization method.
Expand All @@ -221,8 +220,8 @@ def create_or_update_async(resource_group_name, circuit_name, authorization_name
#
# @return [Array<ExpressRouteCircuitAuthorization>] operation results.
#
def list(resource_group_name, circuit_name, custom_headers:nil)
first_page = list_as_lazy(resource_group_name, circuit_name, custom_headers:custom_headers)
def list(resource_group_name, circuit_name, custom_headers = nil)
first_page = list_as_lazy(resource_group_name, circuit_name, custom_headers)
first_page.get_all_items
end

Expand All @@ -237,8 +236,8 @@ def list(resource_group_name, circuit_name, custom_headers:nil)
#
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
#
def list_with_http_info(resource_group_name, circuit_name, custom_headers:nil)
list_async(resource_group_name, circuit_name, custom_headers:custom_headers).value!
def list_with_http_info(resource_group_name, circuit_name, custom_headers = nil)
list_async(resource_group_name, circuit_name, custom_headers).value!
end

#
Expand All @@ -252,15 +251,14 @@ def list_with_http_info(resource_group_name, circuit_name, custom_headers:nil)
#
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
#
def list_async(resource_group_name, circuit_name, custom_headers:nil)
def list_async(resource_group_name, circuit_name, custom_headers = nil)
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
fail ArgumentError, 'circuit_name is nil' if circuit_name.nil?
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?


request_headers = {}
request_headers['Content-Type'] = 'application/json; charset=utf-8'

# Set Headers
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
Expand Down Expand Up @@ -316,8 +314,8 @@ def list_async(resource_group_name, circuit_name, custom_headers:nil)
# will be added to the HTTP request.
#
#
def begin_delete(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
response = begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers:custom_headers).value!
def begin_delete(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
response = begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers).value!
nil
end

Expand All @@ -333,8 +331,8 @@ def begin_delete(resource_group_name, circuit_name, authorization_name, custom_h
#
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
#
def begin_delete_with_http_info(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers:custom_headers).value!
def begin_delete_with_http_info(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers).value!
end

#
Expand All @@ -349,7 +347,7 @@ def begin_delete_with_http_info(resource_group_name, circuit_name, authorization
#
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
#
def begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers:nil)
def begin_delete_async(resource_group_name, circuit_name, authorization_name, custom_headers = nil)
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
fail ArgumentError, 'circuit_name is nil' if circuit_name.nil?
fail ArgumentError, 'authorization_name is nil' if authorization_name.nil?
Expand All @@ -358,7 +356,6 @@ def begin_delete_async(resource_group_name, circuit_name, authorization_name, cu


request_headers = {}
request_headers['Content-Type'] = 'application/json; charset=utf-8'

# Set Headers
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
Expand Down Expand Up @@ -407,8 +404,8 @@ def begin_delete_async(resource_group_name, circuit_name, authorization_name, cu
#
# @return [ExpressRouteCircuitAuthorization] operation results.
#
def begin_create_or_update(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:nil)
response = begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:custom_headers).value!
def begin_create_or_update(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers = nil)
response = begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers).value!
response.body unless response.nil?
end

Expand All @@ -426,8 +423,8 @@ def begin_create_or_update(resource_group_name, circuit_name, authorization_name
#
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
#
def begin_create_or_update_with_http_info(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:nil)
begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:custom_headers).value!
def begin_create_or_update_with_http_info(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers = nil)
begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers).value!
end

#
Expand All @@ -444,7 +441,7 @@ def begin_create_or_update_with_http_info(resource_group_name, circuit_name, aut
#
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
#
def begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers:nil)
def begin_create_or_update_async(resource_group_name, circuit_name, authorization_name, authorization_parameters, custom_headers = nil)
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
fail ArgumentError, 'circuit_name is nil' if circuit_name.nil?
fail ArgumentError, 'authorization_name is nil' if authorization_name.nil?
Expand All @@ -454,12 +451,13 @@ def begin_create_or_update_async(resource_group_name, circuit_name, authorizatio


request_headers = {}
request_headers['Content-Type'] = 'application/json; charset=utf-8'

# Set Headers
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?

request_headers['Content-Type'] = 'application/json; charset=utf-8'

# Serialize Request
request_mapper = Azure::Network::Mgmt::V2015_05_01_preview::Models::ExpressRouteCircuitAuthorization.mapper()
request_content = @client.serialize(request_mapper, authorization_parameters)
Expand Down Expand Up @@ -527,8 +525,8 @@ def begin_create_or_update_async(resource_group_name, circuit_name, authorizatio
#
# @return [AuthorizationListResult] operation results.
#
def list_next(next_page_link, custom_headers:nil)
response = list_next_async(next_page_link, custom_headers:custom_headers).value!
def list_next(next_page_link, custom_headers = nil)
response = list_next_async(next_page_link, custom_headers).value!
response.body unless response.nil?
end

Expand All @@ -543,8 +541,8 @@ def list_next(next_page_link, custom_headers:nil)
#
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
#
def list_next_with_http_info(next_page_link, custom_headers:nil)
list_next_async(next_page_link, custom_headers:custom_headers).value!
def list_next_with_http_info(next_page_link, custom_headers = nil)
list_next_async(next_page_link, custom_headers).value!
end

#
Expand All @@ -558,12 +556,11 @@ def list_next_with_http_info(next_page_link, custom_headers:nil)
#
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
#
def list_next_async(next_page_link, custom_headers:nil)
def list_next_async(next_page_link, custom_headers = nil)
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?


request_headers = {}
request_headers['Content-Type'] = 'application/json; charset=utf-8'

# Set Headers
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
Expand Down Expand Up @@ -619,12 +616,12 @@ def list_next_async(next_page_link, custom_headers:nil)
# @return [AuthorizationListResult] which provide lazy access to pages of the
# response.
#
def list_as_lazy(resource_group_name, circuit_name, custom_headers:nil)
response = list_async(resource_group_name, circuit_name, custom_headers:custom_headers).value!
def list_as_lazy(resource_group_name, circuit_name, custom_headers = nil)
response = list_async(resource_group_name, circuit_name, custom_headers).value!
unless response.nil?
page = response.body
page.next_method = Proc.new do |next_page_link|
list_next_async(next_page_link, custom_headers:custom_headers)
list_next_async(next_page_link, custom_headers)
end
page
end
Expand Down
Loading

0 comments on commit ef5fd9a

Please sign in to comment.