azure_mgmt_authorization 0.16.0 → 0.16.1
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/2015-06-01/generated/azure_mgmt_authorization/authorization_management_client.rb +130 -0
- data/lib/2015-06-01/generated/azure_mgmt_authorization/classic_administrators.rb +228 -0
- data/lib/2015-06-01/generated/azure_mgmt_authorization/models/classic_administrator.rb +90 -0
- data/lib/2015-06-01/generated/azure_mgmt_authorization/models/classic_administrator_list_result.rb +98 -0
- data/lib/2015-06-01/generated/azure_mgmt_authorization/module_definition.rb +9 -0
- data/lib/2015-06-01/generated/azure_mgmt_authorization.rb +30 -0
- data/lib/2015-07-01/generated/azure_mgmt_authorization/authorization_management_client.rb +1 -1
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/authorization_management_client.rb +130 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/models/role_assignment.rb +115 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/models/role_assignment_create_parameters.rb +71 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/models/role_assignment_filter.rb +57 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/models/role_assignment_list_result.rb +98 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/module_definition.rb +9 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization/role_assignments.rb +1493 -0
- data/lib/2017-10-01-preview/generated/azure_mgmt_authorization.rb +32 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/authorization_management_client.rb +143 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/permission.rb +111 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/permission_get_result.rb +98 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/provider_operation.rb +101 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/provider_operations_metadata.rb +119 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/provider_operations_metadata_list_result.rb +98 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/resource_type.rb +77 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_assignment.rb +115 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_assignment_create_parameters.rb +71 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_assignment_filter.rb +57 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_assignment_list_result.rb +98 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_definition.rb +143 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_definition_filter.rb +57 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/models/role_definition_list_result.rb +98 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/module_definition.rb +9 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/permissions.rb +452 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/provider_operations_metadata_operations.rb +316 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/role_assignments.rb +1493 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization/role_definitions.rb +622 -0
- data/lib/2018-01-01-preview/generated/azure_mgmt_authorization.rb +44 -0
- data/lib/azure_mgmt_authorization.rb +3 -0
- data/lib/profiles/latest/modules/authorization_profile_module.rb +63 -71
- data/lib/version.rb +1 -1
- metadata +36 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 76694e92a51280610f50a89dc4ca16593758ffdf
|
4
|
+
data.tar.gz: 51b1a63180c5257c8e1517f409042cec80d56433
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 19a37dd89014c552dbd0d7f2a716e1ca96167785d0b6b0fb2ff9df2a5bbd162cc23f05a383fc42106a6a52b3adf4ddcc477af39fe2888ebfe30ee8b5e10b980d
|
7
|
+
data.tar.gz: fc49589db060b1fa4ce13db8600b985bae6624365c36833bbfe642f9b0ff8274e29b243fe94087ea62ffe4ead010b442bd771c250d86822308264b0e524656be
|
@@ -0,0 +1,130 @@
|
|
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::Authorization::Mgmt::V2015_06_01
|
7
|
+
#
|
8
|
+
# A service client - single point of access to the REST API.
|
9
|
+
#
|
10
|
+
class AuthorizationManagementClient < MsRestAzure::AzureServiceClient
|
11
|
+
include MsRestAzure
|
12
|
+
include MsRestAzure::Serialization
|
13
|
+
|
14
|
+
# @return [String] the base URI of the service.
|
15
|
+
attr_accessor :base_url
|
16
|
+
|
17
|
+
# @return Credentials needed for the client to connect to Azure.
|
18
|
+
attr_reader :credentials
|
19
|
+
|
20
|
+
# @return [String] The ID of the target subscription.
|
21
|
+
attr_accessor :subscription_id
|
22
|
+
|
23
|
+
# @return [String] The API version to use for this operation.
|
24
|
+
attr_reader :api_version
|
25
|
+
|
26
|
+
# @return [String] Gets or sets the preferred language for the response.
|
27
|
+
attr_accessor :accept_language
|
28
|
+
|
29
|
+
# @return [Integer] Gets or sets the retry timeout in seconds for Long
|
30
|
+
# Running Operations. Default value is 30.
|
31
|
+
attr_accessor :long_running_operation_retry_timeout
|
32
|
+
|
33
|
+
# @return [Boolean] When set to true a unique x-ms-client-request-id value
|
34
|
+
# is generated and included in each request. Default is true.
|
35
|
+
attr_accessor :generate_client_request_id
|
36
|
+
|
37
|
+
# @return [ClassicAdministrators] classic_administrators
|
38
|
+
attr_reader :classic_administrators
|
39
|
+
|
40
|
+
#
|
41
|
+
# Creates initializes a new instance of the AuthorizationManagementClient class.
|
42
|
+
# @param credentials [MsRest::ServiceClientCredentials] credentials to authorize HTTP requests made by the service client.
|
43
|
+
# @param base_url [String] the base URI of the service.
|
44
|
+
# @param options [Array] filters to be applied to the HTTP requests.
|
45
|
+
#
|
46
|
+
def initialize(credentials = nil, base_url = nil, options = nil)
|
47
|
+
super(credentials, options)
|
48
|
+
@base_url = base_url || 'https://management.azure.com'
|
49
|
+
|
50
|
+
fail ArgumentError, 'invalid type of credentials input parameter' unless credentials.is_a?(MsRest::ServiceClientCredentials) unless credentials.nil?
|
51
|
+
@credentials = credentials
|
52
|
+
|
53
|
+
@classic_administrators = ClassicAdministrators.new(self)
|
54
|
+
@api_version = '2015-06-01'
|
55
|
+
@accept_language = 'en-US'
|
56
|
+
@long_running_operation_retry_timeout = 30
|
57
|
+
@generate_client_request_id = true
|
58
|
+
add_telemetry
|
59
|
+
end
|
60
|
+
|
61
|
+
#
|
62
|
+
# Makes a request and returns the body of the response.
|
63
|
+
# @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
|
64
|
+
# @param path [String] the path, relative to {base_url}.
|
65
|
+
# @param options [Hash{String=>String}] specifying any request options like :body.
|
66
|
+
# @return [Hash{String=>String}] containing the body of the response.
|
67
|
+
# Example:
|
68
|
+
#
|
69
|
+
# request_content = "{'location':'westus','tags':{'tag1':'val1','tag2':'val2'}}"
|
70
|
+
# path = "/path"
|
71
|
+
# options = {
|
72
|
+
# body: request_content,
|
73
|
+
# query_params: {'api-version' => '2016-02-01'}
|
74
|
+
# }
|
75
|
+
# result = @client.make_request(:put, path, options)
|
76
|
+
#
|
77
|
+
def make_request(method, path, options = {})
|
78
|
+
result = make_request_with_http_info(method, path, options)
|
79
|
+
result.body unless result.nil?
|
80
|
+
end
|
81
|
+
|
82
|
+
#
|
83
|
+
# Makes a request and returns the operation response.
|
84
|
+
# @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
|
85
|
+
# @param path [String] the path, relative to {base_url}.
|
86
|
+
# @param options [Hash{String=>String}] specifying any request options like :body.
|
87
|
+
# @return [MsRestAzure::AzureOperationResponse] Operation response containing the request, response and status.
|
88
|
+
#
|
89
|
+
def make_request_with_http_info(method, path, options = {})
|
90
|
+
result = make_request_async(method, path, options).value!
|
91
|
+
result.body = result.response.body.to_s.empty? ? nil : JSON.load(result.response.body)
|
92
|
+
result
|
93
|
+
end
|
94
|
+
|
95
|
+
#
|
96
|
+
# Makes a request asynchronously.
|
97
|
+
# @param method [Symbol] with any of the following values :get, :put, :post, :patch, :delete.
|
98
|
+
# @param path [String] the path, relative to {base_url}.
|
99
|
+
# @param options [Hash{String=>String}] specifying any request options like :body.
|
100
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
101
|
+
#
|
102
|
+
def make_request_async(method, path, options = {})
|
103
|
+
fail ArgumentError, 'method is nil' if method.nil?
|
104
|
+
fail ArgumentError, 'path is nil' if path.nil?
|
105
|
+
|
106
|
+
request_url = options[:base_url] || @base_url
|
107
|
+
if(!options[:headers].nil? && !options[:headers]['Content-Type'].nil?)
|
108
|
+
@request_headers['Content-Type'] = options[:headers]['Content-Type']
|
109
|
+
end
|
110
|
+
|
111
|
+
request_headers = @request_headers
|
112
|
+
request_headers.merge!({'accept-language' => @accept_language}) unless @accept_language.nil?
|
113
|
+
options.merge!({headers: request_headers.merge(options[:headers] || {})})
|
114
|
+
options.merge!({credentials: @credentials}) unless @credentials.nil?
|
115
|
+
|
116
|
+
super(request_url, method, path, options)
|
117
|
+
end
|
118
|
+
|
119
|
+
|
120
|
+
private
|
121
|
+
#
|
122
|
+
# Adds telemetry information.
|
123
|
+
#
|
124
|
+
def add_telemetry
|
125
|
+
sdk_information = 'azure_mgmt_authorization'
|
126
|
+
sdk_information = "#{sdk_information}/0.16.1"
|
127
|
+
add_user_agent_information(sdk_information)
|
128
|
+
end
|
129
|
+
end
|
130
|
+
end
|
@@ -0,0 +1,228 @@
|
|
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::Authorization::Mgmt::V2015_06_01
|
7
|
+
#
|
8
|
+
# Role based access control provides you a way to apply granular level policy
|
9
|
+
# administration down to individual resources or resource groups. These
|
10
|
+
# operations enable you to manage role definitions and role assignments. A
|
11
|
+
# role definition describes the set of actions that can be performed on
|
12
|
+
# resources. A role assignment grants access to Azure Active Directory users.
|
13
|
+
#
|
14
|
+
class ClassicAdministrators
|
15
|
+
include MsRestAzure
|
16
|
+
|
17
|
+
#
|
18
|
+
# Creates and initializes a new instance of the ClassicAdministrators class.
|
19
|
+
# @param client service class for accessing basic functionality.
|
20
|
+
#
|
21
|
+
def initialize(client)
|
22
|
+
@client = client
|
23
|
+
end
|
24
|
+
|
25
|
+
# @return [AuthorizationManagementClient] reference to the AuthorizationManagementClient
|
26
|
+
attr_reader :client
|
27
|
+
|
28
|
+
#
|
29
|
+
# Gets service administrator, account administrator, and co-administrators for
|
30
|
+
# the subscription.
|
31
|
+
#
|
32
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
33
|
+
# will be added to the HTTP request.
|
34
|
+
#
|
35
|
+
# @return [Array<ClassicAdministrator>] operation results.
|
36
|
+
#
|
37
|
+
def list(custom_headers:nil)
|
38
|
+
first_page = list_as_lazy(custom_headers:custom_headers)
|
39
|
+
first_page.get_all_items
|
40
|
+
end
|
41
|
+
|
42
|
+
#
|
43
|
+
# Gets service administrator, account administrator, and co-administrators for
|
44
|
+
# the subscription.
|
45
|
+
#
|
46
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
47
|
+
# will be added to the HTTP request.
|
48
|
+
#
|
49
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
50
|
+
#
|
51
|
+
def list_with_http_info(custom_headers:nil)
|
52
|
+
list_async(custom_headers:custom_headers).value!
|
53
|
+
end
|
54
|
+
|
55
|
+
#
|
56
|
+
# Gets service administrator, account administrator, and co-administrators for
|
57
|
+
# the subscription.
|
58
|
+
#
|
59
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
60
|
+
# to the HTTP request.
|
61
|
+
#
|
62
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
63
|
+
#
|
64
|
+
def list_async(custom_headers:nil)
|
65
|
+
fail ArgumentError, '@client.api_version is nil' if @client.api_version.nil?
|
66
|
+
fail ArgumentError, '@client.subscription_id is nil' if @client.subscription_id.nil?
|
67
|
+
|
68
|
+
|
69
|
+
request_headers = {}
|
70
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
71
|
+
|
72
|
+
# Set Headers
|
73
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
74
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
75
|
+
path_template = 'subscriptions/{subscriptionId}/providers/Microsoft.Authorization/classicAdministrators'
|
76
|
+
|
77
|
+
request_url = @base_url || @client.base_url
|
78
|
+
|
79
|
+
options = {
|
80
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
81
|
+
path_params: {'subscriptionId' => @client.subscription_id},
|
82
|
+
query_params: {'api-version' => @client.api_version},
|
83
|
+
headers: request_headers.merge(custom_headers || {}),
|
84
|
+
base_url: request_url
|
85
|
+
}
|
86
|
+
promise = @client.make_request_async(:get, path_template, options)
|
87
|
+
|
88
|
+
promise = promise.then do |result|
|
89
|
+
http_response = result.response
|
90
|
+
status_code = http_response.status
|
91
|
+
response_content = http_response.body
|
92
|
+
unless status_code == 200
|
93
|
+
error_model = JSON.load(response_content)
|
94
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
95
|
+
end
|
96
|
+
|
97
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
98
|
+
# Deserialize Response
|
99
|
+
if status_code == 200
|
100
|
+
begin
|
101
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
102
|
+
result_mapper = Azure::Authorization::Mgmt::V2015_06_01::Models::ClassicAdministratorListResult.mapper()
|
103
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
104
|
+
rescue Exception => e
|
105
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
106
|
+
end
|
107
|
+
end
|
108
|
+
|
109
|
+
result
|
110
|
+
end
|
111
|
+
|
112
|
+
promise.execute
|
113
|
+
end
|
114
|
+
|
115
|
+
#
|
116
|
+
# Gets service administrator, account administrator, and co-administrators for
|
117
|
+
# the subscription.
|
118
|
+
#
|
119
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
120
|
+
# to List operation.
|
121
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
122
|
+
# will be added to the HTTP request.
|
123
|
+
#
|
124
|
+
# @return [ClassicAdministratorListResult] operation results.
|
125
|
+
#
|
126
|
+
def list_next(next_page_link, custom_headers:nil)
|
127
|
+
response = list_next_async(next_page_link, custom_headers:custom_headers).value!
|
128
|
+
response.body unless response.nil?
|
129
|
+
end
|
130
|
+
|
131
|
+
#
|
132
|
+
# Gets service administrator, account administrator, and co-administrators for
|
133
|
+
# the subscription.
|
134
|
+
#
|
135
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
136
|
+
# to List operation.
|
137
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
138
|
+
# will be added to the HTTP request.
|
139
|
+
#
|
140
|
+
# @return [MsRestAzure::AzureOperationResponse] HTTP response information.
|
141
|
+
#
|
142
|
+
def list_next_with_http_info(next_page_link, custom_headers:nil)
|
143
|
+
list_next_async(next_page_link, custom_headers:custom_headers).value!
|
144
|
+
end
|
145
|
+
|
146
|
+
#
|
147
|
+
# Gets service administrator, account administrator, and co-administrators for
|
148
|
+
# the subscription.
|
149
|
+
#
|
150
|
+
# @param next_page_link [String] The NextLink from the previous successful call
|
151
|
+
# to List operation.
|
152
|
+
# @param [Hash{String => String}] A hash of custom headers that will be added
|
153
|
+
# to the HTTP request.
|
154
|
+
#
|
155
|
+
# @return [Concurrent::Promise] Promise object which holds the HTTP response.
|
156
|
+
#
|
157
|
+
def list_next_async(next_page_link, custom_headers:nil)
|
158
|
+
fail ArgumentError, 'next_page_link is nil' if next_page_link.nil?
|
159
|
+
|
160
|
+
|
161
|
+
request_headers = {}
|
162
|
+
request_headers['Content-Type'] = 'application/json; charset=utf-8'
|
163
|
+
|
164
|
+
# Set Headers
|
165
|
+
request_headers['x-ms-client-request-id'] = SecureRandom.uuid
|
166
|
+
request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil?
|
167
|
+
path_template = '{nextLink}'
|
168
|
+
|
169
|
+
request_url = @base_url || @client.base_url
|
170
|
+
|
171
|
+
options = {
|
172
|
+
middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]],
|
173
|
+
skip_encoding_path_params: {'nextLink' => next_page_link},
|
174
|
+
headers: request_headers.merge(custom_headers || {}),
|
175
|
+
base_url: request_url
|
176
|
+
}
|
177
|
+
promise = @client.make_request_async(:get, path_template, options)
|
178
|
+
|
179
|
+
promise = promise.then do |result|
|
180
|
+
http_response = result.response
|
181
|
+
status_code = http_response.status
|
182
|
+
response_content = http_response.body
|
183
|
+
unless status_code == 200
|
184
|
+
error_model = JSON.load(response_content)
|
185
|
+
fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model)
|
186
|
+
end
|
187
|
+
|
188
|
+
result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil?
|
189
|
+
# Deserialize Response
|
190
|
+
if status_code == 200
|
191
|
+
begin
|
192
|
+
parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content)
|
193
|
+
result_mapper = Azure::Authorization::Mgmt::V2015_06_01::Models::ClassicAdministratorListResult.mapper()
|
194
|
+
result.body = @client.deserialize(result_mapper, parsed_response)
|
195
|
+
rescue Exception => e
|
196
|
+
fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e.message, e.backtrace, result)
|
197
|
+
end
|
198
|
+
end
|
199
|
+
|
200
|
+
result
|
201
|
+
end
|
202
|
+
|
203
|
+
promise.execute
|
204
|
+
end
|
205
|
+
|
206
|
+
#
|
207
|
+
# Gets service administrator, account administrator, and co-administrators for
|
208
|
+
# the subscription.
|
209
|
+
#
|
210
|
+
# @param custom_headers [Hash{String => String}] A hash of custom headers that
|
211
|
+
# will be added to the HTTP request.
|
212
|
+
#
|
213
|
+
# @return [ClassicAdministratorListResult] which provide lazy access to pages
|
214
|
+
# of the response.
|
215
|
+
#
|
216
|
+
def list_as_lazy(custom_headers:nil)
|
217
|
+
response = list_async(custom_headers:custom_headers).value!
|
218
|
+
unless response.nil?
|
219
|
+
page = response.body
|
220
|
+
page.next_method = Proc.new do |next_page_link|
|
221
|
+
list_next_async(next_page_link, custom_headers:custom_headers)
|
222
|
+
end
|
223
|
+
page
|
224
|
+
end
|
225
|
+
end
|
226
|
+
|
227
|
+
end
|
228
|
+
end
|
@@ -0,0 +1,90 @@
|
|
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::Authorization::Mgmt::V2015_06_01
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# Classic Administrators
|
10
|
+
#
|
11
|
+
class ClassicAdministrator
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
# @return [String] The ID of the administrator.
|
16
|
+
attr_accessor :id
|
17
|
+
|
18
|
+
# @return [String] The name of the administrator.
|
19
|
+
attr_accessor :name
|
20
|
+
|
21
|
+
# @return [String] The type of the administrator.
|
22
|
+
attr_accessor :type
|
23
|
+
|
24
|
+
# @return [String] The email address of the administrator.
|
25
|
+
attr_accessor :email_address
|
26
|
+
|
27
|
+
# @return [String] The role of the administrator.
|
28
|
+
attr_accessor :role
|
29
|
+
|
30
|
+
|
31
|
+
#
|
32
|
+
# Mapper for ClassicAdministrator class as Ruby Hash.
|
33
|
+
# This will be used for serialization/deserialization.
|
34
|
+
#
|
35
|
+
def self.mapper()
|
36
|
+
{
|
37
|
+
client_side_validation: true,
|
38
|
+
required: false,
|
39
|
+
serialized_name: 'ClassicAdministrator',
|
40
|
+
type: {
|
41
|
+
name: 'Composite',
|
42
|
+
class_name: 'ClassicAdministrator',
|
43
|
+
model_properties: {
|
44
|
+
id: {
|
45
|
+
client_side_validation: true,
|
46
|
+
required: false,
|
47
|
+
serialized_name: 'id',
|
48
|
+
type: {
|
49
|
+
name: 'String'
|
50
|
+
}
|
51
|
+
},
|
52
|
+
name: {
|
53
|
+
client_side_validation: true,
|
54
|
+
required: false,
|
55
|
+
serialized_name: 'name',
|
56
|
+
type: {
|
57
|
+
name: 'String'
|
58
|
+
}
|
59
|
+
},
|
60
|
+
type: {
|
61
|
+
client_side_validation: true,
|
62
|
+
required: false,
|
63
|
+
serialized_name: 'type',
|
64
|
+
type: {
|
65
|
+
name: 'String'
|
66
|
+
}
|
67
|
+
},
|
68
|
+
email_address: {
|
69
|
+
client_side_validation: true,
|
70
|
+
required: false,
|
71
|
+
serialized_name: 'properties.emailAddress',
|
72
|
+
type: {
|
73
|
+
name: 'String'
|
74
|
+
}
|
75
|
+
},
|
76
|
+
role: {
|
77
|
+
client_side_validation: true,
|
78
|
+
required: false,
|
79
|
+
serialized_name: 'properties.role',
|
80
|
+
type: {
|
81
|
+
name: 'String'
|
82
|
+
}
|
83
|
+
}
|
84
|
+
}
|
85
|
+
}
|
86
|
+
}
|
87
|
+
end
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
data/lib/2015-06-01/generated/azure_mgmt_authorization/models/classic_administrator_list_result.rb
ADDED
@@ -0,0 +1,98 @@
|
|
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::Authorization::Mgmt::V2015_06_01
|
7
|
+
module Models
|
8
|
+
#
|
9
|
+
# ClassicAdministrator list result information.
|
10
|
+
#
|
11
|
+
class ClassicAdministratorListResult
|
12
|
+
|
13
|
+
include MsRestAzure
|
14
|
+
|
15
|
+
include MsRest::JSONable
|
16
|
+
# @return [Array<ClassicAdministrator>] An array of administrators.
|
17
|
+
attr_accessor :value
|
18
|
+
|
19
|
+
# @return [String] The URL to use for getting the next set of results.
|
20
|
+
attr_accessor :next_link
|
21
|
+
|
22
|
+
# return [Proc] with next page method call.
|
23
|
+
attr_accessor :next_method
|
24
|
+
|
25
|
+
#
|
26
|
+
# Gets the rest of the items for the request, enabling auto-pagination.
|
27
|
+
#
|
28
|
+
# @return [Array<ClassicAdministrator>] operation results.
|
29
|
+
#
|
30
|
+
def get_all_items
|
31
|
+
items = @value
|
32
|
+
page = self
|
33
|
+
while page.next_link != nil do
|
34
|
+
page = page.get_next_page
|
35
|
+
items.concat(page.value)
|
36
|
+
end
|
37
|
+
items
|
38
|
+
end
|
39
|
+
|
40
|
+
#
|
41
|
+
# Gets the next page of results.
|
42
|
+
#
|
43
|
+
# @return [ClassicAdministratorListResult] with next page content.
|
44
|
+
#
|
45
|
+
def get_next_page
|
46
|
+
response = @next_method.call(@next_link).value! unless @next_method.nil?
|
47
|
+
unless response.nil?
|
48
|
+
@next_link = response.body.next_link
|
49
|
+
@value = response.body.value
|
50
|
+
self
|
51
|
+
end
|
52
|
+
end
|
53
|
+
|
54
|
+
#
|
55
|
+
# Mapper for ClassicAdministratorListResult class as Ruby Hash.
|
56
|
+
# This will be used for serialization/deserialization.
|
57
|
+
#
|
58
|
+
def self.mapper()
|
59
|
+
{
|
60
|
+
client_side_validation: true,
|
61
|
+
required: false,
|
62
|
+
serialized_name: 'ClassicAdministratorListResult',
|
63
|
+
type: {
|
64
|
+
name: 'Composite',
|
65
|
+
class_name: 'ClassicAdministratorListResult',
|
66
|
+
model_properties: {
|
67
|
+
value: {
|
68
|
+
client_side_validation: true,
|
69
|
+
required: false,
|
70
|
+
serialized_name: 'value',
|
71
|
+
type: {
|
72
|
+
name: 'Sequence',
|
73
|
+
element: {
|
74
|
+
client_side_validation: true,
|
75
|
+
required: false,
|
76
|
+
serialized_name: 'ClassicAdministratorElementType',
|
77
|
+
type: {
|
78
|
+
name: 'Composite',
|
79
|
+
class_name: 'ClassicAdministrator'
|
80
|
+
}
|
81
|
+
}
|
82
|
+
}
|
83
|
+
},
|
84
|
+
next_link: {
|
85
|
+
client_side_validation: true,
|
86
|
+
required: false,
|
87
|
+
serialized_name: 'nextLink',
|
88
|
+
type: {
|
89
|
+
name: 'String'
|
90
|
+
}
|
91
|
+
}
|
92
|
+
}
|
93
|
+
}
|
94
|
+
}
|
95
|
+
end
|
96
|
+
end
|
97
|
+
end
|
98
|
+
end
|
@@ -0,0 +1,9 @@
|
|
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 end
|
7
|
+
module Azure::Authorization end
|
8
|
+
module Azure::Authorization::Mgmt end
|
9
|
+
module Azure::Authorization::Mgmt::V2015_06_01 end
|
@@ -0,0 +1,30 @@
|
|
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
|
+
require 'uri'
|
7
|
+
require 'cgi'
|
8
|
+
require 'date'
|
9
|
+
require 'json'
|
10
|
+
require 'base64'
|
11
|
+
require 'erb'
|
12
|
+
require 'securerandom'
|
13
|
+
require 'time'
|
14
|
+
require 'timeliness'
|
15
|
+
require 'faraday'
|
16
|
+
require 'faraday-cookie_jar'
|
17
|
+
require 'concurrent'
|
18
|
+
require 'ms_rest'
|
19
|
+
require '2015-06-01/generated/azure_mgmt_authorization/module_definition'
|
20
|
+
require 'ms_rest_azure'
|
21
|
+
|
22
|
+
module Azure::Authorization::Mgmt::V2015_06_01
|
23
|
+
autoload :ClassicAdministrators, '2015-06-01/generated/azure_mgmt_authorization/classic_administrators.rb'
|
24
|
+
autoload :AuthorizationManagementClient, '2015-06-01/generated/azure_mgmt_authorization/authorization_management_client.rb'
|
25
|
+
|
26
|
+
module Models
|
27
|
+
autoload :ClassicAdministratorListResult, '2015-06-01/generated/azure_mgmt_authorization/models/classic_administrator_list_result.rb'
|
28
|
+
autoload :ClassicAdministrator, '2015-06-01/generated/azure_mgmt_authorization/models/classic_administrator.rb'
|
29
|
+
end
|
30
|
+
end
|
@@ -140,7 +140,7 @@ module Azure::Authorization::Mgmt::V2015_07_01
|
|
140
140
|
#
|
141
141
|
def add_telemetry
|
142
142
|
sdk_information = 'azure_mgmt_authorization'
|
143
|
-
sdk_information = "#{sdk_information}/0.16.
|
143
|
+
sdk_information = "#{sdk_information}/0.16.1"
|
144
144
|
add_user_agent_information(sdk_information)
|
145
145
|
end
|
146
146
|
end
|