Class ProxyServiceFacadeImpl

    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void clearPersistentProxySettings()
      Discard persistent proxy settings.
      void configureProxy​(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.String getProxyType​(java.lang.String protocol)  
      private static void recursiveClear​(org.osgi.service.prefs.Preferences preferences)  
      private void registerAuthenticator​(java.lang.String user, java.lang.String password)  
      void setProxyServer​(org.eclipse.core.net.proxy.IProxyService proxyService)  
      void unsetProxyServer​(org.eclipse.core.net.proxy.IProxyService proxyService)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • 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
    • Constructor Detail

      • ProxyServiceFacadeImpl

        public ProxyServiceFacadeImpl()
    • 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: ProxyServiceFacade
        Configure the OSGI proxy service for the protocol specified. Parameter values are assumed to be taken from {@see org.apache.maven.settings.Proxy}
        Specified by:
        configureProxy in interface ProxyServiceFacade
        Parameters:
        protocol - proxy protocol
        host - proxy host
        port - proxy port
        user - may be null
        password - may be null
        nonProxyHosts - pipe-separated list of non-proxied hosts, may be null
      • 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: ProxyServiceFacade
        Discard 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:
        clearPersistentProxySettings in interface ProxyServiceFacade
      • 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)