Code example for Proxy

0
			String proxyHost = android.net.Proxy.getDefaultHost();
			int port = android.net.Proxy.getDefaultPort();
			if (proxyHost != null)
			{ 
				final InetSocketAddress sa = new InetSocketAddress(proxyHost, port);
				mProxy = new Proxy(Proxy.Type.HTTP, sa);
			} 
        } 
	} 
 
	private void setDefaultHostnameVerifier() 
	{ 
		// 
		HostnameVerifier hv = new HostnameVerifier() 
		{ 
			public boolean verify(String hostname, SSLSession session)
			{ 
				return true; 
			} 
		};