All Implemented Interfaces:
Writeable, RefCounted, TaskAwareRequest

public class CancelTasksRequest extends BaseTasksRequest<CancelTasksRequest>
A request to cancel tasks
  • Field Details

  • Constructor Details

  • Method Details

    • writeTo

      public void writeTo(StreamOutput out) throws IOException
      Description copied from interface: Writeable
      Write this into the StreamOutput.
      Specified by:
      writeTo in interface Writeable
      writeTo in class BaseTasksRequest<CancelTasksRequest>
    • match

      public boolean match(Task task)
      match in class BaseTasksRequest<CancelTasksRequest>
    • setReason

      public CancelTasksRequest setReason(String reason)
      Set the reason for canceling the task.
    • getReason

      public String getReason()
      The reason for canceling the task.
    • setWaitForCompletion

      public void setWaitForCompletion(boolean waitForCompletion)
      If true, the request blocks until the cancellation of the task and its descendant tasks is completed. Otherwise, the request can return soon after the cancellation is started. Defaults to false.
    • waitForCompletion

      public boolean waitForCompletion()
    • getDescription

      public String getDescription()
      Description copied from interface: TaskAwareRequest
      Returns optional description of the request to be displayed by the task manager