public class DictionaryNameFinder extends Object
Constructor and Description |
---|
DictionaryNameFinder(OntologyDatabase db,
String documentText,
double pThresh,
SyntacticProbabilityModel model)
Creates a new instance of the DictionaryNameFinder class and connects it
to the given database and the given probability model.
|
Modifier and Type | Method and Description |
---|---|
Collection<DictionaryMatch> |
calculateMatches()
Calculates all matches for the given words.
|
void |
processDocumentText()
Automatically processes all words that occur in the documentText given in
the constructor.
|
void |
processWord(String word,
int offset)
Searches for the given word in the dictionary (batched).
|
public DictionaryNameFinder(OntologyDatabase db, String documentText, double pThresh, SyntacticProbabilityModel model)
db
- is a reference to the ontology database that should be used for
querying the ontology names.documentText
- is a reference to the underlying document text.pThresh
- is the minimum probability for which matches are
generated.model
- is the syntactic model used for probability-based matching.public void processDocumentText()
public void processWord(String word, int offset)
word
- is the word that should be processed.offset
- is the position of the first character in the text.public Collection<DictionaryMatch> calculateMatches()
Copyright (C) 2013, 2014 Raphael Dickfelder, Jan Göpfert, Benjamin Paassen, Andreas Stöckel, licensed under the AGPL v. 3: http://openresearch.cit-ec.de/projects/scie