diff --git a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java index bf5884a5..10fcbcb7 100644 --- a/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java +++ b/src/main/java/org/apache/maven/plugins/javadoc/AbstractJavadocMojo.java @@ -1689,7 +1689,7 @@ public abstract class AbstractJavadocMojo * <additionalDependency> * <groupId>geronimo-spec</groupId> * <artifactId>geronimo-spec-jta</artifactId> - * <version>1.0.1B-rc4:</version> + * <version>1.0.1B-rc4</version> * </additionalDependency> * </additionalDependencies> * @@ -3647,67 +3647,67 @@ private void addMemoryArg( Commandline cmd, String arg, String memory ) */ private void addProxyArg( Commandline cmd ) { - if ( settings == null || settings.getProxies().isEmpty() ) + if ( settings == null || settings.getProxies().isEmpty() ) { return; } - Map activeProxies = new HashMap<>(); + Map activeProxies = new HashMap<>(); - for ( Proxy proxy : settings.getProxies() ) + for ( Proxy proxy : settings.getProxies() ) { - if ( proxy.isActive() ) - { - String protocol = proxy.getProtocol(); + if ( proxy.isActive() ) + { + String protocol = proxy.getProtocol(); - if ( !activeProxies.containsKey( protocol ) ) + if ( !activeProxies.containsKey( protocol ) ) { - activeProxies.put( protocol, proxy ); - } - } + activeProxies.put( protocol, proxy ); + } + } } - if ( activeProxies.containsKey( "https" ) ) - { - Proxy httpsProxy = activeProxies.get( "https" ); - if ( StringUtils.isNotEmpty( httpsProxy.getHost() ) ) + if ( activeProxies.containsKey( "https" ) ) + { + Proxy httpsProxy = activeProxies.get( "https" ); + if ( StringUtils.isNotEmpty( httpsProxy.getHost() ) ) { - cmd.createArg().setValue( "-J-Dhttps.proxyHost=" + httpsProxy.getHost() ); - cmd.createArg().setValue( "-J-Dhttps.proxyPort=" + httpsProxy.getPort() ); - - if ( StringUtils.isNotEmpty( httpsProxy.getNonProxyHosts() ) - && ( !activeProxies.containsKey( "http" ) - || StringUtils.isEmpty( activeProxies.get( "http" ).getNonProxyHosts() ) ) ) - { - cmd.createArg().setValue( "-J-Dhttp.nonProxyHosts=\"" - + httpsProxy.getNonProxyHosts().replace( "|", "^|" ) + "\"" ); - } + cmd.createArg().setValue( "-J-Dhttps.proxyHost=" + httpsProxy.getHost() ); + cmd.createArg().setValue( "-J-Dhttps.proxyPort=" + httpsProxy.getPort() ); + + if ( StringUtils.isNotEmpty( httpsProxy.getNonProxyHosts() ) + && ( !activeProxies.containsKey( "http" ) + || StringUtils.isEmpty( activeProxies.get( "http" ).getNonProxyHosts() ) ) ) + { + cmd.createArg().setValue( "-J-Dhttp.nonProxyHosts=\"" + + httpsProxy.getNonProxyHosts().replace( "|", "^|" ) + "\"" ); + } } - } - - if ( activeProxies.containsKey( "http" ) ) - { - Proxy httpProxy = activeProxies.get( "http" ); - if ( StringUtils.isNotEmpty( httpProxy.getHost() ) ) - { - cmd.createArg().setValue( "-J-Dhttp.proxyHost=" + httpProxy.getHost() ); - cmd.createArg().setValue( "-J-Dhttp.proxyPort=" + httpProxy.getPort() ); + } + + if ( activeProxies.containsKey( "http" ) ) + { + Proxy httpProxy = activeProxies.get( "http" ); + if ( StringUtils.isNotEmpty( httpProxy.getHost() ) ) + { + cmd.createArg().setValue( "-J-Dhttp.proxyHost=" + httpProxy.getHost() ); + cmd.createArg().setValue( "-J-Dhttp.proxyPort=" + httpProxy.getPort() ); - if ( !activeProxies.containsKey( "https" ) ) + if ( !activeProxies.containsKey( "https" ) ) { - cmd.createArg().setValue( "-J-Dhttps.proxyHost=" + httpProxy.getHost() ); - cmd.createArg().setValue( "-J-Dhttps.proxyPort=" + httpProxy.getPort() ); - } + cmd.createArg().setValue( "-J-Dhttps.proxyHost=" + httpProxy.getHost() ); + cmd.createArg().setValue( "-J-Dhttps.proxyPort=" + httpProxy.getPort() ); + } - if ( StringUtils.isNotEmpty( httpProxy.getNonProxyHosts() ) ) + if ( StringUtils.isNotEmpty( httpProxy.getNonProxyHosts() ) ) { - cmd.createArg().setValue( "-J-Dhttp.nonProxyHosts=\"" - + httpProxy.getNonProxyHosts().replace( "|", "^|" ) + "\"" ); + cmd.createArg().setValue( "-J-Dhttp.nonProxyHosts=\"" + + httpProxy.getNonProxyHosts().replace( "|", "^|" ) + "\"" ); } } } - - // We bravely ignore FTP because no one (probably) uses FTP for Javadoc + + // We bravely ignore FTP because no one (probably) uses FTP for Javadoc } /**