public class XmlRuleDisambiguator extends Object implements Disambiguator
| Constructor and Description |
|---|
XmlRuleDisambiguator(Language language) |
| Modifier and Type | Method and Description |
|---|---|
AnalyzedSentence |
disambiguate(AnalyzedSentence input)
If possible, filters out the wrong POS tags.
|
protected List<DisambiguationPatternRule> |
loadPatternRules(String filename)
Load disambiguation rules from an XML file.
|
public XmlRuleDisambiguator(Language language)
public AnalyzedSentence disambiguate(AnalyzedSentence input) throws IOException
Disambiguatordisambiguate in interface Disambiguatorinput - The sentence with already tagged words. The words are expected to
have multiple tags.IOExceptionprotected List<DisambiguationPatternRule> loadPatternRules(String filename) throws ParserConfigurationException, SAXException, IOException
JLanguageTool.addRule(org.languagetool.rules.Rule) to add
these rules to the checking process.DisambiguationPatternRule objectsParserConfigurationExceptionSAXExceptionIOException