Skip to content

Commit

Permalink
Generated from f31b3094d636cd11b16647f38137faef5fff7524
Browse files Browse the repository at this point in the history
Really fix prettier errors.
  • Loading branch information
SDK Automation committed Mar 25, 2020
1 parent 4ac98b1 commit 37a57b5
Show file tree
Hide file tree
Showing 3 changed files with 86 additions and 24 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,12 @@ class BlobContainer(AzureEntityResource):
:vartype type: str
:ivar etag: Resource Etag.
:vartype etag: str
:param default_encryption_scope: Default the container to use specified
encryption scope for all writes.
:type default_encryption_scope: str
:param deny_encryption_scope_override: Block override of encryption scope
from the container default.
:type deny_encryption_scope_override: bool
:param public_access: Specifies whether data in the container may be
accessed publicly and the level of access. Possible values include:
'Container', 'Blob', 'None'
Expand Down Expand Up @@ -314,6 +320,8 @@ class BlobContainer(AzureEntityResource):
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'etag': {'key': 'etag', 'type': 'str'},
'default_encryption_scope': {'key': 'properties.defaultEncryptionScope', 'type': 'str'},
'deny_encryption_scope_override': {'key': 'properties.denyEncryptionScopeOverride', 'type': 'bool'},
'public_access': {'key': 'properties.publicAccess', 'type': 'PublicAccess'},
'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'},
'lease_status': {'key': 'properties.leaseStatus', 'type': 'str'},
Expand All @@ -328,6 +336,8 @@ class BlobContainer(AzureEntityResource):

def __init__(self, **kwargs):
super(BlobContainer, self).__init__(**kwargs)
self.default_encryption_scope = kwargs.get('default_encryption_scope', None)
self.deny_encryption_scope_override = kwargs.get('deny_encryption_scope_override', None)
self.public_access = kwargs.get('public_access', None)
self.last_modified_time = None
self.lease_status = None
Expand Down Expand Up @@ -1509,25 +1519,43 @@ def __init__(self, **kwargs):
class KeyVaultProperties(Model):
"""Properties of key vault.
Variables are only populated by the server, and will be ignored when
sending a request.
:param key_name: The name of KeyVault key.
:type key_name: str
:param key_version: The version of KeyVault key.
:type key_version: str
:param key_vault_uri: The Uri of KeyVault.
:type key_vault_uri: str
:ivar current_versioned_key_identifier: The object identifier of the
current versioned Key Vault Key in use.
:vartype current_versioned_key_identifier: str
:ivar last_key_rotation_timestamp: Timestamp of last rotation of the Key
Vault Key.
:vartype last_key_rotation_timestamp: datetime
"""

_validation = {
'current_versioned_key_identifier': {'readonly': True},
'last_key_rotation_timestamp': {'readonly': True},
}

_attribute_map = {
'key_name': {'key': 'keyname', 'type': 'str'},
'key_version': {'key': 'keyversion', 'type': 'str'},
'key_vault_uri': {'key': 'keyvaulturi', 'type': 'str'},
'current_versioned_key_identifier': {'key': 'currentVersionedKeyIdentifier', 'type': 'str'},
'last_key_rotation_timestamp': {'key': 'lastKeyRotationTimestamp', 'type': 'iso-8601'},
}

def __init__(self, **kwargs):
super(KeyVaultProperties, self).__init__(**kwargs)
self.key_name = kwargs.get('key_name', None)
self.key_version = kwargs.get('key_version', None)
self.key_vault_uri = kwargs.get('key_vault_uri', None)
self.current_versioned_key_identifier = None
self.last_key_rotation_timestamp = None


class LeaseContainerRequest(Model):
Expand Down Expand Up @@ -1702,6 +1730,12 @@ class ListContainerItem(AzureEntityResource):
:vartype type: str
:ivar etag: Resource Etag.
:vartype etag: str
:param default_encryption_scope: Default the container to use specified
encryption scope for all writes.
:type default_encryption_scope: str
:param deny_encryption_scope_override: Block override of encryption scope
from the container default.
:type deny_encryption_scope_override: bool
:param public_access: Specifies whether data in the container may be
accessed publicly and the level of access. Possible values include:
'Container', 'Blob', 'None'
Expand Down Expand Up @@ -1766,6 +1800,8 @@ class ListContainerItem(AzureEntityResource):
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'etag': {'key': 'etag', 'type': 'str'},
'default_encryption_scope': {'key': 'properties.defaultEncryptionScope', 'type': 'str'},
'deny_encryption_scope_override': {'key': 'properties.denyEncryptionScopeOverride', 'type': 'bool'},
'public_access': {'key': 'properties.publicAccess', 'type': 'PublicAccess'},
'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'},
'lease_status': {'key': 'properties.leaseStatus', 'type': 'str'},
Expand All @@ -1780,6 +1816,8 @@ class ListContainerItem(AzureEntityResource):

