Share via


CloudPageBlob.WritePagesAsync Method

Definition

Overloads

WritePagesAsync(Stream, Int64, Checksum, AccessCondition, BlobRequestOptions, OperationContext, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

WritePagesAsync(Stream, Int64, Checksum, AccessCondition, BlobRequestOptions, OperationContext)

Initiates an asynchronous operation to write pages to a page blob.

WritePagesAsync(Stream, Int64, Checksum, AccessCondition, BlobRequestOptions, OperationContext, IProgress<StorageProgress>, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

WritePagesAsync(Stream, Int64, Checksum)

Initiates an asynchronous operation to write pages to a page blob.

WritePagesAsync(Stream, Int64, Checksum, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

WritePagesAsync(Uri, Int64, Int64, Int64, Checksum, AccessCondition, AccessCondition, BlobRequestOptions, OperationContext, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

WritePagesAsync(Stream, Int64, Checksum, AccessCondition, BlobRequestOptions, OperationContext, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task WritePagesAsync (System.IO.Stream pageData, long startOffset, Microsoft.Azure.Storage.Shared.Protocol.Checksum contentChecksum, Microsoft.Azure.Storage.AccessCondition accessCondition, Microsoft.Azure.Storage.Blob.BlobRequestOptions options, Microsoft.Azure.Storage.OperationContext operationContext, System.Threading.CancellationToken cancellationToken);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function WritePagesAsync (pageData As Stream, startOffset As Long, contentChecksum As Checksum, accessCondition As AccessCondition, options As BlobRequestOptions, operationContext As OperationContext, cancellationToken As CancellationToken) As Task

Parameters

pageData
Stream

A Stream object providing the page data.

startOffset
Int64

The offset at which to begin writing, in bytes. The offset must be a multiple of 512.

contentChecksum
Checksum

A hash value used to ensure transactional integrity. May be null or Checksum.None

accessCondition
AccessCondition

An AccessCondition object that represents the condition that must be met in order for the request to proceed. If null, no condition is used.

options
BlobRequestOptions

A BlobRequestOptions object that specifies additional options for the request.

operationContext
OperationContext

An OperationContext object that represents the context for the current operation.

cancellationToken
CancellationToken

A CancellationToken to observe while waiting for a task to complete.

Returns

A Task object that represents the asynchronous operation.

Attributes

Remarks

Clients may send the content checksum headers for a given operation as a means to ensure transactional integrity over the wire. The contentChecksum parameter permits clients who already have access to a pre-computed checksum value for a given byte range to provide it. If the BlobRequestOptions.UseTransactionalMd5 or BlobRequestOptions.UseTransactionalCrc64 properties are set to true and the corresponding content parameter is set to null, then the client library will calculate the checksum value internally.

Applies to

WritePagesAsync(Stream, Int64, Checksum, AccessCondition, BlobRequestOptions, OperationContext)

Initiates an asynchronous operation to write pages to a page blob.

[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task WritePagesAsync (System.IO.Stream pageData, long startOffset, Microsoft.Azure.Storage.Shared.Protocol.Checksum contentChecksum, Microsoft.Azure.Storage.AccessCondition accessCondition, Microsoft.Azure.Storage.Blob.BlobRequestOptions options, Microsoft.Azure.Storage.OperationContext operationContext);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext -> System.Threading.Tasks.Task
override this.WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext -> System.Threading.Tasks.Task
Public Overridable Function WritePagesAsync (pageData As Stream, startOffset As Long, contentChecksum As Checksum, accessCondition As AccessCondition, options As BlobRequestOptions, operationContext As OperationContext) As Task

Parameters

pageData
Stream

A Stream object providing the page data.

startOffset
Int64

The offset at which to begin writing, in bytes. The offset must be a multiple of 512.

contentChecksum
Checksum

A hash value used to ensure transactional integrity. May be null or Checksum.None

accessCondition
AccessCondition

An AccessCondition object that represents the condition that must be met in order for the request to proceed. If null, no condition is used.

options
BlobRequestOptions

A BlobRequestOptions object that specifies additional options for the request.

operationContext
OperationContext

An OperationContext object that represents the context for the current operation.

Returns

A Task object that represents the asynchronous operation.

Attributes

Remarks

Clients may send the content checksum headers for a given operation as a means to ensure transactional integrity over the wire. The contentChecksum parameter permits clients who already have access to a pre-computed checksum value for a given byte range to provide it. If the BlobRequestOptions.UseTransactionalMd5 or BlobRequestOptions.UseTransactionalCrc64 properties are set to true and the corresponding content parameter is set to null, then the client library will calculate the checksum value internally.

Applies to

WritePagesAsync(Stream, Int64, Checksum, AccessCondition, BlobRequestOptions, OperationContext, IProgress<StorageProgress>, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task WritePagesAsync (System.IO.Stream pageData, long startOffset, Microsoft.Azure.Storage.Shared.Protocol.Checksum contentChecksum, Microsoft.Azure.Storage.AccessCondition accessCondition, Microsoft.Azure.Storage.Blob.BlobRequestOptions options, Microsoft.Azure.Storage.OperationContext operationContext, IProgress<Microsoft.Azure.Storage.Core.Util.StorageProgress> progressHandler, System.Threading.CancellationToken cancellationToken);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext * IProgress<Microsoft.Azure.Storage.Core.Util.StorageProgress> * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext * IProgress<Microsoft.Azure.Storage.Core.Util.StorageProgress> * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function WritePagesAsync (pageData As Stream, startOffset As Long, contentChecksum As Checksum, accessCondition As AccessCondition, options As BlobRequestOptions, operationContext As OperationContext, progressHandler As IProgress(Of StorageProgress), cancellationToken As CancellationToken) As Task

Parameters

pageData
Stream

A Stream object providing the page data.

startOffset
Int64

The offset at which to begin writing, in bytes. The offset must be a multiple of 512.

contentChecksum
Checksum

A hash value used to ensure transactional integrity. May be null or Checksum.None

accessCondition
AccessCondition

An AccessCondition object that represents the condition that must be met in order for the request to proceed. If null, no condition is used.

options
BlobRequestOptions

A BlobRequestOptions object that specifies additional options for the request.

operationContext
OperationContext

An OperationContext object that represents the context for the current operation.

progressHandler
IProgress<StorageProgress>

A IProgress<T> object to handle StorageProgress messages.

cancellationToken
CancellationToken

A CancellationToken to observe while waiting for a task to complete.

Returns

A Task object that represents the asynchronous operation.

Attributes

Remarks

Clients may send the content checksum headers for a given operation as a means to ensure transactional integrity over the wire. The contentChecksum parameter permits clients who already have access to a pre-computed checksum value for a given byte range to provide it. If the BlobRequestOptions.UseTransactionalMd5 or BlobRequestOptions.UseTransactionalCrc64 properties are set to true and the corresponding content parameter is set to null, then the client library will calculate the checksum value internally.

Applies to

WritePagesAsync(Stream, Int64, Checksum)

Initiates an asynchronous operation to write pages to a page blob.

[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task WritePagesAsync (System.IO.Stream pageData, long startOffset, Microsoft.Azure.Storage.Shared.Protocol.Checksum contentChecksum);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum -> System.Threading.Tasks.Task
override this.WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum -> System.Threading.Tasks.Task
Public Overridable Function WritePagesAsync (pageData As Stream, startOffset As Long, contentChecksum As Checksum) As Task

Parameters

pageData
Stream

A Stream object providing the page data.

startOffset
Int64

The offset at which to begin writing, in bytes. The offset must be a multiple of 512.

contentChecksum
Checksum

An optional hash value used to ensure transactional integrity. May be null or Checksum.None

Returns

A Task object that represents the asynchronous operation.

Attributes

Remarks

Clients may send the content checksum headers for a given operation as a means to ensure transactional integrity over the wire. The contentChecksum parameter permits clients who already have access to a pre-computed checksum value for a given byte range to provide it. If the BlobRequestOptions.UseTransactionalMd5 or BlobRequestOptions.UseTransactionalCrc64 properties are set to true and the corresponding content parameter is set to null, then the client library will calculate the checksum value internally.

Applies to

WritePagesAsync(Stream, Int64, Checksum, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task WritePagesAsync (System.IO.Stream pageData, long startOffset, Microsoft.Azure.Storage.Shared.Protocol.Checksum contentChecksum, System.Threading.CancellationToken cancellationToken);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.WritePagesAsync : System.IO.Stream * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function WritePagesAsync (pageData As Stream, startOffset As Long, contentChecksum As Checksum, cancellationToken As CancellationToken) As Task

Parameters

pageData
Stream

A Stream object providing the page data.

startOffset
Int64

The offset at which to begin writing, in bytes. The offset must be a multiple of 512.

contentChecksum
Checksum

A hash value used to ensure transactional integrity. May be null or Checksum.None

cancellationToken
CancellationToken

A CancellationToken to observe while waiting for a task to complete.

Returns

A Task object that represents the asynchronous operation.

Attributes

Remarks

Clients may send the content checksum headers for a given operation as a means to ensure transactional integrity over the wire. The contentChecksum parameter permits clients who already have access to a pre-computed checksum value for a given byte range to provide it. If the BlobRequestOptions.UseTransactionalMd5 or BlobRequestOptions.UseTransactionalCrc64 properties are set to true and the corresponding content parameter is set to null, then the client library will calculate the checksum value internally.

Applies to

WritePagesAsync(Uri, Int64, Int64, Int64, Checksum, AccessCondition, AccessCondition, BlobRequestOptions, OperationContext, CancellationToken)

Initiates an asynchronous operation to write pages to a page blob.

[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task WritePagesAsync (Uri sourceUri, long offset, long count, long startOffset, Microsoft.Azure.Storage.Shared.Protocol.Checksum sourceContentChecksum, Microsoft.Azure.Storage.AccessCondition sourceAccessCondition, Microsoft.Azure.Storage.AccessCondition destAccessCondition, Microsoft.Azure.Storage.Blob.BlobRequestOptions options, Microsoft.Azure.Storage.OperationContext operationContext, System.Threading.CancellationToken cancellationToken);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member WritePagesAsync : Uri * int64 * int64 * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.WritePagesAsync : Uri * int64 * int64 * int64 * Microsoft.Azure.Storage.Shared.Protocol.Checksum * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.AccessCondition * Microsoft.Azure.Storage.Blob.BlobRequestOptions * Microsoft.Azure.Storage.OperationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function WritePagesAsync (sourceUri As Uri, offset As Long, count As Long, startOffset As Long, sourceContentChecksum As Checksum, sourceAccessCondition As AccessCondition, destAccessCondition As AccessCondition, options As BlobRequestOptions, operationContext As OperationContext, cancellationToken As CancellationToken) As Task

Parameters

sourceUri
Uri

A Uri specifying the absolute URI to the source blob.

offset
Int64

The byte offset in the source at which to begin retrieving content.

count
Int64

The number of bytes from the source to return, or null to return all bytes through the end of the blob.

startOffset
Int64

The offset at which to begin writing, in bytes. The offset must be a multiple of 512.

sourceContentChecksum
Checksum
sourceAccessCondition
AccessCondition

An AccessCondition object that represents the access conditions for the source blob. If null, no condition is used.

destAccessCondition
AccessCondition

An AccessCondition object that represents the access conditions for the destination blob. If null, no condition is used.

options
BlobRequestOptions

A BlobRequestOptions object that specifies additional options for the request.

operationContext
OperationContext

An OperationContext object that represents the context for the current operation.

cancellationToken
CancellationToken

A CancellationToken to observe while waiting for a task to complete.

Returns

A Task object that represents the asynchronous operation.

Attributes

Applies to