|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.jurvis.net.JvProxyConfig
public class JvProxyConfig
The internet proxy configuration.
| Field Summary | |
|---|---|
static int |
AUTOMATIC
Enumerated value indicating internet connections should be made through an automatically configured proxy (i.e. |
protected String |
configurationScriptURL
The URL of the automatic configuration proxy script. |
static int |
DIRECT
Enumerated value indicating internet connections should be made directly (i.e. |
protected Map |
manual
Map keyed by protocol (e.g. |
static int |
MANUAL
Enumerated value indicating internet connections should be made through a manually configured proxy (i.e. |
protected int |
method
The method used to connect to the internet. |
| Constructor Summary | |
|---|---|
JvProxyConfig()
Construct a new JvProxyConfig with a method of
DIRECT (i.e. |
|
JvProxyConfig(String scriptURL)
Construct a new JvProxyConfig that uses a proxy auto-config
script. |
|
| Method Summary | |
|---|---|
int |
getMethod()
Return the method used to connect to the internet. |
JvProxyInfo |
getProxy(String protocol)
Return the manually configured proxy for the specified protocol (e.g. |
List |
getProxyForURI(String uri)
For the specified URI, return the list of proxies that should be used to access the resource at the URI. |
List |
getProxyForURI(URI uri)
For the specified URI, return the list of proxies that should be used to access the resource at the URI. |
void |
setMethod(int method)
Set the method used to connect to the internet. |
void |
setProxy(String protocol,
String host,
int port)
Set the manually configured proxy for the specified protocol. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int DIRECT
public static final int MANUAL
public static final int AUTOMATIC
protected int method
DIRECT,
MANUAL, or AUTOMATIC.
protected String configurationScriptURL
protected Map manual
JvProxyInfo object holding host and port.
| Constructor Detail |
|---|
public JvProxyConfig()
JvProxyConfig with a method of
DIRECT (i.e. a proxy is not used).
public JvProxyConfig(String scriptURL)
JvProxyConfig that uses a proxy auto-config
script.
scriptURL - the URL of the auto-config script| Method Detail |
|---|
public int getMethod()
DIRECT, MANUAL, or AUTOMATIC.
public void setMethod(int method)
method - the method used to connect to the internetpublic JvProxyInfo getProxy(String protocol)
public void setProxy(String protocol,
String host,
int port)
protocol - the internet protocolhost - the name of the proxy hostport - the proxy port number
public List getProxyForURI(String uri)
throws Exception
uri - the desired URI
JvProxyInfos or null if no proxies
should be used (i.e. connect directly)
Exception
public List getProxyForURI(URI uri)
throws Exception
uri - the desired URI
JvProxyInfos or null if no proxies
should be used (i.e. connect directly)
Exception
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||