Class RuntimeHttpUtils

java.lang.Object
com.amazonaws.util.RuntimeHttpUtils

public class RuntimeHttpUtils extends Object
  • Constructor Details

    • RuntimeHttpUtils

      public RuntimeHttpUtils()
  • Method Details

    • fetchFile

      public static InputStream fetchFile(URI uri, ClientConfiguration config) throws IOException
      Fetches a file from the URI given and returns an input stream to it.
      Parameters:
      uri - the uri of the file to fetch
      config - optional configuration overrides
      Returns:
      an InputStream containing the retrieved data
      Throws:
      IOException - on error
    • toUri

      public static URI toUri(String endpoint, ClientConfiguration config)
      Returns an URI for the given endpoint. Prefixes the protocol if the endpoint given does not have it.
      Throws:
      IllegalArgumentException - if the inputs are null.