uk.ac.man.entitytagger.matching
Class Matcher
java.lang.Object
uk.ac.man.entitytagger.matching.Matcher
- Direct Known Subclasses:
- ACIDMatcher, AutomatonMatcher, DuplicationMatcher, IntersectionMatcher, MatchPostProcessor, PrecomputedMatcher, RegexpMatcher, SentenceMatcher, SimpleClientMatcher, TaxonGrabMatcher, UnionMatcher, VariantDictionaryMatcher
public abstract class Matcher
- extends java.lang.Object
Abstract class describing a matcher, and providing common methods for the available matchers
- Author:
- Martin
Nested Class Summary |
static class |
Matcher.Disambiguation
OFF: No disambiguation is performed
ON_EARLIER: Disambiguation is performed by looking at earlier contents in the document
ON_WHOLE: Disambiguation is performed by looking in the whole document |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Matcher
public Matcher()
match
public abstract java.util.List<Mention> match(java.lang.String text,
Document doc)
- Search a given text for mentions
- Parameters:
text
- doc
- the document associated to the text, may be null
- Returns:
- the mentions found by the matcher in the text
size
public int size()
isValidMatch
protected static boolean isValidMatch(java.lang.String text,
Mention match)
disambiguate
public static java.util.List<Mention> disambiguate(java.lang.String text,
java.util.List<Mention> matches,
Matcher.Disambiguation mode)
combineMatches
public static java.util.List<Mention> combineMatches(java.util.List<Mention> matches)
match
public java.util.List<Mention> match(java.lang.String text)
match
public java.util.List<Mention> match(java.lang.String text,
java.lang.String documentID)
performAcronymResolution
protected static void performAcronymResolution(Document doc,
java.lang.String text,
java.util.List<Mention> matches)
detectEnumerations
public static void detectEnumerations(java.util.List<Mention> mentions,
java.lang.String text)
match
public java.util.List<Mention> match(Document d)