You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@poi.apache.org by us...@apache.org on 2015/11/08 12:57:58 UTC
svn commit: r1713222 - in /poi/trunk: build.xml
src/excelant/java/org/apache/poi/ss/excelant/ExcelAntTask.java
Author: uschindler
Date: Sun Nov 8 11:57:58 2015
New Revision: 1713222
URL: http://svn.apache.org/viewvc?rev=1713222&view=rev
Log:
Make forbiddenapis also check excelant. Use a separate "classpath" for running forbiddenapis; don't misuse javadoc.classpath for that.
Modified:
poi/trunk/build.xml
poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/ExcelAntTask.java
Modified: poi/trunk/build.xml
URL: http://svn.apache.org/viewvc/poi/trunk/build.xml?rev=1713222&r1=1713221&r2=1713222&view=diff
==============================================================================
--- poi/trunk/build.xml (original)
+++ poi/trunk/build.xml Sun Nov 8 11:57:58 2015
@@ -366,6 +366,15 @@ under the License.
<path path="${env.CLASSPATH}"/>
</path>
+ <path id="forbiddenapis.classpath">
+ <path refid="main.classpath"/>
+ <path refid="scratchpad.classpath"/>
+ <path refid="ooxml.classpath"/>
+ <path refid="ooxml.xmlsec.classpath"/>
+ <path refid="excelant.classpath"/>
+ <path path="${env.CLASSPATH}"/>
+ </path>
+
<path id="lib.jacoco">
<fileset dir="lib">
<include name="org.jacoco*.jar" />
@@ -1766,7 +1775,7 @@ under the License.
classpath="${forbidden.jar}"/>
<forbiddenapis
internalRuntimeForbidden="true"
- classpathref="javadoc.classpath"
+ classpathref="forbiddenapis.classpath"
suppressAnnotation="org.apache.poi.util.SuppressForbidden"
>
<bundledsignatures name="jdk-unsafe-${jdk.version.source}"/>
@@ -1779,10 +1788,7 @@ under the License.
<fileset dir="${main.output.dir}"/>
<fileset dir="${ooxml.output.dir}"/>
<fileset dir="${scratchpad.output.dir}"/>
- <!--
- Adding Excelant causes ClassNotFoundException, see https://github.com/policeman-tools/forbidden-apis/issues/85
<fileset dir="${excelant.output.dir}"/>
- -->
<!--
<fileset dir="${examples.output.dir}"/>
-->
Modified: poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/ExcelAntTask.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/ExcelAntTask.java?rev=1713222&r1=1713221&r2=1713222&view=diff
==============================================================================
--- poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/ExcelAntTask.java (original)
+++ poi/trunk/src/excelant/java/org/apache/poi/ss/excelant/ExcelAntTask.java Sun Nov 8 11:57:58 2015
@@ -23,6 +23,7 @@ import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Iterator;
import java.util.LinkedList;
+import java.util.Locale;
import org.apache.poi.ss.excelant.util.ExcelAntWorkbookUtil;
import org.apache.poi.ss.excelant.util.ExcelAntWorkbookUtilFactory;
@@ -88,7 +89,7 @@ public class ExcelAntTask extends Task {
versionBffr.append( "ExcelAnt version " ) ;
versionBffr.append( VERSION ) ;
versionBffr.append( " Copyright 2011" ) ;
- SimpleDateFormat sdf = new SimpleDateFormat( "yyyy" ) ;
+ SimpleDateFormat sdf = new SimpleDateFormat( "yyyy", Locale.ROOT ) ;
double currYear = Double.parseDouble( sdf.format( new Date() ) );
if( currYear > 2011 ) {
versionBffr.append( "-" ) ;
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@poi.apache.org
For additional commands, e-mail: commits-help@poi.apache.org