SalimAzureBlobAPI/SalimAzureAPI/AzureBlobManager.cs
/// <summary>
/// Checks if a container exists.
/// </summary>
/// <param name="containerName">Name of the container.</param>
/// <returns>True if container exists; false otherwise</returns>
Checks if a container exists.
Checks if a container exists .
public bool DoesContainerExist(string containerName)
        {
            bool returnValue = false;
            ExecuteWithExceptionHandling(
                    () =>
                    {
                        IEnumerable<CloudBlobContainer> containers = _blobClient.ListContainers();
                        returnValue = containers.Any(one => one.Name == containerName);
                    });
            return returnValue;
        }
public bool DoesContainerExist ( string containerName ) { bool returnValue = false ; ExecuteWithExceptionHandling ( ( ) => { IEnumerable < CloudBlobContainer > containers = _blobClient . ListContainers ( ) ; returnValue = containers . Any ( one => one . Name == containerName ) ; } ) ; return returnValue ; }
Checks if a container exists.
Checks if a container exists .
True if container exists; false otherwise
True if container exists ; false otherwise
containerName
string
Name of the container.
Name of the container .