public synchronized final String getHost ( ) { if ( host == null ) { if ( getEndpointAddress ( ) != null && ! getEndpointAddress ( ) . isUnresolved ( ) ) { host = getEndpointAddress ( ) . getHostName ( ) ; } if ( host == null && httpURI != null ) { try { host = ( new URL ( httpURI ) ) . getHost ( ) ; } catch ( MalformedURLException e ) { logger . debug ( "Malformed URL" , e ) ; } } } return host ; }
Returns the host to which we are connecting .