Revision: 17605
http://sourceforge.net/p/gate/code/17605
Author: markagreenwood
Date: 2014-03-09 10:15:34 +0000 (Sun, 09 Mar 2014)
Log Message:
-----------
a few more warnings cleared up
Modified Paths:
--------------
gate/trunk/src/main/gate/xml/XmlDocumentHandler.java
gate/trunk/src/main/gate/xml/XmlPositionCorrectionHandler.java
gate/trunk/src/main/hepple/postag/POSTagger.java
Modified: gate/trunk/src/main/gate/xml/XmlDocumentHandler.java
===================================================================
--- gate/trunk/src/main/gate/xml/XmlDocumentHandler.java 2014-03-09
10:08:13 UTC (rev 17604)
+++ gate/trunk/src/main/gate/xml/XmlDocumentHandler.java 2014-03-09
10:15:34 UTC (rev 17605)
@@ -681,6 +681,7 @@
/** Also a workaround for URI identifier. If the QName is gate it will return
* GATE's. Otherwhise it will return the empty string
*/
+ @SuppressWarnings("unused")
private String getMyURI(String aQName) {
if (aQName == null) {
return "";
Modified: gate/trunk/src/main/gate/xml/XmlPositionCorrectionHandler.java
===================================================================
--- gate/trunk/src/main/gate/xml/XmlPositionCorrectionHandler.java
2014-03-09 10:08:13 UTC (rev 17604)
+++ gate/trunk/src/main/gate/xml/XmlPositionCorrectionHandler.java
2014-03-09 10:15:34 UTC (rev 17605)
@@ -34,9 +34,6 @@
*/
public class XmlPositionCorrectionHandler extends DefaultHandler {
- /** Debug flag */
- private static final boolean DEBUG = false;
-
/**
* Variables for correction of 16K parser limit for offset
*/
Modified: gate/trunk/src/main/hepple/postag/POSTagger.java
===================================================================
--- gate/trunk/src/main/hepple/postag/POSTagger.java 2014-03-09 10:08:13 UTC
(rev 17604)
+++ gate/trunk/src/main/hepple/postag/POSTagger.java 2014-03-09 10:15:34 UTC
(rev 17605)
@@ -47,7 +47,6 @@
import java.io.File;
import java.io.FileReader;
import java.io.IOException;
-import java.io.InputStream;
import java.net.URL;
import java.util.ArrayList;
import java.util.HashMap;
@@ -240,15 +239,15 @@
/**
* Reads the rules from the rules input file
*/
+ @SuppressWarnings("resource")
public void readRules(URL rulesURL) throws IOException, InvalidRuleException{
BufferedReader rulesReader = null;
- InputStream rulesStream = null;
+
try {
- rulesStream = rulesURL.openStream();
if(encoding == null) {
- rulesReader = new BomStrippingInputStreamReader(rulesStream);
+ rulesReader = new BomStrippingInputStreamReader(rulesURL.openStream());
} else {
- rulesReader = new BomStrippingInputStreamReader(rulesStream,
this.encoding);
+ rulesReader = new BomStrippingInputStreamReader(rulesURL.openStream(),
this.encoding);
}
String line;
@@ -275,7 +274,6 @@
}
finally {
IOUtils.closeQuietly(rulesReader);
- IOUtils.closeQuietly(rulesStream);
}
}//public void readRules()
@@ -462,6 +460,7 @@
* Reads one input file and creates the structure needed by the tagger
* for input.
*/
+ @SuppressWarnings("unused")
private static List<List<String>> readInput(String file) throws IOException{
BufferedReader reader = null;
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
------------------------------------------------------------------------------
Subversion Kills Productivity. Get off Subversion & Make the Move to Perforce.
With Perforce, you get hassle-free workflows. Merge that actually works.
Faster operations. Version large binaries. Built-in WAN optimization and the
freedom to use Git, Perforce or both. Make the move to Perforce.
http://pubads.g.doubleclick.net/gampad/clk?id=122218951&iu=/4140/ostg.clktrk
_______________________________________________
GATE-cvs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/gate-cvs