Package io.jenkins.plugins.okhttp.api
Interface ResponseConverter<T>
-
- Type Parameters:
T
- the result type of the conversion
public interface ResponseConverter<T>
A response converter allows to convert a
Response
to another object.To be passed to
OkHttpFuture
to handle the HTTP response.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description T
onResponse(okhttp3.Call call, okhttp3.Response response)
Called when the HTTP request finishes successfully and there is a response to process.
-
-
-
Method Detail
-
onResponse
@CheckForNull T onResponse(okhttp3.Call call, okhttp3.Response response) throws IOException
Called when the HTTP request finishes successfully and there is a response to process.- Parameters:
call
- theCall
object that originated the HTTP request.response
- HTTP response- Returns:
- the parsed object (nullable)
- Throws:
IOException
-
-