public class ProxySpecification extends Object
Constructor and Description |
---|
ProxySpecification(String host,
int port,
String scheme)
Creates a ProxySpecification with the supplied hostname, port and scheme.
|
Modifier and Type | Method and Description |
---|---|
ProxySpecification |
and()
Syntactic sugar.
|
static ProxySpecification |
auth(String username,
String password)
Specify preemptive basic authentication for the proxy.
|
boolean |
equals(Object o) |
String |
getHost() |
String |
getPassword() |
int |
getPort() |
String |
getScheme() |
String |
getUsername() |
int |
hashCode() |
static ProxySpecification |
host(String host)
Specify the hostname for of the proxy.
|
static ProxySpecification |
port(int port)
Specify the port of the proxy.
|
String |
toString() |
ProxySpecification |
withAuth(String username,
String password)
Specify (preemptive) basic authentication for the proxy
|
ProxySpecification |
withHost(String host)
Specify the hostname of the proxy.
|
ProxySpecification |
withPort(int port)
Specify the port of the proxy.
|
ProxySpecification |
withScheme(String scheme)
Specify the scheme of the proxy.
|
public static ProxySpecification host(String host)
host
- The hostnamepublic static ProxySpecification port(int port)
port
- The port on localhost to connect to.public static ProxySpecification auth(String username, String password)
username
- The usernamepassword
- The usernamepublic ProxySpecification withPort(int port)
port
- The port of the proxy.public ProxySpecification withHost(String host)
host
- The hostname of the proxy.public ProxySpecification withAuth(String username, String password)
username
- The usernamepassword
- The usernamepublic ProxySpecification withScheme(String scheme)
scheme
- The scheme of the proxy.public ProxySpecification and()
public String getHost()
public int getPort()
public String getScheme()
public String getPassword()
public String getUsername()
Copyright © 2010–2019. All rights reserved.