@Contract(threading=IMMUTABLE) public final class URIAuthority extends Object implements NamedEndpoint, Serializable
URI.| 构造器和说明 |
|---|
URIAuthority(Host host) |
URIAuthority(NamedEndpoint namedEndpoint) |
URIAuthority(String hostname) |
URIAuthority(String userInfo,
Host host) |
URIAuthority(String hostname,
int port) |
URIAuthority(String userInfo,
NamedEndpoint endpoint) |
URIAuthority(String userInfo,
String hostname,
int port)
Constructs a new instance.
|
public URIAuthority(String userInfo, String hostname, int port)
IllegalArgumentException - If the port parameter is outside the specified range of valid port values, which is between 0 and
65535, inclusive. -1 indicates the scheme default port.public URIAuthority(String hostname, int port)
public URIAuthority(Host host)
public URIAuthority(String userInfo, NamedEndpoint endpoint)
public URIAuthority(NamedEndpoint namedEndpoint)
public URIAuthority(String hostname)
public static URIAuthority create(String s) throws URISyntaxException
URIAuthority instance from a string. Text may not contain any blanks.public String getUserInfo()
public String getHostName()
NamedEndpointgetHostName 在接口中 NamedEndpointpublic int getPort()
NamedEndpointgetPort 在接口中 NamedEndpoint-1 if not setCopyright © 2023. All rights reserved.