public static String parseHost(final String address) {
        int ep = address.indexOf(":");
        if (ep == -1 || ep == 0) {
            throw new IllegalArgumentException("invalid address '" + address + "'");
        }
        return address.substring(0, ep).trim();
    }
public static String parseHost(final String address) {
        int ep = address.indexOf(":");
        if (ep == -1 || ep == 0) {
            throw new IllegalArgumentException("invalid address '" + address + "'");
        }
        return address.substring(0, ep).trim();
    }
public static String parseHost ( final String address ) { int ep = address . indexOf ( ":" ) ; if ( ep == - 1 || ep == 0 ) { throw new IllegalArgumentException ( "invalid address '" + address + "'" ) ; } return address . substring ( 0 , ep ) . trim ( ) ; }
Parses the host.

@param address the address
@return the string
Parses the host .