@Test public void interceptorRequest_AnyRequestBuilder_ShouldApplyAllRegisteredInterceptors() { RequestInterceptorContext requestBuilder = mock(RequestInterceptorContext.class); engine.interceptRequest(requestBuilder); verify(requestInterceptor).intercept(requestBuilder); }
public void interceptRequest(RequestInterceptorContext request) { for (RequestInterceptor interceptor : interceptorManager.getRequestInterceptors()) { interceptor.intercept(request); } }
InterceptorEngine { public void interceptRequest(RequestInterceptorContext request) { for (RequestInterceptor interceptor : interceptorManager.getRequestInterceptors()) { interceptor.intercept(request); } } }
InterceptorEngine { public void interceptRequest(RequestInterceptorContext request) { for (RequestInterceptor interceptor : interceptorManager.getRequestInterceptors()) { interceptor.intercept(request); } } InterceptorEngine(InterceptorManagerImpl interceptorManager); }
InterceptorEngine { public void interceptRequest(RequestInterceptorContext request) { for (RequestInterceptor interceptor : interceptorManager.getRequestInterceptors()) { interceptor.intercept(request); } } InterceptorEngine(InterceptorManagerImpl interceptorManager); void interceptRequest(RequestInterceptorContext request); void interceptResponse(Request request, ResponseInterceptorContext response); }
InterceptorEngine { public void interceptRequest(RequestInterceptorContext request) { for (RequestInterceptor interceptor : interceptorManager.getRequestInterceptors()) { interceptor.intercept(request); } } InterceptorEngine(InterceptorManagerImpl interceptorManager); void interceptRequest(RequestInterceptorContext request); void interceptResponse(Request request, ResponseInterceptorContext response);  }