def __init__(self, **kwargs):
super(ListContainerItem, self).__init__(**kwargs)
self.default_encryption_scope = kwargs.get('default_encryption_scope', None)
self.deny_encryption_scope_override = kwargs.get('deny_encryption_scope_override', None)
self.public_access = kwargs.get('public_access', None)
self.last_modified_time = None
self.lease_status = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,12 @@ class BlobContainer(AzureEntityResource):
:vartype type: str
:ivar etag: Resource Etag.
:vartype etag: str
:param default_encryption_scope: Default the container to use specified
encryption scope for all writes.
:type default_encryption_scope: str
:param deny_encryption_scope_override: Block override of encryption scope
from the container default.
:type deny_encryption_scope_override: bool
:param public_access: Specifies whether data in the container may be
accessed publicly and the level of access. Possible values include:
'Container', 'Blob', 'None'
Expand Down Expand Up @@ -314,6 +320,8 @@ class BlobContainer(AzureEntityResource):
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'etag': {'key': 'etag', 'type': 'str'},
'default_encryption_scope': {'key': 'properties.defaultEncryptionScope', 'type': 'str'},
'deny_encryption_scope_override': {'key': 'properties.denyEncryptionScopeOverride', 'type': 'bool'},
'public_access': {'key': 'properties.publicAccess', 'type': 'PublicAccess'},
'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'},
'lease_status': {'key': 'properties.leaseStatus', 'type': 'str'},
Expand All @@ -326,8 +334,10 @@ class BlobContainer(AzureEntityResource):
'has_immutability_policy': {'key': 'properties.hasImmutabilityPolicy', 'type': 'bool'},
}

def __init__(self, *, public_access=None, metadata=None, **kwargs) -> None:
def __init__(self, *, default_encryption_scope: str=None, deny_encryption_scope_override: bool=None, public_access=None, metadata=None, **kwargs) -> None:
super(BlobContainer, self).__init__(**kwargs)
self.default_encryption_scope = default_encryption_scope
self.deny_encryption_scope_override = deny_encryption_scope_override
self.public_access = public_access
self.last_modified_time = None
self.lease_status = None
Expand Down Expand Up @@ -1509,25 +1519,43 @@ def __init__(self, *, ip_address_or_range: str, action="Allow", **kwargs) -> Non
class KeyVaultProperties(Model):
"""Properties of key vault.
Variables are only populated by the server, and will be ignored when
sending a request.
:param key_name: The name of KeyVault key.
:type key_name: str
:param key_version: The version of KeyVault key.
:type key_version: str
:param key_vault_uri: The Uri of KeyVault.
:type key_vault_uri: str
:ivar current_versioned_key_identifier: The object identifier of the
current versioned Key Vault Key in use.
:vartype current_versioned_key_identifier: str
:ivar last_key_rotation_timestamp: Timestamp of last rotation of the Key
Vault Key.
:vartype last_key_rotation_timestamp: datetime
"""

_validation = {
'current_versioned_key_identifier': {'readonly': True},
'last_key_rotation_timestamp': {'readonly': True},
}

_attribute_map = {
'key_name': {'key': 'keyname', 'type': 'str'},
'key_version': {'key': 'keyversion', 'type': 'str'},
'key_vault_uri': {'key': 'keyvaulturi', 'type': 'str'},
'current_versioned_key_identifier': {'key': 'currentVersionedKeyIdentifier', 'type': 'str'},
'last_key_rotation_timestamp': {'key': 'lastKeyRotationTimestamp', 'type': 'iso-8601'},
}

def __init__(self, *, key_name: str=None, key_version: str=None, key_vault_uri: str=None, **kwargs) -> None:
super(KeyVaultProperties, self).__init__(**kwargs)
self.key_name = key_name
self.key_version = key_version
self.key_vault_uri = key_vault_uri
self.current_versioned_key_identifier = None
self.last_key_rotation_timestamp = None


