Package org.eclipse.tycho.p2.impl.proxy
Class ProxyServiceFacadeImpl
- java.lang.Object
-
- org.eclipse.tycho.p2.impl.proxy.ProxyServiceFacadeImpl
-
- All Implemented Interfaces:
ProxyServiceFacade
public class ProxyServiceFacadeImpl extends java.lang.Object implements ProxyServiceFacade
-
-
Field Summary
Fields Modifier and Type Field Description private static java.lang.StringMAVEN_SETTINGS_SOURCEprivate static java.util.regex.PatternNON_PROXY_DELIMITERSprivate org.eclipse.core.net.proxy.IProxyServiceproxyService
-
Constructor Summary
Constructors Constructor Description ProxyServiceFacadeImpl()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclearPersistentProxySettings()Discard persistent proxy settings.voidconfigureProxy(java.lang.String protocol, java.lang.String host, int port, java.lang.String user, java.lang.String password, java.lang.String nonProxyHosts)Configure the OSGI proxy service for the protocol specified.private static java.lang.StringgetProxyType(java.lang.String protocol)private static voidrecursiveClear(org.osgi.service.prefs.Preferences preferences)private voidregisterAuthenticator(java.lang.String user, java.lang.String password)voidsetProxyServer(org.eclipse.core.net.proxy.IProxyService proxyService)voidunsetProxyServer(org.eclipse.core.net.proxy.IProxyService proxyService)
-
-
-
Field Detail
-
MAVEN_SETTINGS_SOURCE
private static final java.lang.String MAVEN_SETTINGS_SOURCE
- See Also:
- Constant Field Values
-
NON_PROXY_DELIMITERS
private static final java.util.regex.Pattern NON_PROXY_DELIMITERS
-
proxyService
private org.eclipse.core.net.proxy.IProxyService proxyService
-
-
Method Detail
-
configureProxy
public void configureProxy(java.lang.String protocol, java.lang.String host, int port, java.lang.String user, java.lang.String password, java.lang.String nonProxyHosts)Description copied from interface:ProxyServiceFacadeConfigure the OSGI proxy service for the protocol specified. Parameter values are assumed to be taken from {@see org.apache.maven.settings.Proxy}- Specified by:
configureProxyin interfaceProxyServiceFacade- Parameters:
protocol- proxy protocolhost- proxy hostport- proxy portuser- may benullpassword- may benullnonProxyHosts- pipe-separated list of non-proxied hosts, may benull
-
registerAuthenticator
private void registerAuthenticator(java.lang.String user, java.lang.String password)
-
getProxyType
private static java.lang.String getProxyType(java.lang.String protocol)
-
clearPersistentProxySettings
public void clearPersistentProxySettings()
Description copied from interface:ProxyServiceFacadeDiscard persistent proxy settings. This is needed because org.eclipse.core.net.proxy.IProxyService always remembers its settings in eclipse/configuration/.settings/org.eclipse.core.net.prefs. Otherwise proxy settings would survive across OSGi framework restarts and thus influence subsequent builds.- Specified by:
clearPersistentProxySettingsin interfaceProxyServiceFacade
-
recursiveClear
private static void recursiveClear(org.osgi.service.prefs.Preferences preferences) throws org.osgi.service.prefs.BackingStoreException- Throws:
org.osgi.service.prefs.BackingStoreException
-
setProxyServer
public void setProxyServer(org.eclipse.core.net.proxy.IProxyService proxyService)
-
unsetProxyServer
public void unsetProxyServer(org.eclipse.core.net.proxy.IProxyService proxyService)
-
-