azure_mgmt_devtestlabs 0.15.2 → 0.16.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs.rb +70 -62
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/arm_templates.rb +21 -18
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/artifact_sources.rb +39 -37
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/artifacts.rb +27 -25
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/costs.rb +12 -12
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/custom_images.rb +41 -38
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/dev_test_labs_client.rb +12 -1
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/disks.rb +61 -60
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/environments.rb +41 -38
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/formulas.rb +37 -34
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/gallery_images.rb +15 -13
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/global_schedules.rb +74 -70
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/labs.rb +113 -109
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/cost_threshold_properties.rb +1 -1
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/http_status_code.rb +56 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/identity_properties.rb +1 -1
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/operation_error.rb +57 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/operation_metadata.rb +59 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/operation_metadata_display.rb +80 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/operation_result.rb +82 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/models/provider_operation_result.rb +101 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/notification_channels.rb +45 -44
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/operations.rb +117 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/policies.rb +39 -37
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/policy_sets.rb +6 -7
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/provider_operations.rb +215 -0
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/schedules.rb +64 -59
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/secrets.rb +33 -30
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/service_runners.rb +33 -30
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/users.rb +43 -41
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/virtual_machine_schedules.rb +49 -46
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/virtual_machines.rb +113 -110
- data/lib/2016-05-15/generated/azure_mgmt_devtestlabs/virtual_networks.rb +47 -45
- data/lib/profiles/latest/devtestlabs_latest_profile_client.rb +28 -9
- data/lib/profiles/latest/devtestlabs_module_definition.rb +0 -1
- data/lib/profiles/latest/modules/devtestlabs_profile_module.rb +589 -542
- data/lib/version.rb +1 -1
- metadata +10 -2
@@ -34,8 +34,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
34
34
|
#
|
35
35
|
# @return [EvaluatePoliciesResponse] operation results.
|
36
36
|
#
|
37
|
-
def evaluate_policies(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers
|
38
|
-
response = evaluate_policies_async(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers).value!
|
37
|
+
def evaluate_policies(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers:nil)
|
38
|
+
response = evaluate_policies_async(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers:custom_headers).value!
|
39
39
|
response.body unless response.nil?
|
40
40
|
end
|
41
41
|
|
@@ -52,8 +52,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
52
52
|
#
|
53
53
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
54
54
|
#
|
55
|
-
def evaluate_policies_with_http_info(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers
|
56
|
-
evaluate_policies_async(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers).value!
|
55
|
+
def evaluate_policies_with_http_info(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers:nil)
|
56
|
+
evaluate_policies_async(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers:custom_headers).value!
|
57
57
|
end
|
58
58
|
|
59
59
|
#
|
@@ -69,7 +69,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
69
69
|
#
|
70
70
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
71
71
|
#
|
72
|
-
def evaluate_policies_async(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers
|
72
|
+
def evaluate_policies_async(resource_group_name, lab_name, name, evaluate_policies_request, custom_headers:nil)
|
73
73
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
74
74
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
75
75
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -79,13 +79,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
79
79
|
|
80
80
|
|
81
81
|
request_headers = {}
|
82
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
82
83
|
|
83
84
|
# Set Headers
|
84
85
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
85
86
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
86
87
|
|
87
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
88
|
-
|
89
88
|
# Serialize Request
|
90
89
|
request_mapper = Azure::DevTestLabs::Mgmt::V2016_05_15::Models::EvaluatePoliciesRequest.mapper()
|
91
90
|
request_content = @client.serialize(request_mapper, evaluate_policies_request)
|
@@ -0,0 +1,215 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
# Code generated by Microsoft (R) AutoRest Code Generator.
|
3
|
+
# Changes may cause incorrect behavior and will be lost if the code is
|
4
|
+
# regenerated.
|
5
|
+
|
6
|
+
module Azure::DevTestLabs::Mgmt::V2016_05_15
|
7
|
+
#
|
8
|
+
# The DevTest Labs Client.
|
9
|
+
#
|
10
|
+
class ProviderOperations
|
11
|
+
include MsRestAzure
|
12
|
+
|
13
|
+
#
|
14
|
+
# Creates and initializes a new instance of the ProviderOperations class.
|
15
|
+
# @param client service class for accessing basic functionality.
|
16
|
+
#
|
17
|
+
def initialize(client)
|
18
|
+
@client = client
|
19
|
+
end
|
20
|
+
|
21
|
+
# @return [DevTestLabsClient] reference to the DevTestLabsClient
|
22
|
+
attr_reader :client
|
23
|
+
|
24
|
+
#
|
25
|
+
# Result of the request to list REST API operations
|
26
|
+
#
|
27
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
28
|
+
# will be added to the HTTP request.
|
29
|
+
#
|
30
|
+
# @return [Array<OperationMetadata>] operation results.
|
31
|
+
#
|
32
|
+
def list(custom_headers:nil)
|
33
|
+
first_page = list_as_lazy(custom_headers:custom_headers)
|
34
|
+
first_page.get_all_items
|
35
|
+
end
|
36
|
+
|
37
|
+
#
|
38
|
+
# Result of the request to list REST API operations
|
39
|
+
#
|
40
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
41
|
+
# will be added to the HTTP request.
|
42
|
+
#
|
43
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
44
|
+
#
|
45
|
+
def list_with_http_info(custom_headers:nil)
|
46
|
+
list_async(custom_headers:custom_headers).value!
|
47
|
+
end
|
48
|
+
|
49
|
+
#
|
50
|
+
# Result of the request to list REST API operations
|
51
|
+
#
|
52
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
53
|
+
# to the HTTP request.
|
54
|
+
#
|
55
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
56
|
+
#
|
57
|
+
def list_async(custom_headers:nil)
|
58
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
59
|
+
|
60
|
+
|
61
|
+
request_headers = {}
|
62
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
63
|
+
|
64
|
+
# Set Headers
|
65
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
66
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
67
|
+
path_template = 'providers/Microsoft.DevTestLab/operations'
|
68
|
+
|
69
|
+
request_url = @base_url || @client.base_url
|
70
|
+
|
71
|
+
options = {
|
72
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
73
|
+
query_params: {'api-version' => @client.api_version},
|
74
|
+
headers: request_headers.merge(custom_headers || {}),
|
75
|
+
base_url: request_url
|
76
|
+
}
|
77
|
+
promise = @client.make_request_async(:get, path_template, options)
|
78
|
+
|
79
|
+
promise = promise.then do |result|
|
80
|
+
http_response = result.response
|
81
|
+
status_code = http_response.status
|
82
|
+
response_content = http_response.body
|
83
|
+
unless status_code == 200
|
84
|
+
error_model = JSON.load(response_content)
|
85
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
86
|
+
end
|
87
|
+
|
88
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
89
|
+
# Deserialize Response
|
90
|
+
if status_code == 200
|
91
|
+
begin
|
92
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
93
|
+
result_mapper = Azure::DevTestLabs::Mgmt::V2016_05_15::Models::ProviderOperationResult.mapper()
|
94
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
95
|
+
rescue Exception => e
|
96
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
97
|
+
end
|
98
|
+
end
|
99
|
+
|
100
|
+
result
|
101
|
+
end
|
102
|
+
|
103
|
+
promise.execute
|
104
|
+
end
|
105
|
+
|
106
|
+
#
|
107
|
+
# Result of the request to list REST API operations
|
108
|
+
#
|
109
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
110
|
+
# to List operation.
|
111
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
112
|
+
# will be added to the HTTP request.
|
113
|
+
#
|
114
|
+
# @return [ProviderOperationResult] operation results.
|
115
|
+
#
|
116
|
+
def list_next(next_page_link, custom_headers:nil)
|
117
|
+
response = list_next_async(next_page_link, custom_headers:custom_headers).value!
|
118
|
+
response.body unless response.nil?
|
119
|
+
end
|
120
|
+
|
121
|
+
#
|
122
|
+
# Result of the request to list REST API operations
|
123
|
+
#
|
124
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
125
|
+
# to List operation.
|
126
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
127
|
+
# will be added to the HTTP request.
|
128
|
+
#
|
129
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
130
|
+
#
|
131
|
+
def list_next_with_http_info(next_page_link, custom_headers:nil)
|
132
|
+
list_next_async(next_page_link, custom_headers:custom_headers).value!
|
133
|
+
end
|
134
|
+
|
135
|
+
#
|
136
|
+
# Result of the request to list REST API operations
|
137
|
+
#
|
138
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
139
|
+
# to List operation.
|
140
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
141
|
+
# to the HTTP request.
|
142
|
+
#
|
143
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
144
|
+
#
|
145
|
+
def list_next_async(next_page_link, custom_headers:nil)
|
146
|
+
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
|
147
|
+
|
148
|
+
|
149
|
+
request_headers = {}
|
150
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
151
|
+
|
152
|
+
# Set Headers
|
153
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
154
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
155
|
+
path_template = '{nextLink}'
|
156
|
+
|
157
|
+
request_url = @base_url || @client.base_url
|
158
|
+
|
159
|
+
options = {
|
160
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
161
|
+
skip_encoding_path_params: {'nextLink' => next_page_link},
|
162
|
+
headers: request_headers.merge(custom_headers || {}),
|
163
|
+
base_url: request_url
|
164
|
+
}
|
165
|
+
promise = @client.make_request_async(:get, path_template, options)
|
166
|
+
|
167
|
+
promise = promise.then do |result|
|
168
|
+
http_response = result.response
|
169
|
+
status_code = http_response.status
|
170
|
+
response_content = http_response.body
|
171
|
+
unless status_code == 200
|
172
|
+
error_model = JSON.load(response_content)
|
173
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
174
|
+
end
|
175
|
+
|
176
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
177
|
+
# Deserialize Response
|
178
|
+
if status_code == 200
|
179
|
+
begin
|
180
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
181
|
+
result_mapper = Azure::DevTestLabs::Mgmt::V2016_05_15::Models::ProviderOperationResult.mapper()
|
182
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
183
|
+
rescue Exception => e
|
184
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
185
|
+
end
|
186
|
+
end
|
187
|
+
|
188
|
+
result
|
189
|
+
end
|
190
|
+
|
191
|
+
promise.execute
|
192
|
+
end
|
193
|
+
|
194
|
+
#
|
195
|
+
# Result of the request to list REST API operations
|
196
|
+
#
|
197
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
198
|
+
# will be added to the HTTP request.
|
199
|
+
#
|
200
|
+
# @return [ProviderOperationResult] which provide lazy access to pages of the
|
201
|
+
# response.
|
202
|
+
#
|
203
|
+
def list_as_lazy(custom_headers:nil)
|
204
|
+
response = list_async(custom_headers:custom_headers).value!
|
205
|
+
unless response.nil?
|
206
|
+
page = response.body
|
207
|
+
page.next_method = Proc.new do |next_page_link|
|
208
|
+
list_next_async(next_page_link, custom_headers:custom_headers)
|
209
|
+
end
|
210
|
+
page
|
211
|
+
end
|
212
|
+
end
|
213
|
+
|
214
|
+
end
|
215
|
+
end
|
@@ -38,8 +38,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
38
38
|
#
|
39
39
|
# @return [Array<Schedule>] operation results.
|
40
40
|
#
|
41
|
-
def list(resource_group_name, lab_name, expand
|
42
|
-
first_page = list_as_lazy(resource_group_name, lab_name, expand, filter, top, orderby, custom_headers)
|
41
|
+
def list(resource_group_name, lab_name, expand:nil, filter:nil, top:nil, orderby:nil, custom_headers:nil)
|
42
|
+
first_page = list_as_lazy(resource_group_name, lab_name, expand:expand, filter:filter, top:top, orderby:orderby, custom_headers:custom_headers)
|
43
43
|
first_page.get_all_items
|
44
44
|
end
|
45
45
|
|
@@ -60,8 +60,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
60
60
|
#
|
61
61
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
62
62
|
#
|
63
|
-
def list_with_http_info(resource_group_name, lab_name, expand
|
64
|
-
list_async(resource_group_name, lab_name, expand, filter, top, orderby, custom_headers).value!
|
63
|
+
def list_with_http_info(resource_group_name, lab_name, expand:nil, filter:nil, top:nil, orderby:nil, custom_headers:nil)
|
64
|
+
list_async(resource_group_name, lab_name, expand:expand, filter:filter, top:top, orderby:orderby, custom_headers:custom_headers).value!
|
65
65
|
end
|
66
66
|
|
67
67
|
#
|
@@ -81,7 +81,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
81
81
|
#
|
82
82
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
83
83
|
#
|
84
|
-
def list_async(resource_group_name, lab_name, expand
|
84
|
+
def list_async(resource_group_name, lab_name, expand:nil, filter:nil, top:nil, orderby:nil, custom_headers:nil)
|
85
85
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
86
86
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
87
87
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -89,6 +89,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
89
89
|
|
90
90
|
|
91
91
|
request_headers = {}
|
92
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
92
93
|
|
93
94
|
# Set Headers
|
94
95
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -146,8 +147,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
146
147
|
#
|
147
148
|
# @return [Schedule] operation results.
|
148
149
|
#
|
149
|
-
def get(resource_group_name, lab_name, name, expand
|
150
|
-
response = get_async(resource_group_name, lab_name, name, expand, custom_headers).value!
|
150
|
+
def get(resource_group_name, lab_name, name, expand:nil, custom_headers:nil)
|
151
|
+
response = get_async(resource_group_name, lab_name, name, expand:expand, custom_headers:custom_headers).value!
|
151
152
|
response.body unless response.nil?
|
152
153
|
end
|
153
154
|
|
@@ -164,8 +165,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
164
165
|
#
|
165
166
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
166
167
|
#
|
167
|
-
def get_with_http_info(resource_group_name, lab_name, name, expand
|
168
|
-
get_async(resource_group_name, lab_name, name, expand, custom_headers).value!
|
168
|
+
def get_with_http_info(resource_group_name, lab_name, name, expand:nil, custom_headers:nil)
|
169
|
+
get_async(resource_group_name, lab_name, name, expand:expand, custom_headers:custom_headers).value!
|
169
170
|
end
|
170
171
|
|
171
172
|
#
|
@@ -181,7 +182,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
181
182
|
#
|
182
183
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
183
184
|
#
|
184
|
-
def get_async(resource_group_name, lab_name, name, expand
|
185
|
+
def get_async(resource_group_name, lab_name, name, expand:nil, custom_headers:nil)
|
185
186
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
186
187
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
187
188
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -190,6 +191,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
190
191
|
|
191
192
|
|
192
193
|
request_headers = {}
|
194
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
193
195
|
|
194
196
|
# Set Headers
|
195
197
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -246,8 +248,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
246
248
|
#
|
247
249
|
# @return [Schedule] operation results.
|
248
250
|
#
|
249
|
-
def create_or_update(resource_group_name, lab_name, name, schedule, custom_headers
|
250
|
-
response = create_or_update_async(resource_group_name, lab_name, name, schedule, custom_headers).value!
|
251
|
+
def create_or_update(resource_group_name, lab_name, name, schedule, custom_headers:nil)
|
252
|
+
response = create_or_update_async(resource_group_name, lab_name, name, schedule, custom_headers:custom_headers).value!
|
251
253
|
response.body unless response.nil?
|
252
254
|
end
|
253
255
|
|
@@ -263,8 +265,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
263
265
|
#
|
264
266
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
265
267
|
#
|
266
|
-
def create_or_update_with_http_info(resource_group_name, lab_name, name, schedule, custom_headers
|
267
|
-
create_or_update_async(resource_group_name, lab_name, name, schedule, custom_headers).value!
|
268
|
+
def create_or_update_with_http_info(resource_group_name, lab_name, name, schedule, custom_headers:nil)
|
269
|
+
create_or_update_async(resource_group_name, lab_name, name, schedule, custom_headers:custom_headers).value!
|
268
270
|
end
|
269
271
|
|
270
272
|
#
|
@@ -279,7 +281,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
279
281
|
#
|
280
282
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
281
283
|
#
|
282
|
-
def create_or_update_async(resource_group_name, lab_name, name, schedule, custom_headers
|
284
|
+
def create_or_update_async(resource_group_name, lab_name, name, schedule, custom_headers:nil)
|
283
285
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
284
286
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
285
287
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -289,13 +291,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
289
291
|
|
290
292
|
|
291
293
|
request_headers = {}
|
294
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
292
295
|
|
293
296
|
# Set Headers
|
294
297
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
295
298
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
296
299
|
|
297
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
298
|
-
|
299
300
|
# Serialize Request
|
300
301
|
request_mapper = Azure::DevTestLabs::Mgmt::V2016_05_15::Models::Schedule.mapper()
|
301
302
|
request_content = @client.serialize(request_mapper, schedule)
|
@@ -362,8 +363,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
362
363
|
# will be added to the HTTP request.
|
363
364
|
#
|
364
365
|
#
|
365
|
-
def delete(resource_group_name, lab_name, name, custom_headers
|
366
|
-
response = delete_async(resource_group_name, lab_name, name, custom_headers).value!
|
366
|
+
def delete(resource_group_name, lab_name, name, custom_headers:nil)
|
367
|
+
response = delete_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
367
368
|
nil
|
368
369
|
end
|
369
370
|
|
@@ -378,8 +379,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
378
379
|
#
|
379
380
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
380
381
|
#
|
381
|
-
def delete_with_http_info(resource_group_name, lab_name, name, custom_headers
|
382
|
-
delete_async(resource_group_name, lab_name, name, custom_headers).value!
|
382
|
+
def delete_with_http_info(resource_group_name, lab_name, name, custom_headers:nil)
|
383
|
+
delete_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
383
384
|
end
|
384
385
|
|
385
386
|
#
|
@@ -393,7 +394,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
393
394
|
#
|
394
395
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
395
396
|
#
|
396
|
-
def delete_async(resource_group_name, lab_name, name, custom_headers
|
397
|
+
def delete_async(resource_group_name, lab_name, name, custom_headers:nil)
|
397
398
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
398
399
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
399
400
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -402,6 +403,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
402
403
|
|
403
404
|
|
404
405
|
request_headers = {}
|
406
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
405
407
|
|
406
408
|
# Set Headers
|
407
409
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -448,8 +450,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
448
450
|
#
|
449
451
|
# @return [Schedule] operation results.
|
450
452
|
#
|
451
|
-
def update(resource_group_name, lab_name, name, schedule, custom_headers
|
452
|
-
response = update_async(resource_group_name, lab_name, name, schedule, custom_headers).value!
|
453
|
+
def update(resource_group_name, lab_name, name, schedule, custom_headers:nil)
|
454
|
+
response = update_async(resource_group_name, lab_name, name, schedule, custom_headers:custom_headers).value!
|
453
455
|
response.body unless response.nil?
|
454
456
|
end
|
455
457
|
|
@@ -465,8 +467,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
465
467
|
#
|
466
468
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
467
469
|
#
|
468
|
-
def update_with_http_info(resource_group_name, lab_name, name, schedule, custom_headers
|
469
|
-
update_async(resource_group_name, lab_name, name, schedule, custom_headers).value!
|
470
|
+
def update_with_http_info(resource_group_name, lab_name, name, schedule, custom_headers:nil)
|
471
|
+
update_async(resource_group_name, lab_name, name, schedule, custom_headers:custom_headers).value!
|
470
472
|
end
|
471
473
|
|
472
474
|
#
|
@@ -481,7 +483,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
481
483
|
#
|
482
484
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
483
485
|
#
|
484
|
-
def update_async(resource_group_name, lab_name, name, schedule, custom_headers
|
486
|
+
def update_async(resource_group_name, lab_name, name, schedule, custom_headers:nil)
|
485
487
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
486
488
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
487
489
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -491,13 +493,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
491
493
|
|
492
494
|
|
493
495
|
request_headers = {}
|
496
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
494
497
|
|
495
498
|
# Set Headers
|
496
499
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
497
500
|
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
498
501
|
|
499
|
-
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
500
|
-
|
501
502
|
# Serialize Request
|
502
503
|
request_mapper = Azure::DevTestLabs::Mgmt::V2016_05_15::Models::ScheduleFragment.mapper()
|
503
504
|
request_content = @client.serialize(request_mapper, schedule)
|
@@ -553,8 +554,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
553
554
|
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
554
555
|
# will be added to the HTTP request.
|
555
556
|
#
|
556
|
-
def execute(resource_group_name, lab_name, name, custom_headers
|
557
|
-
response = execute_async(resource_group_name, lab_name, name, custom_headers).value!
|
557
|
+
def execute(resource_group_name, lab_name, name, custom_headers:nil)
|
558
|
+
response = execute_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
558
559
|
nil
|
559
560
|
end
|
560
561
|
|
@@ -568,9 +569,9 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
568
569
|
# @return [Concurrent::Promise] promise which provides async access to http
|
569
570
|
# response.
|
570
571
|
#
|
571
|
-
def execute_async(resource_group_name, lab_name, name, custom_headers
|
572
|
+
def execute_async(resource_group_name, lab_name, name, custom_headers:nil)
|
572
573
|
# Send request
|
573
|
-
promise = begin_execute_async(resource_group_name, lab_name, name, custom_headers)
|
574
|
+
promise = begin_execute_async(resource_group_name, lab_name, name, custom_headers:custom_headers)
|
574
575
|
|
575
576
|
promise = promise.then do |response|
|
576
577
|
# Defining deserialization method.
|
@@ -595,8 +596,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
595
596
|
#
|
596
597
|
# @return [Array<Schedule>] operation results.
|
597
598
|
#
|
598
|
-
def list_applicable(resource_group_name, lab_name, name, custom_headers
|
599
|
-
first_page = list_applicable_as_lazy(resource_group_name, lab_name, name, custom_headers)
|
599
|
+
def list_applicable(resource_group_name, lab_name, name, custom_headers:nil)
|
600
|
+
first_page = list_applicable_as_lazy(resource_group_name, lab_name, name, custom_headers:custom_headers)
|
600
601
|
first_page.get_all_items
|
601
602
|
end
|
602
603
|
|
@@ -611,8 +612,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
611
612
|
#
|
612
613
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
613
614
|
#
|
614
|
-
def list_applicable_with_http_info(resource_group_name, lab_name, name, custom_headers
|
615
|
-
list_applicable_async(resource_group_name, lab_name, name, custom_headers).value!
|
615
|
+
def list_applicable_with_http_info(resource_group_name, lab_name, name, custom_headers:nil)
|
616
|
+
list_applicable_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
616
617
|
end
|
617
618
|
|
618
619
|
#
|
@@ -626,7 +627,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
626
627
|
#
|
627
628
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
628
629
|
#
|
629
|
-
def list_applicable_async(resource_group_name, lab_name, name, custom_headers
|
630
|
+
def list_applicable_async(resource_group_name, lab_name, name, custom_headers:nil)
|
630
631
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
631
632
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
632
633
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -635,6 +636,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
635
636
|
|
636
637
|
|
637
638
|
request_headers = {}
|
639
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
638
640
|
|
639
641
|
# Set Headers
|
640
642
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -689,8 +691,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
689
691
|
# will be added to the HTTP request.
|
690
692
|
#
|
691
693
|
#
|
692
|
-
def begin_execute(resource_group_name, lab_name, name, custom_headers
|
693
|
-
response = begin_execute_async(resource_group_name, lab_name, name, custom_headers).value!
|
694
|
+
def begin_execute(resource_group_name, lab_name, name, custom_headers:nil)
|
695
|
+
response = begin_execute_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
694
696
|
nil
|
695
697
|
end
|
696
698
|
|
@@ -705,8 +707,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
705
707
|
#
|
706
708
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
707
709
|
#
|
708
|
-
def begin_execute_with_http_info(resource_group_name, lab_name, name, custom_headers
|
709
|
-
begin_execute_async(resource_group_name, lab_name, name, custom_headers).value!
|
710
|
+
def begin_execute_with_http_info(resource_group_name, lab_name, name, custom_headers:nil)
|
711
|
+
begin_execute_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
710
712
|
end
|
711
713
|
|
712
714
|
#
|
@@ -720,7 +722,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
720
722
|
#
|
721
723
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
722
724
|
#
|
723
|
-
def begin_execute_async(resource_group_name, lab_name, name, custom_headers
|
725
|
+
def begin_execute_async(resource_group_name, lab_name, name, custom_headers:nil)
|
724
726
|
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
725
727
|
fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil?
|
726
728
|
fail ArgumentError, 'lab_name is nil' if lab_name.nil?
|
@@ -729,6 +731,7 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
729
731
|
|
730
732
|
|
731
733
|
request_headers = {}
|
734
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
732
735
|
|
733
736
|
# Set Headers
|
734
737
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -773,8 +776,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
773
776
|
#
|
774
777
|
# @return [ResponseWithContinuationSchedule] operation results.
|
775
778
|
#
|
776
|
-
def list_next(next_page_link, custom_headers
|
777
|
-
response = list_next_async(next_page_link, custom_headers).value!
|
779
|
+
def list_next(next_page_link, custom_headers:nil)
|
780
|
+
response = list_next_async(next_page_link, custom_headers:custom_headers).value!
|
778
781
|
response.body unless response.nil?
|
779
782
|
end
|
780
783
|
|
@@ -788,8 +791,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
788
791
|
#
|
789
792
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
790
793
|
#
|
791
|
-
def list_next_with_http_info(next_page_link, custom_headers
|
792
|
-
list_next_async(next_page_link, custom_headers).value!
|
794
|
+
def list_next_with_http_info(next_page_link, custom_headers:nil)
|
795
|
+
list_next_async(next_page_link, custom_headers:custom_headers).value!
|
793
796
|
end
|
794
797
|
|
795
798
|
#
|
@@ -802,11 +805,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
802
805
|
#
|
803
806
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
804
807
|
#
|
805
|
-
def list_next_async(next_page_link, custom_headers
|
808
|
+
def list_next_async(next_page_link, custom_headers:nil)
|
806
809
|
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
|
807
810
|
|
808
811
|
|
809
812
|
request_headers = {}
|
813
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
810
814
|
|
811
815
|
# Set Headers
|
812
816
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -860,8 +864,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
860
864
|
#
|
861
865
|
# @return [ResponseWithContinuationSchedule] operation results.
|
862
866
|
#
|
863
|
-
def list_applicable_next(next_page_link, custom_headers
|
864
|
-
response = list_applicable_next_async(next_page_link, custom_headers).value!
|
867
|
+
def list_applicable_next(next_page_link, custom_headers:nil)
|
868
|
+
response = list_applicable_next_async(next_page_link, custom_headers:custom_headers).value!
|
865
869
|
response.body unless response.nil?
|
866
870
|
end
|
867
871
|
|
@@ -875,8 +879,8 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
875
879
|
#
|
876
880
|
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
877
881
|
#
|
878
|
-
def list_applicable_next_with_http_info(next_page_link, custom_headers
|
879
|
-
list_applicable_next_async(next_page_link, custom_headers).value!
|
882
|
+
def list_applicable_next_with_http_info(next_page_link, custom_headers:nil)
|
883
|
+
list_applicable_next_async(next_page_link, custom_headers:custom_headers).value!
|
880
884
|
end
|
881
885
|
|
882
886
|
#
|
@@ -889,11 +893,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
889
893
|
#
|
890
894
|
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
891
895
|
#
|
892
|
-
def list_applicable_next_async(next_page_link, custom_headers
|
896
|
+
def list_applicable_next_async(next_page_link, custom_headers:nil)
|
893
897
|
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
|
894
898
|
|
895
899
|
|
896
900
|
request_headers = {}
|
901
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
897
902
|
|
898
903
|
# Set Headers
|
899
904
|
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
@@ -955,12 +960,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
955
960
|
# @return [ResponseWithContinuationSchedule] which provide lazy access to pages
|
956
961
|
# of the response.
|
957
962
|
#
|
958
|
-
def list_as_lazy(resource_group_name, lab_name, expand
|
959
|
-
response = list_async(resource_group_name, lab_name, expand, filter, top, orderby, custom_headers).value!
|
963
|
+
def list_as_lazy(resource_group_name, lab_name, expand:nil, filter:nil, top:nil, orderby:nil, custom_headers:nil)
|
964
|
+
response = list_async(resource_group_name, lab_name, expand:expand, filter:filter, top:top, orderby:orderby, custom_headers:custom_headers).value!
|
960
965
|
unless response.nil?
|
961
966
|
page = response.body
|
962
967
|
page.next_method = Proc.new do |next_page_link|
|
963
|
-
list_next_async(next_page_link, custom_headers)
|
968
|
+
list_next_async(next_page_link, custom_headers:custom_headers)
|
964
969
|
end
|
965
970
|
page
|
966
971
|
end
|
@@ -978,12 +983,12 @@ module Azure::DevTestLabs::Mgmt::V2016_05_15
|
|
978
983
|
# @return [ResponseWithContinuationSchedule] which provide lazy access to pages
|
979
984
|
# of the response.
|
980
985
|
#
|
981
|
-
def list_applicable_as_lazy(resource_group_name, lab_name, name, custom_headers
|
982
|
-
response = list_applicable_async(resource_group_name, lab_name, name, custom_headers).value!
|
986
|
+
def list_applicable_as_lazy(resource_group_name, lab_name, name, custom_headers:nil)
|
987
|
+
response = list_applicable_async(resource_group_name, lab_name, name, custom_headers:custom_headers).value!
|
983
988
|
unless response.nil?
|
984
989
|
page = response.body
|
985
990
|
page.next_method = Proc.new do |next_page_link|
|
986
|
-
list_applicable_next_async(next_page_link, custom_headers)
|
991
|
+
list_applicable_next_async(next_page_link, custom_headers:custom_headers)
|
987
992
|
end
|
988
993
|
page
|
989
994
|
end
|