-
- All Implemented Interfaces:
-
com.mobwith.httpmodule.Interceptor.Chain
public final class RealInterceptorChain implements Interceptor.Chain
A concrete interceptor chain that carries the entire interceptor chain: all application interceptors, the OkHttp core, all network interceptors, and finally the network caller.
-
-
Constructor Summary
Constructors Constructor Description RealInterceptorChain(List<Interceptor> interceptors, StreamAllocation streamAllocation, HttpCodec httpCodec, RealConnection connection, int index, MobonRequest mobonRequest, Call call, EventListener eventListener, int connectTimeout, int readTimeout, int writeTimeout)
-
Method Summary
Modifier and Type Method Description Connectionconnection()Returns the connection the mobonRequest will be executed on. intconnectTimeoutMillis()Interceptor.ChainwithConnectTimeout(int timeout, TimeUnit unit)intreadTimeoutMillis()Interceptor.ChainwithReadTimeout(int timeout, TimeUnit unit)intwriteTimeoutMillis()Interceptor.ChainwithWriteTimeout(int timeout, TimeUnit unit)StreamAllocationstreamAllocation()HttpCodechttpStream()Callcall()EventListenereventListener()MobonRequestrequest()MobonResponseproceed(MobonRequest mobonRequest)MobonResponseproceed(MobonRequest mobonRequest, StreamAllocation streamAllocation, HttpCodec httpCodec, RealConnection connection)-
-
Constructor Detail
-
RealInterceptorChain
RealInterceptorChain(List<Interceptor> interceptors, StreamAllocation streamAllocation, HttpCodec httpCodec, RealConnection connection, int index, MobonRequest mobonRequest, Call call, EventListener eventListener, int connectTimeout, int readTimeout, int writeTimeout)
-
-
Method Detail
-
connection
Connection connection()
Returns the connection the mobonRequest will be executed on. This is only available in the chainsof network interceptors; for application interceptors this is always null.
-
connectTimeoutMillis
int connectTimeoutMillis()
-
withConnectTimeout
Interceptor.Chain withConnectTimeout(int timeout, TimeUnit unit)
-
readTimeoutMillis
int readTimeoutMillis()
-
withReadTimeout
Interceptor.Chain withReadTimeout(int timeout, TimeUnit unit)
-
writeTimeoutMillis
int writeTimeoutMillis()
-
withWriteTimeout
Interceptor.Chain withWriteTimeout(int timeout, TimeUnit unit)
-
streamAllocation
StreamAllocation streamAllocation()
-
httpStream
HttpCodec httpStream()
-
eventListener
EventListener eventListener()
-
request
MobonRequest request()
-
proceed
MobonResponse proceed(MobonRequest mobonRequest)
-
proceed
MobonResponse proceed(MobonRequest mobonRequest, StreamAllocation streamAllocation, HttpCodec httpCodec, RealConnection connection)
-
-
-
-