public interface DnsResolver
| Modifier and Type | Method and Description |
|---|---|
InetAddress[] |
resolve(String host)
返回指定主机名的IP地址,如果给定的主机不被识别或关联的IP地址不能用于构建InetAddress实例,则返回null。
|
InetAddress[] resolve(String host) throws UnknownHostException
host - 要由此解析器解析的主机名。
UnknownHostException
InetAddress
Copyright © 1999–2017 The Apache Software Foundation. All rights reserved.