maven-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vsive...@apache.org
Subject svn commit: r709691 - /maven/plugins/trunk/maven-linkcheck-plugin/src/main/java/org/apache/maven/plugins/linkcheck/LinkcheckReport.java
Date Sat, 01 Nov 2008 13:32:15 GMT
Author: vsiveton
Date: Sat Nov  1 06:32:15 2008
New Revision: 709691

URL: http://svn.apache.org/viewvc?rev=709691&view=rev
Log:
o added encoding support due to r709689

Modified:
    maven/plugins/trunk/maven-linkcheck-plugin/src/main/java/org/apache/maven/plugins/linkcheck/LinkcheckReport.java

Modified: maven/plugins/trunk/maven-linkcheck-plugin/src/main/java/org/apache/maven/plugins/linkcheck/LinkcheckReport.java
URL: http://svn.apache.org/viewvc/maven/plugins/trunk/maven-linkcheck-plugin/src/main/java/org/apache/maven/plugins/linkcheck/LinkcheckReport.java?rev=709691&r1=709690&r2=709691&view=diff
==============================================================================
--- maven/plugins/trunk/maven-linkcheck-plugin/src/main/java/org/apache/maven/plugins/linkcheck/LinkcheckReport.java
(original)
+++ maven/plugins/trunk/maven-linkcheck-plugin/src/main/java/org/apache/maven/plugins/linkcheck/LinkcheckReport.java
Sat Nov  1 06:32:15 2008
@@ -58,6 +58,7 @@
 import org.apache.maven.settings.Settings;
 import org.codehaus.plexus.i18n.I18N;
 import org.codehaus.plexus.util.StringUtils;
+import org.codehaus.plexus.util.WriterFactory;
 
 /**
  * Generates a <code>Linkcheck</code> report.
@@ -256,6 +257,14 @@
      */
     protected String[] excludedLinks;
 
+    /**
+     * Specifies the encoding to be used by Linkcheck. If <code>${project.reporting.outputEncoding}</code>
is not
+     * specified, using UTF-8.
+     *
+     * @parameter expression="${encoding}" default-value="${project.reporting.outputEncoding}"
+     */
+    private String encoding;
+
     // ----------------------------------------------------------------------
     // Public methods
     // ----------------------------------------------------------------------
@@ -409,6 +418,7 @@
         lc.setExcludedPages( getExcludedPages() );
         lc.setExcludedHttpStatusErrors( excludedHttpStatusErrors );
         lc.setExcludedHttpStatusWarnings( excludedHttpStatusWarnings );
+        lc.setEncoding( ( StringUtils.isNotEmpty( encoding ) ? encoding : WriterFactory.UTF_8
) );
 
         HttpBean bean = new HttpBean();
         bean.setMethod( httpMethod );



Mime
View raw message