|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.6.0) E13403-07 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.javatools.data.HashStructureAdapter oracle.ide.config.ChangeEventSource oracle.ide.webbrowser.ProxyOptions
public class ProxyOptions
Provides access to HTTP proxy options as set via Tools->Preferences->Web Browser and Proxy.
You can obtain the current settings using getProxyOptions()
. You can
replace the current proxy settings by instantiating a new instance of this
class and calling the static method setProxyOptions( ProxyOptions )
.
Typically this should be avoided and a ProxyOptionsFilter should be set
on the ProxyOptions instead.
While this class is not final, subclassing it is not supported, doing so may cause your extension to break in a future release of the product.
Field Summary | |
---|---|
static java.lang.String |
DEFAULT_PROXY_PORT
The default proxy port. |
static java.lang.String |
KEY_SETTINGS
The key for this settings object. |
static java.lang.String |
PROPERTY_PROXY_EXCEPTIONS
The name of the Java system proprety that stores the proxy exceptions. |
static java.lang.String |
PROPERTY_PROXY_HOST
The name of the Java system property that stores the proxy host. |
static java.lang.String |
PROPERTY_PROXY_PORT
The name of the Java system property that stores the proxy port. |
Fields inherited from class oracle.javatools.data.HashStructureAdapter |
---|
_hash |
Constructor Summary | |
---|---|
|
ProxyOptions()
|
protected |
ProxyOptions(HashStructure hash)
|
Method Summary | |
---|---|
void |
applyToCurrentVM()
Applies the options stored in this object to the Java VM in which the IDE is running. |
java.lang.Object |
copyTo(java.lang.Object target)
Copy support. |
protected void |
copyToImpl(ProxyOptions copy)
|
void |
doTask(java.lang.Runnable r)
Performs an operation, setting the VM proxy options temporarily to the settings stored in this ProxyOptions object. |
boolean |
equals(java.lang.Object other)
Equals support. |
ProxyOptionsFilter |
getFilter()
Gets the filter applied to the ProxyOptions This only should be used to get the filter for the IDE settings, other ProxyOptions objects will not use filters and a default filter will always be returned |
static ProxyOptions |
getInstance(PropertyStorage prefs)
|
boolean |
getIsIdeProxy()
Gets whether the ProxyOptions object is the one taht represents the IDE settings |
java.lang.String[] |
getJavaProxyOptions()
Get proxy options as command line arguments suitable for passing into java.exe. |
java.lang.String |
getProxyData()
Get the encrypted password. |
java.lang.String |
getProxyExceptions()
Get the list of proxy exceptions. |
java.lang.String |
getProxyHost()
Get the name of the host to use as an http proxy. |
static ProxyOptions |
getProxyOptions()
Get the current proxy options. |
java.lang.String |
getProxyPassword()
Get the password for proxy authentication. |
java.lang.String |
getProxyPort()
Get the tcp port number of the proxy host. |
java.lang.String |
getProxyUserName()
Get the username for proxy authentication. |
java.lang.String |
getUnfilteredProxyData()
Gets the proxy data without applying any filter (should be used only be preference panels) |
java.lang.String |
getUnfilteredProxyExceptions()
Gets the proxy exceptions without applying any filter (should be used only be preference panels) |
java.lang.String |
getUnfilteredProxyHost()
Gets the proxy host without applying any filter (should be used only be preference panels) |
java.lang.String |
getUnfilteredProxyPassword()
Gets the proxy password without applying any filter (should be used only be preference panels) |
java.lang.String |
getUnfilteredProxyPort()
Gets the proxy port without applying any filter (should be used only be preference panels) |
java.lang.String |
getUnfilteredProxyUserName()
Gets the proxy user name without applying any filter (should be used only be preference panels) |
java.lang.Boolean |
getUnfilteredUseProxy()
Gets the use proxy setting without applying any filter (should be used only be preference panels) |
java.lang.Boolean |
getUnfilteredUseProxyAuthentication()
Gets the use proxy authentication setting without applying any filter (should be used only be preference panels) |
java.lang.Boolean |
getUseProxy()
Get whether an http proxy should be used. |
java.lang.Boolean |
getUseProxyAuthentication()
Get whether proxy authentication should be used. |
void |
setFilter(ProxyOptionsFilter filter)
Sets the filter applied to the ProxyOptions. |
void |
setProxyData(java.lang.String newData)
Set the encrypted password. |
void |
setProxyExceptions(java.lang.String newProxyExceptions)
Set the list of proxy exceptions. |
void |
setProxyHost(java.lang.String newProxyHost)
Set the name of the host to use as an http proxy. |
static void |
setProxyOptions(ProxyOptions proxyOptions)
Set the current proxy options. |
void |
setProxyPassword(java.lang.String newProxyPassword)
Set the password for proxy authentication. |
void |
setProxyPort(java.lang.String newProxyPort)
Set the tcp port number of the proxy host. |
void |
setProxyUserName(java.lang.String newProxyUserName)
Set the username for proxy authentication. |
void |
setUseProxy(java.lang.Boolean newUseProxy)
Set whether an http proxy should be used. |
void |
setUseProxyAuthentication(java.lang.Boolean newUseProxyAuthentication)
Set whether proxy authentication should be used. |
Methods inherited from class oracle.ide.config.ChangeEventSource |
---|
addChangeListener, fireChangeEvent, fireChangeEvent, removeChangeListener, setUseObjectEquals |
Methods inherited from class oracle.javatools.data.HashStructureAdapter |
---|
addStructureChangeListener, containsKey, copyToImpl, equalsImpl, findOrCreate, forcedCopyTo, getHashStructure, removeStructureChangeListener, useObjectEquals |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.String KEY_SETTINGS
public static final java.lang.String PROPERTY_PROXY_HOST
public static final java.lang.String PROPERTY_PROXY_PORT
public static final java.lang.String PROPERTY_PROXY_EXCEPTIONS
public static final java.lang.String DEFAULT_PROXY_PORT
Constructor Detail |
---|
public ProxyOptions()
protected ProxyOptions(HashStructure hash)
Method Detail |
---|
public static ProxyOptions getInstance(PropertyStorage prefs)
public static final ProxyOptions getProxyOptions() throws TransientMarker
TransientMarker
public boolean getIsIdeProxy() throws TransientMarker
TransientMarker
public ProxyOptionsFilter getFilter()
public void setFilter(ProxyOptionsFilter filter)
filter
- the filter to apply to the ProxyOtpions. When null is
passed the default filter will be re-appliedpublic static final void setProxyOptions(ProxyOptions proxyOptions) throws TransientMarker
proxyOptions
- the new proxy options.
TransientMarker
public final void setProxyHost(java.lang.String newProxyHost)
newProxyHost
- the host to use as an http proxy.public final java.lang.String getProxyHost()
public final java.lang.String getUnfilteredProxyHost()
public final void setProxyPort(java.lang.String newProxyPort)
newProxyPort
- the tcp port number of the proxy host.public final java.lang.String getProxyPort()
public final java.lang.String getUnfilteredProxyPort()
public final void setProxyExceptions(java.lang.String newProxyExceptions)
newProxyExceptions
- host name patterns which should bypass the proxypublic final java.lang.String getProxyExceptions()
public final java.lang.String getUnfilteredProxyExceptions()
public final void setUseProxy(java.lang.Boolean newUseProxy)
newUseProxy
- whether an http proxy should be used.public java.lang.Boolean getUseProxy()
public java.lang.Boolean getUnfilteredUseProxy()
public final void setUseProxyAuthentication(java.lang.Boolean newUseProxyAuthentication)
newUseProxyAuthentication
- whether proxy authentication should be usedpublic java.lang.Boolean getUseProxyAuthentication()
public java.lang.Boolean getUnfilteredUseProxyAuthentication()
public final void setProxyUserName(java.lang.String newProxyUserName)
newProxyUserName
- the username for proxy authenticationpublic final java.lang.String getProxyUserName()
public final java.lang.String getUnfilteredProxyUserName()
public final void setProxyPassword(java.lang.String newProxyPassword)
newProxyPassword
- the password for proxy authenticationpublic final java.lang.String getProxyPassword() throws TransientMarker
TransientMarker
public final java.lang.String getUnfilteredProxyPassword() throws TransientMarker
TransientMarker
public final void setProxyData(java.lang.String newData)
newData
- the new encrypted passwordpublic final java.lang.String getProxyData()
public final java.lang.String getUnfilteredProxyData()
public java.lang.String[] getJavaProxyOptions()
NOTE: proxy authentication is not included in these arguments, as it would not be secure to pass this in plain text over the command line. If the Java application being launched needs to make connections through a proxy that requires authentication, it will need to obtain the authentication information itself. For example, it might provide an implementation of the java.net.Authenticator interface.
useProxy
preference is false,
or the proxyHost
is null or zero length,
this method will return null.public void doTask(java.lang.Runnable r)
The operation is specified using a Runnable
. During the lifecycle
of the Runnable.run()
method, the VM's proxy options will be set
to those specified in the provided ProxyOptions object.
Important: the runnable is executed with a global lock held on the proxy options object. It should therefore avoid blocking for a long period of time.
r
- a runnable to execute with the specified proxy settings. This
runnable will be executed synchronously (i.e. on the calling thread).public void applyToCurrentVM()
Extension developers should generally never call this method. It is
called automatically by the IDE when the user changes proxy options on the
Web Browser / Proxy page in preferences, or when proxy options are
programmatically changed via the setProxyOptions(ProxyOptions)
method.
public final boolean equals(java.lang.Object other)
HashStructureAdapter
HashStructureAdapter._hash
, this base equals implementation should be
sufficient and not need to be overridden.
equals
in class HashStructureAdapter
public java.lang.Object copyTo(java.lang.Object target)
HashStructureAdapter
copyTo
in interface Copyable
copyTo
in class ChangeEventSource
target
- The target object to which the state of
this
object should be copied. If target
is null
, then the copyTo
method will
return a new instance of this
class.
this
object was copied. If the target
was
non-null
, then the return value is the same as the
target
object that was passed in; otherwise, the
return value is a new instance of this
class.protected final void copyToImpl(ProxyOptions copy)
|
Oracle Fusion Middleware Java API Reference for Oracle Extension SDK Reference 11g Release 1 (11.1.1.6.0) E13403-07 |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |