Class: Azure::ARM::DataLakeStore::Account
- Inherits:
-
Object
- Object
- Azure::ARM::DataLakeStore::Account
- Includes:
- MsRestAzure
- Defined in:
- lib/generated/azure_mgmt_datalake_store/account.rb
Overview
Creates an Azure Data Lake Store account management client.
Instance Attribute Summary collapse
-
#client ⇒ DataLakeStoreAccountManagementClient
readonly
Reference to the DataLakeStoreAccountManagementClient.
Instance Method Summary collapse
-
#begin_create(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Creates the specified Data Lake Store account.
-
#begin_create_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
Creates the specified Data Lake Store account.
-
#begin_create_with_http_info(resource_group_name, name, parameters, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Creates the specified Data Lake Store account.
-
#begin_delete(resource_group_name, name, custom_headers = nil) ⇒ Object
Deletes the specified Data Lake Store account.
-
#begin_delete_async(resource_group_name, name, custom_headers = nil) ⇒ Concurrent::Promise
Deletes the specified Data Lake Store account.
-
#begin_delete_with_http_info(resource_group_name, name, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Deletes the specified Data Lake Store account.
-
#begin_update(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Updates the specified Data Lake Store account information.
-
#begin_update_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
Updates the specified Data Lake Store account information.
-
#begin_update_with_http_info(resource_group_name, name, parameters, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Updates the specified Data Lake Store account information.
-
#create(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Creates the specified Data Lake Store account.
-
#create_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
contains the Data Lake Store account.
-
#delete(resource_group_name, name, custom_headers = nil) ⇒ Object
Deletes the specified Data Lake Store account.
-
#delete_async(resource_group_name, name, custom_headers = nil) ⇒ Concurrent::Promise
contains the Data Lake Store account.
-
#enable_key_vault(resource_group_name, account_name, custom_headers = nil) ⇒ Object
Attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
-
#enable_key_vault_async(resource_group_name, account_name, custom_headers = nil) ⇒ Concurrent::Promise
Attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
-
#enable_key_vault_with_http_info(resource_group_name, account_name, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
-
#get(resource_group_name, name, custom_headers = nil) ⇒ DataLakeStoreAccount
Gets the specified Data Lake Store account.
-
#get_async(resource_group_name, name, custom_headers = nil) ⇒ Concurrent::Promise
Gets the specified Data Lake Store account.
-
#get_with_http_info(resource_group_name, name, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Gets the specified Data Lake Store account.
-
#initialize(client) ⇒ Account
constructor
Creates and initializes a new instance of the Account class.
-
#list(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Array<DataLakeStoreAccountBasic>
Lists the Data Lake Store accounts within the subscription.
-
#list_as_lazy(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within the subscription.
-
#list_async(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within the subscription.
-
#list_by_resource_group(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Array<DataLakeStoreAccountBasic>
Lists the Data Lake Store accounts within a specific resource group.
-
#list_by_resource_group_as_lazy(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within a specific resource group.
-
#list_by_resource_group_async(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within a specific resource group.
-
#list_by_resource_group_next(next_page_link, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within a specific resource group.
-
#list_by_resource_group_next_async(next_page_link, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within a specific resource group.
-
#list_by_resource_group_next_with_http_info(next_page_link, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within a specific resource group.
-
#list_by_resource_group_with_http_info(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within a specific resource group.
-
#list_next(next_page_link, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within the subscription.
-
#list_next_async(next_page_link, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within the subscription.
-
#list_next_with_http_info(next_page_link, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within the subscription.
-
#list_with_http_info(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within the subscription.
-
#update(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Updates the specified Data Lake Store account information.
-
#update_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
contains the Data Lake Store account.
Constructor Details
#initialize(client) ⇒ Account
Creates and initializes a new instance of the Account class.
17 18 19 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 17 def initialize(client) @client = client end |
Instance Attribute Details
#client ⇒ DataLakeStoreAccountManagementClient (readonly)
Returns reference to the DataLakeStoreAccountManagementClient.
22 23 24 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 22 def client @client end |
Instance Method Details
#begin_create(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Creates the specified Data Lake Store account.
contains the Data Lake Store account. Data Lake Store account. will be added to the HTTP request.
619 620 621 622 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 619 def begin_create(resource_group_name, name, parameters, custom_headers = nil) response = begin_create_async(resource_group_name, name, parameters, custom_headers).value! response.body unless response.nil? end |
#begin_create_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
Creates the specified Data Lake Store account.
contains the Data Lake Store account. Data Lake Store account. to the HTTP request.
654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 654 def begin_create_async(resource_group_name, name, parameters, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'parameters is nil' if parameters.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 = {} # 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::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() request_content = @client.serialize(request_mapper, parameters) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{name}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:put, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 201 || status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 201 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#begin_create_with_http_info(resource_group_name, name, parameters, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Creates the specified Data Lake Store account.
contains the Data Lake Store account. Data Lake Store account. will be added to the HTTP request.
637 638 639 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 637 def begin_create_with_http_info(resource_group_name, name, parameters, custom_headers = nil) begin_create_async(resource_group_name, name, parameters, custom_headers).value! end |
#begin_delete(resource_group_name, name, custom_headers = nil) ⇒ Object
Deletes the specified Data Lake Store account.
contains the Data Lake Store account. will be added to the HTTP request.
856 857 858 859 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 856 def begin_delete(resource_group_name, name, custom_headers = nil) response = begin_delete_async(resource_group_name, name, custom_headers).value! nil end |
#begin_delete_async(resource_group_name, name, custom_headers = nil) ⇒ Concurrent::Promise
Deletes the specified Data Lake Store account.
contains the Data Lake Store account. to the HTTP request.
887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 887 def begin_delete_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if 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 = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{name}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:delete, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 || status_code == 204 || status_code == 202 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result end promise.execute end |
#begin_delete_with_http_info(resource_group_name, name, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Deletes the specified Data Lake Store account.
contains the Data Lake Store account. will be added to the HTTP request.
872 873 874 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 872 def begin_delete_with_http_info(resource_group_name, name, custom_headers = nil) begin_delete_async(resource_group_name, name, custom_headers).value! end |
#begin_update(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Updates the specified Data Lake Store account information.
contains the Data Lake Store account. to update the Data Lake Store account. will be added to the HTTP request.
739 740 741 742 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 739 def begin_update(resource_group_name, name, parameters, custom_headers = nil) response = begin_update_async(resource_group_name, name, parameters, custom_headers).value! response.body unless response.nil? end |
#begin_update_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
Updates the specified Data Lake Store account information.
contains the Data Lake Store account. to update the Data Lake Store account. to the HTTP request.
774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 774 def begin_update_async(resource_group_name, name, parameters, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if name.nil? fail ArgumentError, 'parameters is nil' if parameters.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 = {} # 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::ARM::DataLakeStore::Models::DataLakeStoreAccountUpdateParameters.mapper() request_content = @client.serialize(request_mapper, parameters) request_content = request_content != nil ? JSON.generate(request_content, quirks_mode: true) : nil path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{name}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => @client.api_version}, body: request_content, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:patch, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 || status_code == 201 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end # Deserialize Response if status_code == 201 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#begin_update_with_http_info(resource_group_name, name, parameters, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Updates the specified Data Lake Store account information.
contains the Data Lake Store account. to update the Data Lake Store account. will be added to the HTTP request.
757 758 759 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 757 def begin_update_with_http_info(resource_group_name, name, parameters, custom_headers = nil) begin_update_async(resource_group_name, name, parameters, custom_headers).value! end |
#create(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Creates the specified Data Lake Store account.
contains the Data Lake Store account. Data Lake Store account. will be added to the HTTP request.
37 38 39 40 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 37 def create(resource_group_name, name, parameters, custom_headers = nil) response = create_async(resource_group_name, name, parameters, custom_headers).value! response.body unless response.nil? end |
#create_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
contains the Data Lake Store account. Data Lake Store account. will be added to the HTTP request.
response.
54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 54 def create_async(resource_group_name, name, parameters, custom_headers = nil) # Send request promise = begin_create_async(resource_group_name, name, parameters, custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#delete(resource_group_name, name, custom_headers = nil) ⇒ Object
Deletes the specified Data Lake Store account.
contains the Data Lake Store account. will be added to the HTTP request.
129 130 131 132 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 129 def delete(resource_group_name, name, custom_headers = nil) response = delete_async(resource_group_name, name, custom_headers).value! nil end |
#delete_async(resource_group_name, name, custom_headers = nil) ⇒ Concurrent::Promise
contains the Data Lake Store account. will be added to the HTTP request.
response.
144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 144 def delete_async(resource_group_name, name, custom_headers = nil) # Send request promise = begin_delete_async(resource_group_name, name, custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |
#enable_key_vault(resource_group_name, account_name, custom_headers = nil) ⇒ Object
Attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
contains the Data Lake Store account. attempt to enable the Key Vault for. will be added to the HTTP request.
266 267 268 269 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 266 def enable_key_vault(resource_group_name, account_name, custom_headers = nil) response = enable_key_vault_async(resource_group_name, account_name, custom_headers).value! nil end |
#enable_key_vault_async(resource_group_name, account_name, custom_headers = nil) ⇒ Concurrent::Promise
Attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
contains the Data Lake Store account. attempt to enable the Key Vault for. to the HTTP request.
301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 301 def enable_key_vault_async(resource_group_name, account_name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'account_name is nil' if account_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 = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/enableKeyVault' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'accountName' => account_name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:post, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? result end promise.execute end |
#enable_key_vault_with_http_info(resource_group_name, account_name, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
contains the Data Lake Store account. attempt to enable the Key Vault for. will be added to the HTTP request.
284 285 286 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 284 def enable_key_vault_with_http_info(resource_group_name, account_name, custom_headers = nil) enable_key_vault_async(resource_group_name, account_name, custom_headers).value! end |
#get(resource_group_name, name, custom_headers = nil) ⇒ DataLakeStoreAccount
Gets the specified Data Lake Store account.
contains the Data Lake Store account. will be added to the HTTP request.
171 172 173 174 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 171 def get(resource_group_name, name, custom_headers = nil) response = get_async(resource_group_name, name, custom_headers).value! response.body unless response.nil? end |
#get_async(resource_group_name, name, custom_headers = nil) ⇒ Concurrent::Promise
Gets the specified Data Lake Store account.
contains the Data Lake Store account. to the HTTP request.
202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 202 def get_async(resource_group_name, name, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_name.nil? fail ArgumentError, 'name is nil' if 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 = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{name}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'name' => name,'subscriptionId' => @client.subscription_id}, query_params: {'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#get_with_http_info(resource_group_name, name, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Gets the specified Data Lake Store account.
contains the Data Lake Store account. will be added to the HTTP request.
187 188 189 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 187 def get_with_http_info(resource_group_name, name, custom_headers = nil) get_async(resource_group_name, name, custom_headers).value! end |
#list(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Array<DataLakeStoreAccountBasic>
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. of the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. will be added to the HTTP request.
501 502 503 504 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 501 def list(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) first_page = list_as_lazy(filter, top, skip, select, orderby, count, custom_headers) first_page.get_all_items end |
#list_as_lazy(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. of the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. will be added to the HTTP request.
of the response.
1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 1170 def list_as_lazy(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) response = list_async(filter, top, skip, select, orderby, count, 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) end page end end |
#list_async(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. of the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. to the HTTP request.
556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 556 def list_async(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = 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 = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/providers/Microsoft.DataLakeStore/accounts' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'subscriptionId' => @client.subscription_id}, query_params: {'$filter' => filter,'$top' => top,'$skip' => skip,'$select' => select,'$orderby' => orderby,'$count' => count,'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccountListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_by_resource_group(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Array<DataLakeStoreAccountBasic>
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
contains the Data Lake Store account(s). elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. will be added to the HTTP request.
368 369 370 371 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 368 def list_by_resource_group(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) first_page = list_by_resource_group_as_lazy(resource_group_name, filter, top, skip, select, orderby, count, custom_headers) first_page.get_all_items end |
#list_by_resource_group_as_lazy(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
contains the Data Lake Store account(s). elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. will be added to the HTTP request.
of the response.
1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 1135 def list_by_resource_group_as_lazy(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) response = list_by_resource_group_async(resource_group_name, filter, top, skip, select, orderby, count, custom_headers).value! unless response.nil? page = response.body page.next_method = Proc.new do |next_page_link| list_by_resource_group_next_async(next_page_link, custom_headers) end page end end |
#list_by_resource_group_async(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
contains the Data Lake Store account(s). elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. to the HTTP request.
427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 427 def list_by_resource_group_async(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) fail ArgumentError, 'resource_group_name is nil' if resource_group_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 = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = 'subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], path_params: {'resourceGroupName' => resource_group_name,'subscriptionId' => @client.subscription_id}, query_params: {'$filter' => filter,'$top' => top,'$skip' => skip,'$select' => select,'$orderby' => orderby,'$count' => count,'api-version' => @client.api_version}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccountListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_by_resource_group_next(next_page_link, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
to List operation. will be added to the HTTP request.
940 941 942 943 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 940 def list_by_resource_group_next(next_page_link, custom_headers = nil) response = list_by_resource_group_next_async(next_page_link, custom_headers).value! response.body unless response.nil? end |
#list_by_resource_group_next_async(next_page_link, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
to List operation. to the HTTP request.
971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 971 def list_by_resource_group_next_async(next_page_link, custom_headers = nil) fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? request_headers = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = '{nextLink}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], skip_encoding_path_params: {'nextLink' => next_page_link}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccountListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_by_resource_group_next_with_http_info(next_page_link, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
to List operation. will be added to the HTTP request.
956 957 958 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 956 def list_by_resource_group_next_with_http_info(next_page_link, custom_headers = nil) list_by_resource_group_next_async(next_page_link, custom_headers).value! end |
#list_by_resource_group_with_http_info(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within a specific resource group. The response includes a link to the next page of results, if any.
contains the Data Lake Store account(s). elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. will be added to the HTTP request.
398 399 400 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 398 def list_by_resource_group_with_http_info(resource_group_name, filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) list_by_resource_group_async(resource_group_name, filter, top, skip, select, orderby, count, custom_headers).value! end |
#list_next(next_page_link, custom_headers = nil) ⇒ DataLakeStoreAccountListResult
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
to List operation. will be added to the HTTP request.
1030 1031 1032 1033 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 1030 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 |
#list_next_async(next_page_link, custom_headers = nil) ⇒ Concurrent::Promise
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
to List operation. to the HTTP request.
1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 1061 def list_next_async(next_page_link, custom_headers = nil) fail ArgumentError, 'next_page_link is nil' if next_page_link.nil? request_headers = {} # Set Headers request_headers['x-ms-client-request-id'] = SecureRandom.uuid request_headers['accept-language'] = @client.accept_language unless @client.accept_language.nil? path_template = '{nextLink}' request_url = @base_url || @client.base_url = { middlewares: [[MsRest::RetryPolicyMiddleware, times: 3, retry: 0.02], [:cookie_jar]], skip_encoding_path_params: {'nextLink' => next_page_link}, headers: request_headers.merge(custom_headers || {}), base_url: request_url } promise = @client.make_request_async(:get, path_template, ) promise = promise.then do |result| http_response = result.response status_code = http_response.status response_content = http_response.body unless status_code == 200 error_model = JSON.load(response_content) fail MsRestAzure::AzureOperationError.new(result.request, http_response, error_model) end result.request_id = http_response['x-ms-request-id'] unless http_response['x-ms-request-id'].nil? # Deserialize Response if status_code == 200 begin parsed_response = response_content.to_s.empty? ? nil : JSON.load(response_content) result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccountListResult.mapper() result.body = @client.deserialize(result_mapper, parsed_response) rescue Exception => e fail MsRest::DeserializationError.new('Error occurred in deserializing the response', e., e.backtrace, result) end end result end promise.execute end |
#list_next_with_http_info(next_page_link, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
to List operation. will be added to the HTTP request.
1046 1047 1048 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 1046 def list_next_with_http_info(next_page_link, custom_headers = nil) list_next_async(next_page_link, custom_headers).value! end |
#list_with_http_info(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) ⇒ MsRestAzure::AzureOperationResponse
Lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of results, if any.
elements. Optional. entry to just those requested, e.g. Categories?$select=CategoryName,Description. Optional. expressions with an optional “asc” (the default) or “desc” depending on the order you’d like the values sorted, e.g. Categories?$orderby=CategoryName desc. Optional. of the matching resources included with the resources in the response, e.g. Categories?$count=true. Optional. will be added to the HTTP request.
529 530 531 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 529 def list_with_http_info(filter = nil, top = nil, skip = nil, select = nil, orderby = nil, count = nil, custom_headers = nil) list_async(filter, top, skip, select, orderby, count, custom_headers).value! end |
#update(resource_group_name, name, parameters, custom_headers = nil) ⇒ DataLakeStoreAccount
Updates the specified Data Lake Store account information.
contains the Data Lake Store account. to update the Data Lake Store account. will be added to the HTTP request.
85 86 87 88 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 85 def update(resource_group_name, name, parameters, custom_headers = nil) response = update_async(resource_group_name, name, parameters, custom_headers).value! response.body unless response.nil? end |
#update_async(resource_group_name, name, parameters, custom_headers = nil) ⇒ Concurrent::Promise
contains the Data Lake Store account. to update the Data Lake Store account. will be added to the HTTP request.
response.
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 |
# File 'lib/generated/azure_mgmt_datalake_store/account.rb', line 102 def update_async(resource_group_name, name, parameters, custom_headers = nil) # Send request promise = begin_update_async(resource_group_name, name, parameters, custom_headers) promise = promise.then do |response| # Defining deserialization method. deserialize_method = lambda do |parsed_response| result_mapper = Azure::ARM::DataLakeStore::Models::DataLakeStoreAccount.mapper() parsed_response = @client.deserialize(result_mapper, parsed_response) end # Waiting for response. @client.get_long_running_operation_result(response, deserialize_method) end promise end |