Package org.apache.http.nio.reactor
Interface SessionRequestCallback
-
public interface SessionRequestCallback
SessionRequestCallback interface can be used to get notifications of completion of session requests asynchronously without having to wait for it, blocking the current thread of execution.- Since:
- 4.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
cancelled(SessionRequest request)
Triggered on cancellation of aSessionRequest
.void
completed(SessionRequest request)
Triggered on successful completion of aSessionRequest
.void
failed(SessionRequest request)
Triggered on unsuccessful completion aSessionRequest
.void
timeout(SessionRequest request)
Triggered if aSessionRequest
times out.
-
-
-
Method Detail
-
completed
void completed(SessionRequest request)
Triggered on successful completion of aSessionRequest
. TheSessionRequest.getSession()
method can now be used to obtain the new I/O session.- Parameters:
request
- session request.
-
failed
void failed(SessionRequest request)
Triggered on unsuccessful completion aSessionRequest
. TheSessionRequest.getException()
method can now be used to obtain the cause of the error.- Parameters:
request
- session request.
-
timeout
void timeout(SessionRequest request)
Triggered if aSessionRequest
times out.- Parameters:
request
- session request.
-
cancelled
void cancelled(SessionRequest request)
Triggered on cancellation of aSessionRequest
.- Parameters:
request
- session request.
-
-