C#C++F#VB
CloudQueue.::..AddMessageAsync Method (CloudQueueMessage, Nullable<TimeSpan>, Nullable<TimeSpan>, QueueRequestOptions, OperationContext, CancellationToken)(CloudQueueMessage^, Nullable<TimeSpan>, Nullable<TimeSpan>, QueueRequestOptions^, OperationContext^, CancellationToken)(CloudQueueMessage, Nullable<TimeSpan>, Nullable<TimeSpan>, QueueRequestOptions, OperationContext, CancellationToken)(CloudQueueMessage, Nullable(Of TimeSpan), Nullable(Of TimeSpan), QueueRequestOptions, OperationContext, CancellationToken)
Initiates an asynchronous operation to add a message to the queue.
Assembly: Microsoft.WindowsAzure.Storage (in Microsoft.WindowsAzure.Storage.dll)
Syntax
[DoesServiceRequestAttribute] public virtual Task AddMessageAsync( CloudQueueMessage message, Nullable<TimeSpan> timeToLive, Nullable<TimeSpan> initialVisibilityDelay, QueueRequestOptions options, OperationContext operationContext, CancellationToken cancellationToken )
C++
public: [DoesServiceRequestAttribute] virtual Task^ AddMessageAsync( CloudQueueMessage^ message, Nullable<TimeSpan> timeToLive, Nullable<TimeSpan> initialVisibilityDelay, QueueRequestOptions^ options, OperationContext^ operationContext, CancellationToken cancellationToken )
[<DoesServiceRequestAttribute>] abstract AddMessageAsync : message:CloudQueueMessage * timeToLive:Nullable<TimeSpan> * initialVisibilityDelay:Nullable<TimeSpan> * options:QueueRequestOptions * operationContext:OperationContext * cancellationToken:CancellationToken -> Task [<DoesServiceRequestAttribute>] override AddMessageAsync : message:CloudQueueMessage * timeToLive:Nullable<TimeSpan> * initialVisibilityDelay:Nullable<TimeSpan> * options:QueueRequestOptions * operationContext:OperationContext * cancellationToken:CancellationToken -> Task
<DoesServiceRequestAttribute> Public Overridable Function AddMessageAsync ( message As CloudQueueMessage, timeToLive As Nullable(Of TimeSpan), initialVisibilityDelay As Nullable(Of TimeSpan), options As QueueRequestOptions, operationContext As OperationContext, cancellationToken As CancellationToken ) As Task
Parameters
- message
-
Type:
Microsoft.WindowsAzure.Storage.Queue.CloudQueueMessageMicrosoft.WindowsAzure.Storage.Queue::CloudQueueMessage^Microsoft.WindowsAzure.Storage.Queue.CloudQueueMessageMicrosoft.WindowsAzure.Storage.Queue.CloudQueueMessage
A CloudQueueMessage object.
- timeToLive
-
Type:
System.Nullable<TimeSpan>System::Nullable<TimeSpan>System.Nullable<TimeSpan>System.Nullable(Of TimeSpan)
A TimeSpan specifying the maximum time to allow the message to be in the queue, or null.
- initialVisibilityDelay
-
Type:
System.Nullable<TimeSpan>System::Nullable<TimeSpan>System.Nullable<TimeSpan>System.Nullable(Of TimeSpan)
A TimeSpan specifying the interval of time from now during which the message will be invisible. If null then the message will be visible immediately.
- options
-
Type:
Microsoft.WindowsAzure.Storage.Queue.QueueRequestOptionsMicrosoft.WindowsAzure.Storage.Queue::QueueRequestOptions^Microsoft.WindowsAzure.Storage.Queue.QueueRequestOptionsMicrosoft.WindowsAzure.Storage.Queue.QueueRequestOptions
A QueueRequestOptions object that specifies additional options for the request.
- operationContext
-
Type:
Microsoft.WindowsAzure.Storage.OperationContextMicrosoft.WindowsAzure.Storage::OperationContext^Microsoft.WindowsAzure.Storage.OperationContextMicrosoft.WindowsAzure.Storage.OperationContext
An OperationContext object that represents the context for the current operation.
- cancellationToken
-
Type:
System.Threading.CancellationTokenSystem.Threading::CancellationTokenSystem.Threading.CancellationTokenSystem.Threading.CancellationToken
A CancellationToken to observe while waiting for a task to complete.
Return Value
Type: System.Threading.Tasks.TaskSystem.Threading.Tasks::Task^System.Threading.Tasks.TaskSystem.Threading.Tasks.TaskA Task object that represents the asynchronous operation.