/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }
/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Returns the address of a host according to the given host string name * {@code host}. The host string may be either a machine name or a dotted * string IP address. If the latter, the {@code hostName} field is * determined upon demand. {@code host} can be {@code null} which means that * an address of the loopback interface is returned. * * @param host * the hostName to be resolved to an address or {@code null}. * @return the {@code InetAddress} instance representing the host. * @throws UnknownHostException * if the address lookup fails. */ public static InetAddress getByName(String host) throws UnknownHostException { return getAllByNameImpl(host)[0]; }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }
/** * Gets all IP addresses associated with the given {@code host} identified * by name or literal IP address. The IP address is resolved by the * configured name service. If the host name is empty or {@code null} an * {@code UnknownHostException} is thrown. If the host name is a literal IP * address string an array with the corresponding single {@code InetAddress} * is returned. * * @param host the hostname or literal IP string to be resolved. * @return the array of addresses associated with the specified host. * @throws UnknownHostException if the address lookup fails. */ public static InetAddress[] getAllByName(String host) throws UnknownHostException { return getAllByNameImpl(host).clone(); }