private static boolean isHostDnsName ( URI uri ) { String host = uri . getHost ( ) ; for ( int i = 0 ; i < host . length ( ) ; i ++ ) { char hostChar = host . charAt ( i ) ; if ( ! Character . isDigit ( hostChar ) && ! ( hostChar == ' ' ) ) { return true ; } } return false ; }
Returns a boolean indicating whether the host of the specified URI is DNS .