Class: Armrest::Services::BlobService
- Defined in:
- lib/armrest/services/blob_service.rb
Instance Method Summary collapse
-
#get_properties ⇒ Object
docs.microsoft.com/en-us/rest/api/storagerp/blob-services/get-service-properties GET management.azure.com/subscriptions/subscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.Storage/storageAccounts/accountName/blobServices/default?api-version=2021-04-01.
-
#initialize(options = {}) ⇒ BlobService
constructor
A new instance of BlobService.
-
#set_properties(props) ⇒ Object
docs.microsoft.com/en-us/rest/api/storagerp/blob-services/set-service-properties PUT management.azure.com/subscriptions/subscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.Storage/storageAccounts/accountName/blobServices/default?api-version=2021-04-01.
Methods included from Api::Settings
#client_id, #client_secret, #endpoint, #group, #location, #resource, #subscription_id, #tenant_id
Methods included from Api::HandleResponse
Methods included from Logging
#default_logger, #logger, #logger=
Constructor Details
#initialize(options = {}) ⇒ BlobService
Returns a new instance of BlobService.
3 4 5 6 |
# File 'lib/armrest/services/blob_service.rb', line 3 def initialize(={}) super @storage_account = [:storage_account] end |
Instance Method Details
#get_properties ⇒ Object
docs.microsoft.com/en-us/rest/api/storagerp/blob-services/get-service-properties GET management.azure.com/subscriptions/subscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.Storage/storageAccounts/accountName/blobServices/default?api-version=2021-04-01
10 11 12 13 14 |
# File 'lib/armrest/services/blob_service.rb', line 10 def get_properties path = "subscriptions/#{subscription_id}/resourceGroups/#{group}/providers/Microsoft.Storage/storageAccounts/#{@storage_account}/blobServices/default" resp = api.get(path) load_json(resp) end |
#set_properties(props) ⇒ Object
docs.microsoft.com/en-us/rest/api/storagerp/blob-services/set-service-properties PUT management.azure.com/subscriptions/subscriptionId/resourceGroups/resourceGroupName/providers/Microsoft.Storage/storageAccounts/accountName/blobServices/default?api-version=2021-04-01
18 19 20 21 22 23 |
# File 'lib/armrest/services/blob_service.rb', line 18 def set_properties(props) props = props.to_h.deep_symbolize_keys data = { properties: props } path = "subscriptions/#{subscription_id}/resourceGroups/#{group}/providers/Microsoft.Storage/storageAccounts/#{@storage_account}/blobServices/default" api.put(path, data) end |