In order to intercept the network using Ok Http network Lib, we have to use addNetworkInterceptor method to set the interceptor interface.
Following is the issue, when ever doing network request creating new object and explicitly setting interceptor for each request. Facing similar problem with stetho lib also.
Is their a way that once the interceptor is set, it should not be required to set again again for request?
Interceptors are added globally when you configure OkHttpClient. You don't need to repeat this configuration once per request, just once per process start.
In order to intercept the network using Ok Http network Lib, we have to use addNetworkInterceptor method to set the interceptor interface.
Following is the issue, when ever doing network request creating new object and explicitly setting interceptor for each request. Facing similar problem with stetho lib also.
Is their a way that once the interceptor is set, it should not be required to set again again for request?