Class PlainHttpUrlConnectionExecutor

java.lang.Object
org.dmfs.httpessentials.httpurlconnection.PlainHttpUrlConnectionExecutor
All Implemented Interfaces:
org.dmfs.httpessentials.client.HttpRequestExecutor

public final class PlainHttpUrlConnectionExecutor extends Object implements org.dmfs.httpessentials.client.HttpRequestExecutor
An HttpRequestExecutor that's based on Java's HttpUrlConnection.

Note that this implementation is constrained by the underlying HttpURLConnection implementation. In particular that means you should not rely on being able to use certain HTTP methods like PROPFIND. Standard HTTP methods should always work though.

Also note that this, by convention, won't follow redirects.

  • Constructor Details

  • Method Details

    • execute

      public <T> T execute(URI uri, org.dmfs.httpessentials.client.HttpRequest<T> request) throws IOException, org.dmfs.httpessentials.exceptions.ProtocolError, org.dmfs.httpessentials.exceptions.ProtocolException
      Specified by:
      execute in interface org.dmfs.httpessentials.client.HttpRequestExecutor
      Throws:
      IOException
      org.dmfs.httpessentials.exceptions.ProtocolError
      org.dmfs.httpessentials.exceptions.ProtocolException