/// <summary>
 /// Cancel a service task
 /// </summary>
 /// <remarks>
 /// The service tasks resource is a nested, proxy-only resource representing
 /// work performed by a DMS instance. This method cancels a service task if
 /// it's currently queued or running.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='groupName'>
 /// Name of the resource group
 /// </param>
 /// <param name='serviceName'>
 /// Name of the service
 /// </param>
 /// <param name='taskName'>
 /// Name of the Task
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <ProjectTask> CancelAsync(this IServiceTasksOperations operations, string groupName, string serviceName, string taskName, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CancelWithHttpMessagesAsync(groupName, serviceName, taskName, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }