Package com.github.kevinsawicki.http
Class HttpRequest.Operation<V>
- java.lang.Object
-
- com.github.kevinsawicki.http.HttpRequest.Operation<V>
-
- Type Parameters:
V
-
- All Implemented Interfaces:
java.util.concurrent.Callable<V>
- Direct Known Subclasses:
HttpRequest.CloseOperation
,HttpRequest.FlushOperation
- Enclosing class:
- HttpRequest
protected abstract static class HttpRequest.Operation<V> extends java.lang.Object implements java.util.concurrent.Callable<V>
Operation that handles executing a callback once complete and handling nested exceptions
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
Operation()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description V
call()
protected abstract void
done()
Operation complete callbackprotected abstract V
run()
Run operation
-
-
-
Method Detail
-
run
protected abstract V run() throws HttpRequest.HttpRequestException, java.io.IOException
Run operation- Returns:
- result
- Throws:
HttpRequest.HttpRequestException
java.io.IOException
-
done
protected abstract void done() throws java.io.IOException
Operation complete callback- Throws:
java.io.IOException
-
call
public V call() throws HttpRequest.HttpRequestException
- Specified by:
call
in interfacejava.util.concurrent.Callable<V>
- Throws:
HttpRequest.HttpRequestException
-
-