Class TaskGroup.InvocationContext

java.lang.Object
com.microsoft.azure.management.resources.fluentcore.dag.TaskGroup.InvocationContext
Enclosing class:
TaskGroup

public static final class TaskGroup.InvocationContext extends Object
A mutable type that can be used to pass data around task items during the invocation of the TaskGroup.
  • Field Details

  • Method Details

    • taskGroup

      public TaskGroup taskGroup()
      Returns:
      the TaskGroup this invocation context associated with.
    • withTerminateOnErrorStrategy

      public TaskGroup.InvocationContext withTerminateOnErrorStrategy(TaskGroupTerminateOnErrorStrategy strategy)
      Sets the group termination strategy to use on error.
      Parameters:
      strategy - the strategy
      Returns:
      the context
    • terminateOnErrorStrategy

      public TaskGroupTerminateOnErrorStrategy terminateOnErrorStrategy()
      Returns:
      the termination strategy to use upon error during the current invocation of the TaskGroup.
    • put

      public void put(String key, Object value)
      Put a key-value in the context.
      Parameters:
      key - the key
      value - the value
    • get

      public Object get(String key)
      Get a value in the context with the given key.
      Parameters:
      key - the key
      Returns:
      value with the given key if exists, null otherwise.
    • hasKey

      public boolean hasKey(String key)
      Check existence of a key in the context.
      Parameters:
      key - the key
      Returns:
      true if the key exists, false otherwise.