Package com.helger.httpclient
Class HttpDebugger
java.lang.Object
com.helger.httpclient.HttpDebugger
Some debugging for HTTP requests. Currently used in
HttpClientManager.- Author:
- Philip Helger
-
Method Summary
Modifier and TypeMethodDescriptionstatic voidafterRequest(org.apache.hc.core5.http.ClassicHttpRequest aRequest, Object aResponse, Throwable aCaughtException) Call after an invocation.static voidbeforeRequest(org.apache.hc.core5.http.ClassicHttpRequest aRequest, org.apache.hc.core5.http.protocol.HttpContext aHttpContext) Call before an invocationstatic booleanstatic voidsetEnabled(boolean bEnabled)
-
Method Details
-
isEnabled
public static boolean isEnabled() -
setEnabled
public static void setEnabled(boolean bEnabled) -
beforeRequest
public static void beforeRequest(@Nonnull org.apache.hc.core5.http.ClassicHttpRequest aRequest, @Nullable org.apache.hc.core5.http.protocol.HttpContext aHttpContext) Call before an invocation- Parameters:
aRequest- The request to be executed. May not benull.aHttpContext- The special HTTP content for this call. May benull.
-
afterRequest
public static void afterRequest(@Nonnull org.apache.hc.core5.http.ClassicHttpRequest aRequest, @Nullable Object aResponse, @Nullable Throwable aCaughtException) Call after an invocation.- Parameters:
aRequest- The source request. May not be modified internally. May not benull.aResponse- The response object retrieved. May be anything includingnull(e.g. in case of exception).aCaughtException- The caught exception. May benull.- Since:
- 8.8.2
-