class LeaseContainerRequest(Model):
Expand Down Expand Up @@ -1702,6 +1730,12 @@ class ListContainerItem(AzureEntityResource):
:vartype type: str
:ivar etag: Resource Etag.
:vartype etag: str
:param default_encryption_scope: Default the container to use specified
encryption scope for all writes.
:type default_encryption_scope: str
:param deny_encryption_scope_override: Block override of encryption scope
from the container default.
:type deny_encryption_scope_override: bool
:param public_access: Specifies whether data in the container may be
accessed publicly and the level of access. Possible values include:
'Container', 'Blob', 'None'
Expand Down Expand Up @@ -1766,6 +1800,8 @@ class ListContainerItem(AzureEntityResource):
'name': {'key': 'name', 'type': 'str'},
'type': {'key': 'type', 'type': 'str'},
'etag': {'key': 'etag', 'type': 'str'},
'default_encryption_scope': {'key': 'properties.defaultEncryptionScope', 'type': 'str'},
'deny_encryption_scope_override': {'key': 'properties.denyEncryptionScopeOverride', 'type': 'bool'},
'public_access': {'key': 'properties.publicAccess', 'type': 'PublicAccess'},
'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'},
'lease_status': {'key': 'properties.leaseStatus', 'type': 'str'},
Expand All @@ -1778,8 +1814,10 @@ class ListContainerItem(AzureEntityResource):
'has_immutability_policy': {'key': 'properties.hasImmutabilityPolicy', 'type': 'bool'},
}

def __init__(self, *, public_access=None, metadata=None, **kwargs) -> None:
def __init__(self, *, default_encryption_scope: str=None, deny_encryption_scope_override: bool=None, public_access=None, metadata=None, **kwargs) -> None:
super(ListContainerItem, self).__init__(**kwargs)
self.default_encryption_scope = default_encryption_scope
self.deny_encryption_scope_override = deny_encryption_scope_override
self.public_access = public_access
self.last_modified_time = None
self.lease_status = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ def internal_paging(next_link=None):
list.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/blobServices/default/containers'}

def create(
self, resource_group_name, account_name, container_name, public_access=None, metadata=None, custom_headers=None, raw=False, **operation_config):
self, resource_group_name, account_name, container_name, blob_container, custom_headers=None, raw=False, **operation_config):
"""Creates a new container under the specified account as described by
request body. The container resource includes metadata and properties
for that container. It does not include a list of the blobs contained
Expand All @@ -147,14 +147,9 @@ def create(
(-) only. Every dash (-) character must be immediately preceded and
followed by a letter or number.
:type container_name: str
:param public_access: Specifies whether data in the container may be
accessed publicly and the level of access. Possible values include:
'Container', 'Blob', 'None'
:type public_access: str or
~azure.mgmt.storage.v2019_06_01.models.PublicAccess
:param metadata: A name-value pair to associate with the container as
metadata.
:type metadata: dict[str, str]
:param blob_container: Properties of the blob container to create.
:type blob_container:
~azure.mgmt.storage.v2019_06_01.models.BlobContainer
:param dict custom_headers: headers that will be added to the request
:param bool raw: returns the direct response alongside the
deserialized response
Expand All @@ -165,8 +160,6 @@ def create(
~msrest.pipeline.ClientRawResponse
:raises: :class:`CloudError<msrestazure.azure_exceptions.CloudError>`
"""
blob_container = models.BlobContainer(public_access=public_access, metadata=metadata)

# Construct URL
url = self.create.metadata['url']
path_format_arguments = {
Expand Down Expand Up @@ -218,7 +211,7 @@ def create(
create.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Storage/storageAccounts/{accountName}/blobServices/default/containers/{containerName}'}

def update(
self, resource_group_name, account_name, container_name, public_access=None, metadata=None, custom_headers=None, raw=False, **operation_config):
self, resource_group_name, account_name, container_name, blob_container, custom_headers=None, raw=False, **operation_config):
"""Updates container properties as specified in request body. Properties
not mentioned in the request will be unchanged. Update fails if the
specified container doesn't already exist. .
Expand All @@ -236,14 +229,9 @@ def update(
(-) only. Every dash (-) character must be immediately preceded and
followed by a letter or number.
:type container_name: str
:param public_access: Specifies whether data in the container may be
accessed publicly and the level of access. Possible values include:
'Container', 'Blob', 'None'
:type public_access: str or
~azure.mgmt.storage.v2019_06_01.models.PublicAccess
:param metadata: A name-value pair to associate with the container as
metadata.
:type metadata: dict[str, str]
:param blob_container: Properties to update for the blob container.
:type blob_container:
~azure.mgmt.storage.v2019_06_01.models.BlobContainer
:param dict custom_headers: headers that will be added to the request
:param bool raw: returns the direct response alongside the
deserialized response
Expand All @@ -254,8 +242,6 @@ def update(
~msrest.pipeline.ClientRawResponse
:raises: :class:`CloudError<msrestazure.azure_exceptions.CloudError>`
"""
blob_container = models.BlobContainer(public_access=public_access, metadata=metadata)

# Construct URL
url = self.update.metadata['url']
path_format_arguments = {
Expand Down

0 comments on commit 37a57b5

Please sign in to comment.