Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,11 @@
# regenerated.
# --------------------------------------------------------------------------

from .storage_management_client import StorageManagementClient
from .version import VERSION
from ._configuration import StorageManagementClientConfiguration
from ._storage_management_client import StorageManagementClient
__all__ = ['StorageManagementClient', 'StorageManagementClientConfiguration']

__all__ = ['StorageManagementClient']
from .version import VERSION

__version__ = VERSION

Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# coding=utf-8
# --------------------------------------------------------------------------
# Copyright (c) Microsoft Corporation. All rights reserved.
# Licensed under the MIT License. See License.txt in the project root for
# license information.
#
# Code generated by Microsoft (R) AutoRest Code Generator.
# Changes may cause incorrect behavior and will be lost if the code is
# regenerated.
# --------------------------------------------------------------------------
from msrestazure import AzureConfiguration

from .version import VERSION


class StorageManagementClientConfiguration(AzureConfiguration):
"""Configuration for StorageManagementClient
Note that all parameters used to create this instance are saved as instance
attributes.

:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param subscription_id: Subscription credentials which uniquely identify
the Microsoft Azure subscription. The subscription ID forms part of the
URI for every service call.
:type subscription_id: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, subscription_id, base_url=None):

if credentials is None:
raise ValueError("Parameter 'credentials' must not be None.")
if subscription_id is None:
raise ValueError("Parameter 'subscription_id' must not be None.")
if not base_url:
base_url = 'https://management.azure.com'

super(StorageManagementClientConfiguration, self).__init__(base_url)

# Starting Autorest.Python 4.0.64, make connection pool activated by default
self.keep_alive = True

self.add_user_agent('azure-mgmt-storage/{}'.format(VERSION))
self.add_user_agent('Azure-SDK-For-Python')

self.credentials = credentials
self.subscription_id = subscription_id
Original file line number Diff line number Diff line change
Expand Up @@ -11,45 +11,11 @@

from msrest.service_client import SDKClient
from msrest import Serializer, Deserializer
from msrestazure import AzureConfiguration
from .version import VERSION
from .operations.storage_accounts_operations import StorageAccountsOperations
from .operations.usage_operations import UsageOperations
from . import models


class StorageManagementClientConfiguration(AzureConfiguration):
"""Configuration for StorageManagementClient
Note that all parameters used to create this instance are saved as instance
attributes.

:param credentials: Credentials needed for the client to connect to Azure.
:type credentials: :mod:`A msrestazure Credentials
object<msrestazure.azure_active_directory>`
:param subscription_id: Subscription credentials which uniquely identify
the Microsoft Azure subscription. The subscription ID forms part of the
URI for every service call.
:type subscription_id: str
:param str base_url: Service URL
"""

def __init__(
self, credentials, subscription_id, base_url=None):

if credentials is None:
raise ValueError("Parameter 'credentials' must not be None.")
if subscription_id is None:
raise ValueError("Parameter 'subscription_id' must not be None.")
if not base_url:
base_url = 'https://management.azure.com'

super(StorageManagementClientConfiguration, self).__init__(base_url)

self.add_user_agent('azure-mgmt-storage/{}'.format(VERSION))
self.add_user_agent('Azure-SDK-For-Python')

self.credentials = credentials
self.subscription_id = subscription_id
from ._configuration import StorageManagementClientConfiguration
from .operations import StorageAccountsOperations
from .operations import UsageOperations
from . import models


class StorageManagementClient(SDKClient):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,34 +10,34 @@
# --------------------------------------------------------------------------

try:
from .storage_account_check_name_availability_parameters_py3 import StorageAccountCheckNameAvailabilityParameters
from .check_name_availability_result_py3 import CheckNameAvailabilityResult
from .storage_account_create_parameters_py3 import StorageAccountCreateParameters
from .endpoints_py3 import Endpoints
from .custom_domain_py3 import CustomDomain
from .storage_account_py3 import StorageAccount
from .storage_account_keys_py3 import StorageAccountKeys
from .storage_account_update_parameters_py3 import StorageAccountUpdateParameters
from .storage_account_regenerate_key_parameters_py3 import StorageAccountRegenerateKeyParameters
from .usage_name_py3 import UsageName
from .usage_py3 import Usage
from .resource_py3 import Resource
from ._models_py3 import CheckNameAvailabilityResult
from ._models_py3 import CustomDomain
from ._models_py3 import Endpoints
from ._models_py3 import Resource
from ._models_py3 import StorageAccount
from ._models_py3 import StorageAccountCheckNameAvailabilityParameters
from ._models_py3 import StorageAccountCreateParameters
from ._models_py3 import StorageAccountKeys
from ._models_py3 import StorageAccountRegenerateKeyParameters
from ._models_py3 import StorageAccountUpdateParameters
from ._models_py3 import Usage
from ._models_py3 import UsageName
except (SyntaxError, ImportError):
from .storage_account_check_name_availability_parameters import StorageAccountCheckNameAvailabilityParameters
from .check_name_availability_result import CheckNameAvailabilityResult
from .storage_account_create_parameters import StorageAccountCreateParameters
from .endpoints import Endpoints
from .custom_domain import CustomDomain
from .storage_account import StorageAccount
from .storage_account_keys import StorageAccountKeys
from .storage_account_update_parameters import StorageAccountUpdateParameters
from .storage_account_regenerate_key_parameters import StorageAccountRegenerateKeyParameters
from .usage_name import UsageName
from .usage import Usage
from .resource import Resource
from .storage_account_paged import StorageAccountPaged
from .usage_paged import UsagePaged
from .storage_management_client_enums import (
from ._models import CheckNameAvailabilityResult
from ._models import CustomDomain
from ._models import Endpoints
from ._models import Resource
from ._models import StorageAccount
from ._models import StorageAccountCheckNameAvailabilityParameters
from ._models import StorageAccountCreateParameters
from ._models import StorageAccountKeys
from ._models import StorageAccountRegenerateKeyParameters
from ._models import StorageAccountUpdateParameters
from ._models import Usage
from ._models import UsageName
from ._paged_models import StorageAccountPaged
from ._paged_models import UsagePaged
from ._storage_management_client_enums import (
Reason,
AccountType,
ProvisioningState,
Expand All @@ -46,18 +46,18 @@
)

__all__ = [
'StorageAccountCheckNameAvailabilityParameters',
'CheckNameAvailabilityResult',
'StorageAccountCreateParameters',
'Endpoints',
'CustomDomain',
'Endpoints',
'Resource',
'StorageAccount',
'StorageAccountCheckNameAvailabilityParameters',
'StorageAccountCreateParameters',
'StorageAccountKeys',
'StorageAccountUpdateParameters',
'StorageAccountRegenerateKeyParameters',
'UsageName',
'StorageAccountUpdateParameters',
'Usage',
'Resource',
'UsageName',
'StorageAccountPaged',
'UsagePaged',
'Reason',
Expand Down
Loading