uk.ac.man.entitytagger.matching.matchers
Class PrecomputedMatcher
java.lang.Object
uk.ac.man.entitytagger.matching.Matcher
uk.ac.man.entitytagger.matching.matchers.PrecomputedMatcher
public class PrecomputedMatcher
- extends Matcher
Field Summary |
private java.sql.Connection |
conn
|
private java.util.Map<java.lang.String,java.util.List<Mention>> |
map
|
private java.lang.String |
table
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
map
private java.util.Map<java.lang.String,java.util.List<Mention>> map
conn
private java.sql.Connection conn
table
private java.lang.String table
PrecomputedMatcher
public PrecomputedMatcher(java.io.File file)
PrecomputedMatcher
public PrecomputedMatcher(java.sql.Connection conn,
java.lang.String table)
PrecomputedMatcher
public PrecomputedMatcher(java.io.File file,
java.util.Set<java.lang.String> validDocuments,
java.lang.String restrictPostfix)
matchByID
public java.util.List<Mention> matchByID(java.lang.String id)
match
public java.util.List<Mention> match(java.lang.String text,
Document doc)
- Description copied from class:
Matcher
- Search a given text for mentions
- Specified by:
match
in class Matcher
doc
- the document associated to the text, may be null
- Returns:
- the mentions found by the matcher in the text
size
public int size()
- Overrides:
size
in class Matcher
getStoredData
public java.util.Map<java.lang.String,java.util.List<Mention>> getStoredData()