BlobContainerClient Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
The BlobContainerClient allows you to manipulate Azure Storage containers and their blobs.
public class BlobContainerClient
type BlobContainerClient = class
Public Class BlobContainerClient
- Inheritance
-
BlobContainerClient
Constructors
BlobContainerClient() |
Initializes a new instance of the BlobContainerClient class for mocking. |
BlobContainerClient(String, String, BlobClientOptions) |
Initializes a new instance of the BlobContainerClient class. |
BlobContainerClient(String, String) |
Initializes a new instance of the BlobContainerClient class. |
BlobContainerClient(Uri, AzureSasCredential, BlobClientOptions) |
Initializes a new instance of the BlobContainerClient class. |
BlobContainerClient(Uri, BlobClientOptions) |
Initializes a new instance of the BlobContainerClient class. |
BlobContainerClient(Uri, StorageSharedKeyCredential, BlobClientOptions) |
Initializes a new instance of the BlobContainerClient class. |
BlobContainerClient(Uri, TokenCredential, BlobClientOptions) |
Initializes a new instance of the BlobContainerClient class. |
Fields
LogsBlobContainerName |
The Azure Storage name used to identify a storage account's logs container. |
RootBlobContainerName |
The Azure Storage name used to identify a storage account's root container. |
WebBlobContainerName |
The Azure Storage name used to identify a storage account's web content container. |
Properties
AccountName |
Gets the Storage account name corresponding to the container client. |
CanGenerateSasUri |
Indicates whether the client is able to generate a SAS uri. Client can generate a SAS url if it is authenticated with a StorageSharedKeyCredential. |
Name |
Gets the name of the container. |
Uri |
Gets the container's primary Uri endpoint. |
Methods
Create(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) |
The Create(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) operation creates a new container under the specified account. If the container with the same name already exists, the operation fails. For more information, see Create Container. |
CreateAsync(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) |
The CreateAsync(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) operation creates a new container under the specified account. If the container with the same name already exists, the operation fails. For more information, see Create Container. |
CreateClient(Uri, BlobClientOptions, HttpPipeline) |
Initializes a new instance of the BlobContainerClient class. |
CreateIfNotExists(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) |
The CreateIfNotExists(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) operation creates a new container under the specified account. If the container with the same name already exists, it is not changed. For more information, see Create Container. |
CreateIfNotExistsAsync(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) |
The CreateIfNotExistsAsync(PublicAccessType, IDictionary<String,String>, BlobContainerEncryptionScopeOptions, CancellationToken) operation creates a new container under the specified account. If the container with the same name already exists, it is not changed. For more information, see Create Container. |
Delete(BlobRequestConditions, CancellationToken) |
The Delete(BlobRequestConditions, CancellationToken) operation marks the specified container for deletion. The container and any blobs contained within it are later deleted during garbage collection which could take several minutes. For more information, see Delete Container. |
DeleteAsync(BlobRequestConditions, CancellationToken) |
The DeleteAsync(BlobRequestConditions, CancellationToken) operation marks the specified container for deletion. The container and any blobs contained within it are later deleted during garbage collection which could take several minutes. For more information, see Delete Container. |
DeleteBlob(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) |
The DeleteBlob(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) operation marks the specified blob or snapshot for deletion. The blob is later deleted during garbage collection which could take several minutes. Note that in order to delete a blob, you must delete all of its snapshots. You can delete both at the same time using IncludeSnapshots. For more information, see Delete Blob. |
DeleteBlobAsync(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) |
The DeleteBlobAsync(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) operation marks the specified blob or snapshot for deletion. The blob is later deleted during garbage collection which could take several minutes. Note that in order to delete a blob, you must delete all of its snapshots. You can delete both at the same time using IncludeSnapshots. For more information, see Delete Blob. |
DeleteBlobIfExists(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) |
The DeleteBlobIfExists(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) operation marks the specified blob or snapshot for deletion, if the blob or snapshot exists. The blob is later deleted during garbage collection which could take several minutes. Note that in order to delete a blob, you must delete all of its snapshots. You can delete both at the same time using IncludeSnapshots. For more information, see Delete Blob. |
DeleteBlobIfExistsAsync(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) |
The DeleteBlobIfExistsAsync(String, DeleteSnapshotsOption, BlobRequestConditions, CancellationToken) operation marks the specified blob or snapshot for deletion, if the blob or snapshot exists. The blob is later deleted during garbage collection which could take several minutes. Note that in order to delete a blob, you must delete all of its snapshots. You can delete both at the same time using IncludeSnapshots. For more information, see Delete Blob. |
DeleteIfExists(BlobRequestConditions, CancellationToken) |
The DeleteIfExists(BlobRequestConditions, CancellationToken) operation marks the specified container for deletion if it exists. The container and any blobs contained within it are later deleted during garbage collection which could take several minutes. For more information, see Delete Container. |
DeleteIfExistsAsync(BlobRequestConditions, CancellationToken) |
The DeleteIfExistsAsync(BlobRequestConditions, CancellationToken) operation marks the specified container for deletion if it exists. The container and any blobs contained within it are later deleted during garbage collection which could take several minutes. For more information, see Delete Container. |
Exists(CancellationToken) |
The Exists(CancellationToken) operation can be called on a BlobContainerClient to see if the associated container exists on the storage account in the storage service. |
ExistsAsync(CancellationToken) |
The ExistsAsync(CancellationToken) operation can be called on a BlobContainerClient to see if the associated container exists on the storage account in the storage service. |
FindBlobsByTags(String, CancellationToken) |
The Filter Blobs operation enables callers to list blobs in the container whose tags match a given search expression and only the tags appearing in the expression will be returned. For more information, see Find Blobs by Tags. |
FindBlobsByTagsAsync(String, CancellationToken) |
The Filter Blobs operation enables callers to list blobs in the container whose tags match a given search expression and only the tags appearing in the expression will be returned. For more information, see Find Blobs by Tags. |
GenerateSasUri(BlobContainerSasPermissions, DateTimeOffset) |
The GenerateSasUri(BlobContainerSasPermissions, DateTimeOffset) returns a Uri that generates a Blob Container Service Shared Access Signature (SAS) Uri based on the Client properties and parameters passed. The SAS is signed by the shared key credential of the client. To check if the client is able to sign a Service Sas see CanGenerateSasUri. For more information, see Constructing a service SAS. |
GenerateSasUri(BlobSasBuilder) |
The GenerateSasUri(BlobSasBuilder) returns a Uri that generates a Blob Container Service Shared Access Signature (SAS) Uri based on the Client properties and builder passed. The SAS is signed by the shared key credential of the client. To check if the client is able to sign a Service Sas see CanGenerateSasUri. For more information, see Constructing a Service SAS. |
GenerateUserDelegationSasUri(BlobContainerSasPermissions, DateTimeOffset, UserDelegationKey) |
The GenerateUserDelegationSasUri(BlobContainerSasPermissions, DateTimeOffset, UserDelegationKey) returns a Uri representing a Blob Container Service Shared Access Signature (SAS) Uri based on the Client properties and parameters passed. The SAS is signed by the user delegation key that is passed in. For more information, see Creating an user delegation SAS. |
GenerateUserDelegationSasUri(BlobSasBuilder, UserDelegationKey) |
The GenerateUserDelegationSasUri(BlobSasBuilder, UserDelegationKey) returns a Uri representing a Blob Container Service Shared Access Signature (SAS) Uri based on the Client properties and builder passed. The SAS is signed by the user delegation key that is passed in. For more information, see Creating an user delegation SAS. |
GetAccessPolicy(BlobRequestConditions, CancellationToken) |
The GetAccessPolicy(BlobRequestConditions, CancellationToken) operation gets the permissions for this container. The permissions indicate whether container data may be accessed publicly. For more information, see Get Container ACL. |
GetAccessPolicyAsync(BlobRequestConditions, CancellationToken) |
The GetAccessPolicyAsync(BlobRequestConditions, CancellationToken) operation gets the permissions for this container. The permissions indicate whether container data may be accessed publicly. For more information, see Get Container ACL. |
GetAccountInfo(CancellationToken) |
The GetAccountInfo(CancellationToken) operation returns the sku name and account kind for the specified account. For more information, see Get Account Information. |
GetAccountInfoAsync(CancellationToken) |
The GetAccountInfoAsync(CancellationToken) operation returns the sku name and account kind for the specified account. For more information, see Get Account Information. |
GetAppendBlobClientCore(String) |
Create a new AppendBlobClient object by
concatenating |
GetBlobBaseClientCore(String) |
Create a new BlobBaseClient object by appending
|
GetBlobClient(String) |
Create a new BlobClient object by appending
|
GetBlobLeaseClientCore(String) |
Initializes a new instance of the BlobLeaseClient class. |
GetBlobs(BlobTraits, BlobStates, String, CancellationToken) |
The GetBlobs(BlobTraits, BlobStates, String, CancellationToken) operation returns an async sequence of blobs in this container. Enumerating the blobs may make multiple requests to the service while fetching all the values. Blobs are ordered lexicographically by name. For more information, see List Blobs. |
GetBlobsAsync(BlobTraits, BlobStates, String, CancellationToken) |
The GetBlobsAsync(BlobTraits, BlobStates, String, CancellationToken) operation returns an async sequence of blobs in this container. Enumerating the blobs may make multiple requests to the service while fetching all the values. Blobs are ordered lexicographically by name. For more information, see List Blobs. |
GetBlobsByHierarchy(BlobTraits, BlobStates, String, String, CancellationToken) |
The GetBlobsByHierarchy(BlobTraits, BlobStates, String, String, CancellationToken) operation returns
an async collection of blobs in this container. Enumerating the
blobs may make multiple requests to the service while fetching all
the values. Blobs are ordered lexicographically by name. A
For more information, see List Blobs. |
GetBlobsByHierarchyAsync(BlobTraits, BlobStates, String, String, CancellationToken) |
The GetBlobsByHierarchyAsync(BlobTraits, BlobStates, String, String, CancellationToken) operation returns
an async collection of blobs in this container. Enumerating the
blobs may make multiple requests to the service while fetching all
the values. Blobs are ordered lexicographically by name. A
For more information, see List Blobs. |
GetBlockBlobClientCore(String) |
Create a new BlockBlobClient object by
concatenating |
GetPageBlobClientCore(String) |
Create a new PageBlobClient object by
concatenating |
GetParentBlobServiceClientCore() |
Create a new BlobServiceClient that pointing to this BlobContainerClient's blob service. The new BlobServiceClient uses the same request policy pipeline as the BlobContainerClient. |
GetProperties(BlobRequestConditions, CancellationToken) |
The GetProperties(BlobRequestConditions, CancellationToken) operation returns all user-defined metadata and system properties for the specified container. The data returned does not include the container's list of blobs. For more information, see Get Container Properties. |
GetPropertiesAsync(BlobRequestConditions, CancellationToken) |
The GetPropertiesAsync(BlobRequestConditions, CancellationToken) operation returns all user-defined metadata and system properties for the specified container. The data returned does not include the container's list of blobs. For more information, see Get Container Properties. |
SetAccessPolicy(PublicAccessType, IEnumerable<BlobSignedIdentifier>, BlobRequestConditions, CancellationToken) |
The SetAccessPolicy(PublicAccessType, IEnumerable<BlobSignedIdentifier>, BlobRequestConditions, CancellationToken) operation sets the permissions for the specified container. The permissions indicate whether blob container data may be accessed publicly. For more information, see Set Container ACL. |
SetAccessPolicyAsync(PublicAccessType, IEnumerable<BlobSignedIdentifier>, BlobRequestConditions, CancellationToken) |
The SetAccessPolicyAsync(PublicAccessType, IEnumerable<BlobSignedIdentifier>, BlobRequestConditions, CancellationToken) operation sets the permissions for the specified container. The permissions indicate whether blob container data may be accessed publicly. For more information, see Set Container ACL. |
SetMetadata(IDictionary<String,String>, BlobRequestConditions, CancellationToken) |
The SetMetadata(IDictionary<String,String>, BlobRequestConditions, CancellationToken) operation sets one or more user-defined name-value pairs for the specified container. For more information, see Set Container Metadata. |
SetMetadataAsync(IDictionary<String,String>, BlobRequestConditions, CancellationToken) |
The SetMetadataAsync(IDictionary<String,String>, BlobRequestConditions, CancellationToken) operation sets one or more user-defined name-value pairs for the specified container. For more information, see Set Container Metadata. |
UploadBlob(String, BinaryData, CancellationToken) |
The UploadBlob(String, BinaryData, CancellationToken) operation creates a new block blob. For partial block blob updates and other advanced features, please see BlockBlobClient. To create or modify page or append blobs, please see PageBlobClient or AppendBlobClient. For more information, see Put Blob. |
UploadBlob(String, Stream, CancellationToken) |
The UploadBlob(String, Stream, CancellationToken) operation creates a new block blob. For partial block blob updates and other advanced features, please see BlockBlobClient. To create or modify page or append blobs, please see PageBlobClient or AppendBlobClient. For more information, see Put Blob. |
UploadBlobAsync(String, BinaryData, CancellationToken) |
The UploadBlobAsync(String, BinaryData, CancellationToken) operation creates a new block blob. For partial block blob updates and other advanced features, please see BlockBlobClient. To create or modify page or append blobs, please see PageBlobClient or AppendBlobClient. For more information, see Put Blob. |
UploadBlobAsync(String, Stream, CancellationToken) |
The UploadBlobAsync(String, Stream, CancellationToken) operation creates a new block blob. For partial block blob updates and other advanced features, please see BlockBlobClient. To create or modify page or append blobs, please see PageBlobClient or AppendBlobClient. For more information, see Put Blob. |
Extension Methods
StartDownloadToDirectoryAsync(BlobContainerClient, String, BlobContainerClientTransferOptions) |
Downloads the contents of a blob container. |
StartDownloadToDirectoryAsync(BlobContainerClient, String, String) |
Downloads the contents of a blob container. |
StartUploadDirectoryAsync(BlobContainerClient, String, BlobContainerClientTransferOptions) |
Uploads the entire contents of local directory to the blob container. |
StartUploadDirectoryAsync(BlobContainerClient, String, String) |
Uploads the entire contents of local directory to the blob container. |
GetAppendBlobClient(BlobContainerClient, String) |
Create a new AppendBlobClient object by
concatenating |
GetBlobBaseClient(BlobContainerClient, String) |
Create a new BlobBaseClient object by concatenating
|
GetBlobBatchClient(BlobContainerClient) |
Create a new BlobBatchClient object for the container associated with the BlobContainerClient. The new BlobBatchClient uses the same request policy pipeline as the BlobContainerClient. |
GetBlobLeaseClient(BlobContainerClient, String) |
Initializes a new instance of the BlobLeaseClient class. |
GetBlockBlobClient(BlobContainerClient, String) |
Create a new BlockBlobClient object by
concatenating |
GetParentBlobServiceClient(BlobContainerClient) |
Create a new BlobServiceClient that pointing to this BlobContainerClient's blob service. The new BlobServiceClient uses the same request policy pipeline as the BlobContainerClient. |