private Proxy getProxyForUrl ( String requestUrl ) { List < Proxy > proxies = props . getProxies ( ) ; if ( proxies == null || proxies . isEmpty ( ) ) { return null ; } final URI uri = URI . create ( requestUrl ) ; for ( Proxy proxy : proxies ) { if ( ! proxy . isNonProxyHost ( uri . getHost ( ) ) ) { return proxy ; } } return null ; }
Get proxy for given URL