public final class DefaultHostsFileEntriesResolver extends java.lang.Object implements HostsFileEntriesResolver
HostsFileEntriesResolver
that resolves hosts file entries only once.DEFAULT
构造器和说明 |
---|
DefaultHostsFileEntriesResolver() |
限定符和类型 | 方法和说明 |
---|---|
java.net.InetAddress |
address(java.lang.String inetHost,
ResolvedAddressTypes resolvedAddressTypes)
Resolve the address of a hostname against the entries in a hosts file, depending on some address types.
|
java.util.List<java.net.InetAddress> |
addresses(java.lang.String inetHost,
ResolvedAddressTypes resolvedAddressTypes)
Resolves all addresses of a hostname against the entries in a hosts file, depending on the specified
ResolvedAddressTypes . |
public java.net.InetAddress address(java.lang.String inetHost, ResolvedAddressTypes resolvedAddressTypes)
HostsFileEntriesResolver
address
在接口中 HostsFileEntriesResolver
inetHost
- the hostname to resolveresolvedAddressTypes
- the address types to resolvepublic java.util.List<java.net.InetAddress> addresses(java.lang.String inetHost, ResolvedAddressTypes resolvedAddressTypes)
ResolvedAddressTypes
.inetHost
- the hostname to resolveresolvedAddressTypes
- the address types to resolvenull
in case the hostname cannot be resolved