CloudQueue.PeekMessagesAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
PeekMessagesAsync(Int32, QueueRequestOptions, OperationContext, CancellationToken) |
Initiates an asynchronous operation to peek messages from the queue. |
PeekMessagesAsync(Int32, QueueRequestOptions, OperationContext) |
Initiates an asynchronous operation to peek messages from the queue. |
PeekMessagesAsync(Int32) |
Initiates an asynchronous operation to peek messages from the queue. |
PeekMessagesAsync(Int32, CancellationToken) |
Initiates an asynchronous operation to peek messages from the queue. |
PeekMessagesAsync(Int32, QueueRequestOptions, OperationContext, CancellationToken)
Initiates an asynchronous operation to peek messages from the queue.
[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<Microsoft.Azure.Storage.Queue.CloudQueueMessage>> PeekMessagesAsync (int messageCount, Microsoft.Azure.Storage.Queue.QueueRequestOptions options, Microsoft.Azure.Storage.OperationContext operationContext, System.Threading.CancellationToken cancellationToken);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member PeekMessagesAsync : int * Microsoft.Azure.Storage.Queue.QueueRequestOptions * Microsoft.Azure.Storage.OperationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
override this.PeekMessagesAsync : int * Microsoft.Azure.Storage.Queue.QueueRequestOptions * Microsoft.Azure.Storage.OperationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
Public Overridable Function PeekMessagesAsync (messageCount As Integer, options As QueueRequestOptions, operationContext As OperationContext, cancellationToken As CancellationToken) As Task(Of IEnumerable(Of CloudQueueMessage))
Parameters
- messageCount
- Int32
The number of messages to peek. The maximum number of messages that may be retrieved at one time is 32.
- options
- QueueRequestOptions
A QueueRequestOptions 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<TResult> object that is an enumerable collection of type CloudQueueMessage that represents the asynchronous operation.
- Attributes
Applies to
PeekMessagesAsync(Int32, QueueRequestOptions, OperationContext)
Initiates an asynchronous operation to peek messages from the queue.
[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<Microsoft.Azure.Storage.Queue.CloudQueueMessage>> PeekMessagesAsync (int messageCount, Microsoft.Azure.Storage.Queue.QueueRequestOptions options, Microsoft.Azure.Storage.OperationContext operationContext);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member PeekMessagesAsync : int * Microsoft.Azure.Storage.Queue.QueueRequestOptions * Microsoft.Azure.Storage.OperationContext -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
override this.PeekMessagesAsync : int * Microsoft.Azure.Storage.Queue.QueueRequestOptions * Microsoft.Azure.Storage.OperationContext -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
Public Overridable Function PeekMessagesAsync (messageCount As Integer, options As QueueRequestOptions, operationContext As OperationContext) As Task(Of IEnumerable(Of CloudQueueMessage))
Parameters
- messageCount
- Int32
The number of messages to peek. The maximum number of messages that may be retrieved at one time is 32.
- options
- QueueRequestOptions
A QueueRequestOptions object that specifies additional options for the request.
- operationContext
- OperationContext
An OperationContext object that represents the context for the current operation.
Returns
A Task<TResult> object that is an enumerable collection of type CloudQueueMessage that represents the asynchronous operation.
- Attributes
Applies to
PeekMessagesAsync(Int32)
Initiates an asynchronous operation to peek messages from the queue.
[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<Microsoft.Azure.Storage.Queue.CloudQueueMessage>> PeekMessagesAsync (int messageCount);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member PeekMessagesAsync : int -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
override this.PeekMessagesAsync : int -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
Public Overridable Function PeekMessagesAsync (messageCount As Integer) As Task(Of IEnumerable(Of CloudQueueMessage))
Parameters
- messageCount
- Int32
The number of messages to peek. The maximum number of messages that may be retrieved at one time is 32.
Returns
A Task<TResult> object that is an enumerable collection of type CloudQueueMessage that represents the asynchronous operation.
- Attributes
Applies to
PeekMessagesAsync(Int32, CancellationToken)
Initiates an asynchronous operation to peek messages from the queue.
[Microsoft.Azure.Storage.DoesServiceRequest]
public virtual System.Threading.Tasks.Task<System.Collections.Generic.IEnumerable<Microsoft.Azure.Storage.Queue.CloudQueueMessage>> PeekMessagesAsync (int messageCount, System.Threading.CancellationToken cancellationToken);
[<Microsoft.Azure.Storage.DoesServiceRequest>]
abstract member PeekMessagesAsync : int * System.Threading.CancellationToken -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
override this.PeekMessagesAsync : int * System.Threading.CancellationToken -> System.Threading.Tasks.Task<seq<Microsoft.Azure.Storage.Queue.CloudQueueMessage>>
Public Overridable Function PeekMessagesAsync (messageCount As Integer, cancellationToken As CancellationToken) As Task(Of IEnumerable(Of CloudQueueMessage))
Parameters
- messageCount
- Int32
The number of messages to peek. The maximum number of messages that may be retrieved at one time is 32.
- cancellationToken
- CancellationToken
A CancellationToken to observe while waiting for a task to complete.
Returns
A Task<TResult> object that is an enumerable collection of type CloudQueueMessage that represents the asynchronous operation.
- Attributes