Interface PortableHttpResponse


public interface PortableHttpResponse
This interface exposes the commonalities between the Apache httpasyncclient and Netty and R2 client.
  • Method Details

    • getStatusCode

      int getStatusCode()
      Returns:
      Status code of the response, like 200, 400, 500 etc.
    • getContentInByteBuf

      io.netty.buffer.ByteBuf getContentInByteBuf() throws IOException
      Returns the response as ByteBuf.
      Returns:
      Throws:
      IOException
    • containsHeader

      boolean containsHeader(String headerName)
      Parameters:
      headerName -
      Returns:
      whether response contains header name specified in the parameters
    • getFirstHeader

      String getFirstHeader(String headerName)
      Parameters:
      headerName -
      Returns:
      the value of the first header for header name specified in the parameters