public class TokenRefreshInterceptor extends Object implements Interceptor
| Constructor and Description |
|---|
TokenRefreshInterceptor(Config config,
HttpClient.Factory factory) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
afterFailure(BasicBuilder headerBuilder,
HttpResponse<?> response)
Called after a websocket failure or by default from a normal request
|
void |
before(BasicBuilder headerBuilder,
HttpHeaders headers)
Called before a request to allow for the manipulation of the request
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitafterFailurepublic static final String NAME
public TokenRefreshInterceptor(Config config, HttpClient.Factory factory)
public void before(BasicBuilder headerBuilder, HttpHeaders headers)
Interceptorbefore in interface InterceptorheaderBuilder - used to modify the requestheaders - the current headerspublic boolean afterFailure(BasicBuilder headerBuilder, HttpResponse<?> response)
InterceptorafterFailure in interface InterceptorheaderBuilder - used to modify the requestresponse - the failed responseCopyright © 2015–2022 Red Hat. All rights reserved.