Class PollResult<T>

java.lang.Object
com.azure.core.management.polling.PollResult<T>
Type Parameters:
T - the type of the value

public final class PollResult<T> extends Object
Type representing result (succeeded or failed result) of a long-running-poll operation.
  • Constructor Details

    • PollResult

      public PollResult(T value)
      Creates PollResult.
      Parameters:
      value - the service returned value for a succeeded poll operation
    • PollResult

      public PollResult(PollResult.Error error)
      Creates PollResult.
      Parameters:
      error - describes the error that poll-operation received from the service
  • Method Details

    • getValue

      public T getValue()
      Get the service returned value when poll-operation succeeded.
      Returns:
      the value
    • getError

      public PollResult.Error getError()
      Get the error description when poll-operation receives error from service.
      Returns:
      the error