private static async Task CallBlobSamples(CloudBlobContainer container)
{
// Create a blob with a random name.
CloudBlockBlob blob = await CreateRandomlyNamedBlockBlobAsync(container);
// Get a reference to the blob created above from the server.
// This call will fail if the blob does not yet exist.
await GetExistingBlobReferenceAsync(container, blob.Name);
// Create a specified number of block blobs in a flat structure.
await CreateSequentiallyNamedBlockBlobsAsync(container, 5);
// List blobs in a flat listing
await ListBlobsFlatListingAsync(container, 10);
// Create a specified number of block blobs in a hierarchical structure.
await CreateNestedBlockBlobsAsync(container, 4, 3);
// List blobs with a hierarchical listing.
await ListBlobsHierarchicalListingAsync(container, null);
// List blobs whose names begin with "s" hierarchically, passing the container name as part of the prefix.
ListBlobsFromServiceClient(container.ServiceClient, string.Format("{0}/s", container.Name));
// List blobs whose names begin with "0" hierarchically, passing the container name as part of the prefix.
await ListBlobsFromServiceClientAsync(container.ServiceClient, string.Format("{0}/0", container.Name));
// Create a snapshot of a block blob.
await CreateBlockBlobSnapshotAsync(container);
// Copy a block blob to another blob in the same container.
await CopyBlockBlobAsync(container);
// To create and copy a large blob, uncomment this method.
// By default it creates a 100 MB blob and then copies it; change the value of the sizeInMb parameter
// to create a smaller or larger blob.
// await CopyLargeBlob(container, 100);
// Upload a blob in blocks.
await UploadBlobInBlocksAsync(container);
// Upload a 5 MB array of bytes to a block blob.
await UploadByteArrayAsync(container, 1024 * 5);
}