Class WaitersRuntime.ResponseStatusAcceptor

java.lang.Object
software.amazon.awssdk.services.mediaconnect.waiters.internal.WaitersRuntime.ResponseStatusAcceptor
All Implemented Interfaces:
WaiterAcceptor<SdkResponse>
Enclosing class:
WaitersRuntime

public static final class WaitersRuntime.ResponseStatusAcceptor extends Object implements WaiterAcceptor<SdkResponse>
A WaiterAcceptor implementation that checks for a specific HTTP response status, regardless of whether it's reported by a response or an exception.
  • Constructor Details

    • ResponseStatusAcceptor

      public ResponseStatusAcceptor(int statusCode, WaiterState waiterState)
  • Method Details

    • waiterState

      public WaiterState waiterState()
      Specified by:
      waiterState in interface WaiterAcceptor<SdkResponse>
      Returns:
      the next WaiterState that the waiter should be transitioned to
    • matches

      public boolean matches(SdkResponse response)
      Description copied from interface: WaiterAcceptor
      Check to see if the response matches with the expected state defined by this acceptor
      Specified by:
      matches in interface WaiterAcceptor<SdkResponse>
      Parameters:
      response - the response to inspect
      Returns:
      whether it accepts the response
    • matches

      public boolean matches(Throwable throwable)
      Description copied from interface: WaiterAcceptor
      Check to see if the exception matches the expected state defined by this acceptor
      Specified by:
      matches in interface WaiterAcceptor<SdkResponse>
      Parameters:
      throwable - the exception to inspect
      Returns:
      whether it accepts the throwable