Code example for SSLContext

Methods: init

0
                    return null; 
                } 
 
            }; 
 
            sslContext.init(null, new TrustManager[] {tm}, null);
        } 
 
        @Override 
        public Socket createSocket(Socket socket, String host, int port, boolean autoClose) throws IOException, UnknownHostException {
            return sslContext.getSocketFactory().createSocket(socket, host, port, autoClose);
        } 
 
        @Override 
        public Socket createSocket() throws IOException {
            return sslContext.getSocketFactory().createSocket();
        } 
 
    } 
     
    public HttpClient getHttpClient() {