DataSharesOperations Class

Warning

DO NOT instantiate this class directly.

Instead, you should access the following operations through

StorageManagementClient's

<xref:data_shares> attribute.

Constructor

DataSharesOperations(*args, **kwargs)

Methods

begin_create

Create a Storage DataShare if it does not already exist; otherwise, error out. This API will not allow you to replace an already existing resource.

begin_delete

Delete a Storage DataShare.

begin_update

Update a Storage DataShare.

get

Get the specified Storage DataShare.

list_by_storage_account

List all Storage DataShares in a Storage Account.

begin_create

Create a Storage DataShare if it does not already exist; otherwise, error out. This API will not allow you to replace an already existing resource.

begin_create(resource_group_name: str, account_name: str, data_share_name: str, resource: _models.DataShare, *, content_type: str = 'application/json', **kwargs: Any) -> LROPoller[_models.DataShare]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. The name is case insensitive. Required.

account_name
Required
str

The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required.

data_share_name
Required
str

The name of the Storage DataShare. Required.

resource
Required
DataShare or <xref:JSON> or IO[bytes]

Create a Storage DataShare if it does not already exist; otherwise, error out. This API will not allow you to replace an already existing resource. Is one of the following types: DataShare, JSON, IO[bytes] Required.

Returns

Type Description

An instance of LROPoller that returns DataShare. The DataShare is compatible with MutableMapping

Exceptions

Type Description

begin_delete

Delete a Storage DataShare.

begin_delete(resource_group_name: str, account_name: str, data_share_name: str, **kwargs: Any) -> LROPoller[None]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. The name is case insensitive. Required.

account_name
Required
str

The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required.

data_share_name
Required
str

The name of the Storage DataShare. Required.

Returns

Type Description

An instance of LROPoller that returns None

Exceptions

Type Description

begin_update

Update a Storage DataShare.

begin_update(resource_group_name: str, account_name: str, data_share_name: str, properties: _models.DataShareUpdate, *, content_type: str = 'application/json', **kwargs: Any) -> LROPoller[_models.DataShare]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. The name is case insensitive. Required.

account_name
Required
str

The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required.

data_share_name
Required
str

The name of the Storage DataShare. Required.

properties
Required
DataShareUpdate or <xref:JSON> or IO[bytes]

The updated properties of the Storage DataShare. Is one of the following types: DataShareUpdate, JSON, IO[bytes] Required.

Returns

Type Description

An instance of LROPoller that returns DataShare. The DataShare is compatible with MutableMapping

Exceptions

Type Description

get

Get the specified Storage DataShare.

get(resource_group_name: str, account_name: str, data_share_name: str, **kwargs: Any) -> DataShare

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. The name is case insensitive. Required.

account_name
Required
str

The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required.

data_share_name
Required
str

The name of the Storage DataShare. Required.

Returns

Type Description

DataShare. The DataShare is compatible with MutableMapping

Exceptions

Type Description

list_by_storage_account

List all Storage DataShares in a Storage Account.

list_by_storage_account(resource_group_name: str, account_name: str, **kwargs: Any) -> ItemPaged[DataShare]

Parameters

Name Description
resource_group_name
Required
str

The name of the resource group. The name is case insensitive. Required.

account_name
Required
str

The name of the storage account within the specified resource group. Storage account names must be between 3 and 24 characters in length and use numbers and lower-case letters only. Required.

Returns

Type Description

An iterator like instance of DataShare

Exceptions

Type Description