VERTRIEB: 1-800-867-1380

CloudPageBlob.GetPageRanges-Methode (BlobRequestOptions)

Gets a collection of page ranges and their starting and ending bytes.

Namespace: Microsoft.WindowsAzure.StorageClient
Assembly: Microsoft.WindowsAzure.StorageClient (in microsoft.windowsazure.storageclient.dll)

'Usage
Dim instance As CloudPageBlob
Dim options As BlobRequestOptions
Dim returnValue As IEnumerable(Of PageRange)

returnValue = instance.GetPageRanges(options)

public:
IEnumerable<PageRange^>^ GetPageRanges (
	BlobRequestOptions^ options
)
public IEnumerable<PageRange> GetPageRanges (
	BlobRequestOptions options
)
public function GetPageRanges (
	options : BlobRequestOptions
) : IEnumerable<PageRange>

Parameter

options

An object that specifies any additional options for the request.

Rückgabewert

An enumerable collection of page ranges.

The following example returns the collection of page ranges for a page blob and writes them to the console window.

static void GetPageBlobRanges(Uri blobEndpoint, string accountName, string accountKey)
{
    //Create service client for credentialed access to the Blob service.
    CloudBlobClient blobClient = new CloudBlobClient(blobEndpoint, new StorageCredentialsAccountAndKey(accountName, accountKey));

    //Get a reference to the page blob.
    CloudPageBlob pageBlob = blobClient.GetPageBlobReference("mycontainer/mypageblob");

    foreach (PageRange pageRange in pageBlob.GetPageRanges())
    {
        Console.WriteLine("Starting offset: " + pageRange.StartOffset);
        Console.WriteLine("Ending offset: " + pageRange.EndOffset);
        Console.WriteLine("Content: " + pageRange.ToString());
        Console.WriteLine();
    }
}

The start and end byte offsets for each page range are inclusive.


Alle öffentlichen statischen (freigegebenen in Visual Basic) Member dieses Typs sind threadsicher. Bei Instanzmembern ist die Threadsicherheit nicht gewährleistet.

Entwicklungsplattformen

Windows XP Home Edition, Windows XP Professional, Windows Server 2003, Windows Server 2008 und Windows 2000

Zielplattformen

Fanden Sie dies hilfreich?
(1500 verbleibende Zeichen)
Vielen Dank für Ihr Feedback.

Community-Beiträge

Anzeigen:
© 2014 Microsoft