You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by us...@apache.org on 2012/07/08 00:03:22 UTC
svn commit: r1358653 -
/lucene/dev/branches/lucene4199/lucene/tools/src/java/org/apache/lucene/validation/ForbiddenApisCheckTask.java
Author: uschindler
Date: Sat Jul 7 22:03:22 2012
New Revision: 1358653
URL: http://svn.apache.org/viewvc?rev=1358653&view=rev
Log:
LUCENE-4199: update javadocs and printout for no longer method-only checks
Modified:
lucene/dev/branches/lucene4199/lucene/tools/src/java/org/apache/lucene/validation/ForbiddenApisCheckTask.java
Modified: lucene/dev/branches/lucene4199/lucene/tools/src/java/org/apache/lucene/validation/ForbiddenApisCheckTask.java
URL: http://svn.apache.org/viewvc/lucene/dev/branches/lucene4199/lucene/tools/src/java/org/apache/lucene/validation/ForbiddenApisCheckTask.java?rev=1358653&r1=1358652&r2=1358653&view=diff
==============================================================================
--- lucene/dev/branches/lucene4199/lucene/tools/src/java/org/apache/lucene/validation/ForbiddenApisCheckTask.java (original)
+++ lucene/dev/branches/lucene4199/lucene/tools/src/java/org/apache/lucene/validation/ForbiddenApisCheckTask.java Sat Jul 7 22:03:22 2012
@@ -57,8 +57,8 @@ import java.util.Locale;
import java.util.Map;
/**
- * Task to check if a set of class files contains calls to forbidden methods
- * from a given classpath and list of methods (either inline or as pointer to files).
+ * Task to check if a set of class files contains calls to forbidden APIs
+ * from a given classpath and list of API signatures (either inline or as pointer to files).
*/
public class ForbiddenApisCheckTask extends Task {
@@ -187,7 +187,7 @@ public class ForbiddenApisCheckTask exte
}
}
- /** Reads a list of method signatures. Closes the Reader when done (on Exception, too)! */
+ /** Reads a list of API signatures. Closes the Reader when done (on Exception, too)! */
private void parseApiFile(ClassLoader loader, Reader reader) throws IOException {
final BufferedReader r = new BufferedReader(reader);
try {
@@ -252,12 +252,12 @@ public class ForbiddenApisCheckTask exte
}
log(String.format(Locale.ROOT,
- "Scanned %d class file(s) for forbidden method invocations (in %.2fs), %d error(s).",
+ "Scanned %d class file(s) for forbidden API invocations (in %.2fs), %d error(s).",
checked, (System.currentTimeMillis() - start) / 1000.0, errors),
errors > 0 ? Project.MSG_ERR : Project.MSG_INFO);
if (errors > 0) {
- throw new BuildException("Check for forbidden method calls failed, see log.");
+ throw new BuildException("Check for forbidden API calls failed, see log.");
}
} finally {
if (loader != null) loader.cleanup();
@@ -269,12 +269,12 @@ public class ForbiddenApisCheckTask exte
classFiles.add(rc);
}
- /** A file with method signatures apiFile= attribute */
+ /** A file with API signatures apiFile= attribute */
public void setApiFile(File file) {
apiSignatures.add(new FileResource(getProject(), file));
}
- /** Set of files with method signatures as <apiFileSet/> nested element */
+ /** Set of files with API signatures as <apiFileSet/> nested element */
public FileSet createApiFileSet() {
final FileSet fs = new FileSet();
fs.setProject(getProject());