@Contract(threading=IMMUTABLE) public final class Host extends Object implements NamedEndpoint, Serializable
Modifier and Type | Method and Description |
---|---|
static Host |
create(String s) |
boolean |
equals(Object o) |
String |
getHostName()
Returns name (IP or DNS name).
|
int |
getPort()
Returns the port.
|
int |
hashCode() |
String |
toString() |
public Host(String name, int port)
public static Host create(String s) throws URISyntaxException
URISyntaxException
public String getHostName()
NamedEndpoint
getHostName
in interface NamedEndpoint
public int getPort()
NamedEndpoint
getPort
in interface NamedEndpoint
-1
if not setCopyright © 2005–2021 The Apache Software Foundation. All rights reserved.