SalimAzureBlobAPI/SalimAzureAPI/AzureBlobManager.cs
/// <summary>
/// Checks if a blob exists.
/// </summary>
/// <param name="containerName">Name of the container.</param>
/// <param name="blobName">Name of the blob.</param>
/// <returns>True if blob exists; false otherwise</returns>
Checks if a blob exists.
Checks if a blob exists .
public bool DoesBlobExist(string containerName, string blobName)
        {
            bool returnValue = false;
            ExecuteWithExceptionHandling(
                    () =>
                    {
                        CloudBlobContainer container = _blobClient.GetContainerReference(containerName);
                        _blockBlob = container.GetBlockBlobReference(blobName);
                        returnValue = _blockBlob.Exists();
                    });
            return returnValue;
        }
public bool DoesBlobExist ( string containerName , string blobName ) { bool returnValue = false ; ExecuteWithExceptionHandling ( ( ) => { CloudBlobContainer container = _blobClient . GetContainerReference ( containerName ) ; _blockBlob = container . GetBlockBlobReference ( blobName ) ; returnValue = _blockBlob . Exists ( ) ; } ) ; return returnValue ; }
Checks if a blob exists.
Checks if a blob exists .
True if blob exists; false otherwise
True if blob exists ; false otherwise
containerName
string
Name of the container.
Name of the container .
blobName
string
Name of the blob.
Name of the blob .