Skip to content

Commit

Permalink
fixed retrieval
Browse files Browse the repository at this point in the history
  • Loading branch information
vlabatut committed Mar 4, 2015
1 parent e5d79d5 commit 66f6131
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/tr/edu/gsu/nerwip/tools/corpus/ArticleRetrieval.java
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ public static void retrieveArticles(String fileName) throws ReaderException, IOE
logger.log("Reading file " + file);

ArticleRetriever retriever = new ArticleRetriever();
retriever.setCacheEnabled(false);
retriever.setCacheEnabled(true);

logger.increaseOffset();
// boolean pass = true; // used for degbugging purposes
Expand All @@ -136,19 +136,19 @@ public static void retrieveArticles(String fileName) throws ReaderException, IOE
// pass = false;
// if(!pass)
{ logger.log("Processing '" + name + "'");
URL url;
URL url = null;
if(name.startsWith("http"))
url = new URL(name);
else
{ String urlStr = "http://en.wikipedia.org/wiki/"+name;
try
{ url = new URL(urlStr);
retriever.process(url);
}
catch (MalformedURLException e)
{ e.printStackTrace();
}
}
retriever.process(url);
}
}
logger.decreaseOffset();
Expand Down

0 comments on commit 66f6131

Please sign in to comment.