Interface HTTPInterceptor
-
- All Implemented Interfaces:
public interface HTTPInterceptor
An interceptor for HTTP requests made by the player.
-
-
Method Summary
Modifier and Type Method Description Unit
onRequest(InterceptableHTTPRequest request)
Intercepts an HTTP request before opening the connection, optionally modifying the request. Unit
onResponse(InterceptableHTTPResponse response)
Intercepts an HTTP response before consuming the response body, optionally modifying the response. -
-
Method Detail
-
onRequest
Unit onRequest(InterceptableHTTPRequest request)
Intercepts an HTTP request before opening the connection, optionally modifying the request.
After this method returns, the given request can no longer be modified.
- Parameters:
request
- The mutable HTTP request
-
onResponse
Unit onResponse(InterceptableHTTPResponse response)
Intercepts an HTTP response before consuming the response body, optionally modifying the response.
After this method returns, the given response can no longer be modified.
- Parameters:
response
- The mutable HTTP response
-
-
-
-