List of usage examples for com.squareup.okhttp Interceptor interface-usage
From source file com.shopify.buy.data.MockResponseGenerator.java
public class MockResponseGenerator implements Interceptor { /* This class generates a json file containing the http responses that can be used for mock (non-network) testing. To generate the file, do the following: 1. Set ShopifyAndroidTestCase.GENERATE_MOCK_RESPONSES = true
From source file com.taobao.weex.devtools.inspector.network.OkHttpInterceptor.java
/**
* Provides easy integration with <a href="http://square.github.io/okhttp/">OkHttp</a> 2.2.0+
* by way of the new <a href="https://github.com/square/okhttp/wiki/Interceptors">Interceptor</a>
* system. To use:
* <pre>
* OkHttpClient client = new OkHttpClient();
From source file com.taobao.weex.okhttp.WeexOkhttpInterceptor.java
public class WeexOkhttpInterceptor implements Interceptor { private NetworkEventReporter mEventReporter; private final AtomicInteger mNextRequestId = new AtomicInteger(0); public WeexOkhttpInterceptor() {
From source file com.travoca.api.utils.HttpLoggingInterceptor.java
/**
* An OkHttp interceptor which logs request and response information. Can be applied as an
* {@linkplain OkHttpClient#interceptors() application interceptor} or as a
* {@linkplain OkHttpClient#networkInterceptors() network interceptor}.
* <p/>
* The format of the logs created by this class should not be considered stable and may change
From source file com.twodwarfs.retrofitoo.net.HttpLoggingInterceptor.java
/**
* An OkHttp interceptor which logs request and response information. Can be applied as an
* {@linkplain OkHttpClient#interceptors() application interceptor} or as a
* {@linkplain OkHttpClient#networkInterceptors() network interceptor}.
* <p>
* The format of the logs created by this class should not be considered stable and may change
From source file com.vavian.mockretrofitrequests.rest.service.FakeInterceptor.java
/** * */ public class FakeInterceptor implements Interceptor { private final static String TAG = FakeInterceptor.class.getSimpleName();
From source file com.wecanstudio.xdsjs.save.Model.net.LoggingInterceptor.java
public class LoggingInterceptor implements Interceptor { private static final String TAG = "OkHttp"; @Override public Response intercept(Chain chain) throws IOException { Request request = chain.request();
From source file com.xing.api.Oauth1SigningInterceptor.java
/** * Request {@link Interceptor} that handel's Oauth1 request signing. */ final class Oauth1SigningInterceptor implements Interceptor { private static final Pattern CHARACTER_PATTERN = Pattern.compile("\\W"); private static final int NUANCE_BYTES = 32;
From source file com.yandex.disk.rest.LoggingInterceptor.java
public class LoggingInterceptor implements Interceptor { private static final Logger logger = LoggerFactory.getLogger(LoggingInterceptor.class); private static final String SEND_PREFIX = " >> "; private static final String RECEIVE_PREFIX = " << ";
From source file io.fabric8.openshift.client.internal.OpenShiftOAuthInterceptor.java
public class OpenShiftOAuthInterceptor implements Interceptor { private static final String AUTHORIZATION = "Authorization"; private static final String LOCATION = "Location"; private static final String AUTHORIZE_PATH = "oauth/authorize?response_type=token&client_id=openshift-challenging-client";