public class StopWordSet extends Object implements org.apache.uima.resource.SharedResourceObject
Constructor and Description |
---|
StopWordSet() |
StopWordSet(String[] fileNames) |
Modifier and Type | Method and Description |
---|---|
void |
addStopWordListFile(String fileName)
Loads a text file (UTF-8 encoding!) containing stop words.
|
boolean |
contains(String aWord) |
void |
load(org.apache.uima.resource.DataResource dataRes) |
void |
load(InputStream aIs) |
void |
load(InputStream aIs,
String aEncoding) |
void |
load(Reader aReader)
Load the stopwords from the given reader.
|
public StopWordSet()
public StopWordSet(String[] fileNames) throws IOException
IOException
public void addStopWordListFile(String fileName) throws IOException
fileName
- the file to read.IOException
- if the file could not be read.public void load(org.apache.uima.resource.DataResource dataRes) throws org.apache.uima.resource.ResourceInitializationException
load
in interface org.apache.uima.resource.SharedResourceObject
org.apache.uima.resource.ResourceInitializationException
public void load(InputStream aIs) throws IOException
IOException
public void load(InputStream aIs, String aEncoding) throws IOException
IOException
public void load(Reader aReader) throws IOException
aReader
- a reader.IOException
- if the data could not be read.public boolean contains(String aWord)
Copyright © 2007–2018 Ubiquitous Knowledge Processing (UKP) Lab, Technische Universität Darmstadt. All rights reserved.