@Test public void testClientCreation() { OkHttpClient client = HttpClients.getSslAllTrustingClient(); for (int i = 0; i < 10; i++) { assertTrue(client == HttpClients.getSslAllTrustingClient()); } }
public static OkHttpClient getSslAllTrustingClient() { synchronized (LOCK) { if (sslAllTrustingClient == null) { sslAllTrustingClient = createClient(((x509Certificates, s) -> Single.just(true))); } return sslAllTrustingClient; } }
HttpClients { public static OkHttpClient getSslAllTrustingClient() { synchronized (LOCK) { if (sslAllTrustingClient == null) { sslAllTrustingClient = createClient(((x509Certificates, s) -> Single.just(true))); } return sslAllTrustingClient; } } }
HttpClients { public static OkHttpClient getSslAllTrustingClient() { synchronized (LOCK) { if (sslAllTrustingClient == null) { sslAllTrustingClient = createClient(((x509Certificates, s) -> Single.just(true))); } return sslAllTrustingClient; } } private  HttpClients(); }
HttpClients { public static OkHttpClient getSslAllTrustingClient() { synchronized (LOCK) { if (sslAllTrustingClient == null) { sslAllTrustingClient = createClient(((x509Certificates, s) -> Single.just(true))); } return sslAllTrustingClient; } } private  HttpClients(); static OkHttpClient getSslAllTrustingClient(); }
HttpClients { public static OkHttpClient getSslAllTrustingClient() { synchronized (LOCK) { if (sslAllTrustingClient == null) { sslAllTrustingClient = createClient(((x509Certificates, s) -> Single.just(true))); } return sslAllTrustingClient; } } private  HttpClients(); static OkHttpClient getSslAllTrustingClient();  }