Uses of Class
org.languagetool.rules.RuleMatch
Packages that use RuleMatch
Package
Description
-
Uses of RuleMatch in org.languagetool
Fields in org.languagetool with type parameters of type RuleMatchModifier and TypeFieldDescriptionprivate final com.google.common.cache.Cache<InputSentence,
List<RuleMatch>> ResultCache.matchesCache
Methods in org.languagetool that return RuleMatchModifier and TypeMethodDescriptionJLanguageTool.adjustRuleMatchPos
(RuleMatch match, int charCount, int columnCount, int lineCount, String sentence, AnnotatedText annotatedText) Change RuleMatch positions so they are relative to the complete text, not just to the sentence.Methods in org.languagetool that return types with arguments of type RuleMatchModifier and TypeMethodDescriptionJLanguageTool.applyCustomFilters
(List<RuleMatch> matches, AnnotatedText text) should be called just once with complete list of matches, before returning them to callerJLanguageTool.TextCheckCallable.call()
The main check method.JLanguageTool.check
(String text, boolean tokenizeText, JLanguageTool.ParagraphHandling paraMode) JLanguageTool.check
(String text, boolean tokenizeText, JLanguageTool.ParagraphHandling paraMode, RuleMatchListener listener) JLanguageTool.check
(String text, RuleMatchListener listener) The main check method.JLanguageTool.check
(AnnotatedText text) The main check method.JLanguageTool.check
(AnnotatedText annotatedText, boolean tokenizeText, JLanguageTool.ParagraphHandling paraMode) The main check method.JLanguageTool.check
(AnnotatedText annotatedText, boolean tokenizeText, JLanguageTool.ParagraphHandling paraMode, RuleMatchListener listener) The main check method.JLanguageTool.check
(AnnotatedText annotatedText, boolean tokenizeText, JLanguageTool.ParagraphHandling paraMode, RuleMatchListener listener, JLanguageTool.Mode mode) The main check method.JLanguageTool.check
(AnnotatedText text, RuleMatchListener listener) JLanguageTool.checkAnalyzedSentence
(JLanguageTool.ParagraphHandling paraMode, List<Rule> rules, AnalyzedSentence analyzedSentence) This is an internal method that's public only for technical reasons, please use one of theJLanguageTool.check(String)
methods instead.MultiThreadedJLanguageTool.createTextCheckCallables
(JLanguageTool.ParagraphHandling paraMode, AnnotatedText annotatedText, List<AnalyzedSentence> analyzedSentences, List<String> sentences, List<Rule> allRules, int charCount, int lineCount, int columnCount, RuleMatchListener listener, JLanguageTool.Mode mode) ResultCache.getIfPresent
(InputSentence key) com.google.common.cache.Cache<InputSentence,
List<RuleMatch>> ResultCache.getMatchesCache()
JLanguageTool.TextCheckCallable.getOtherRuleMatches()
JLanguageTool.TextCheckCallable.getTextLevelRuleMatches()
JLanguageTool.performCheck
(List<AnalyzedSentence> analyzedSentences, List<String> sentences, List<Rule> allRules, JLanguageTool.ParagraphHandling paraMode, AnnotatedText annotatedText, JLanguageTool.Mode mode) JLanguageTool.performCheck
(List<AnalyzedSentence> analyzedSentences, List<String> sentences, List<Rule> allRules, JLanguageTool.ParagraphHandling paraMode, AnnotatedText annotatedText, RuleMatchListener listener, JLanguageTool.Mode mode) MultiThreadedJLanguageTool.performCheck
(List<AnalyzedSentence> analyzedSentences, List<String> sentences, List<Rule> allRules, JLanguageTool.ParagraphHandling paraMode, AnnotatedText annotatedText, RuleMatchListener listener, JLanguageTool.Mode mode) Methods in org.languagetool with parameters of type RuleMatchModifier and TypeMethodDescriptionJLanguageTool.adjustRuleMatchPos
(RuleMatch match, int charCount, int columnCount, int lineCount, String sentence, AnnotatedText annotatedText) Change RuleMatch positions so they are relative to the complete text, not just to the sentence.JLanguageTool.TextCheckCallable.getLineColumnRange
(RuleMatch match) void
RuleMatchListener.matchFound
(RuleMatch ruleMatch) Called for everyRuleMatch
found.Method parameters in org.languagetool with type arguments of type RuleMatchModifier and TypeMethodDescriptionJLanguageTool.applyCustomFilters
(List<RuleMatch> matches, AnnotatedText text) should be called just once with complete list of matches, before returning them to callervoid
ResultCache.put
(InputSentence key, List<RuleMatch> sentenceMatches) int
ResultCache.MatchesWeigher.weigh
(InputSentence sentence, List<RuleMatch> matches) -
Uses of RuleMatch in org.languagetool.rules
Methods in org.languagetool.rules that return RuleMatchModifier and TypeMethodDescriptionAbstractDateCheckFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) AbstractFutureDateFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) AbstractNewYearDateFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) @Nullable RuleMatch
DateRangeChecker.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) PartialPosTagFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) @Nullable RuleMatch
ShortenedYearRangeChecker.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) WhitespaceCheckFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) YMDDateHelper.correctDate
(RuleMatch match, Map<String, String> args) private @Nullable RuleMatch
GenericUnpairedBracketsRule.createMatch
(List<RuleMatch> ruleMatches, UnsyncStack<SymbolLocator> ruleMatchStack, int startPos, String symbol, AnalyzedSentence sentence, List<AnalyzedSentence> sentences) protected RuleMatch
AbstractSimpleReplaceRule.createRuleMatch
(AnalyzedTokenReadings tokenReadings, List<String> replacements, AnalyzedSentence sentence) protected RuleMatch
WordRepeatRule.createRuleMatch
(String prevToken, String token, int prevPos, int pos, String msg, AnalyzedSentence sentence) AbstractCompoundRule.match
(AnalyzedSentence sentence) AbstractDashRule.match
(AnalyzedSentence sentence) AbstractFillerWordsRule.match
(List<AnalyzedSentence> sentences) AbstractPunctuationCheckRule.match
(AnalyzedSentence sentence) AbstractSimpleReplaceRule.match
(AnalyzedSentence sentence) AbstractSimpleReplaceRule2.match
(AnalyzedSentence sentence) final RuleMatch[]
AbstractSpaceBeforeRule.match
(AnalyzedSentence sentence) AbstractStyleRepeatedWordRule.match
(List<AnalyzedSentence> sentences) AbstractUnitConversionRule.match
(AnalyzedSentence sentence) AbstractWordCoherencyRule.match
(List<AnalyzedSentence> sentences) final RuleMatch[]
AdvancedWordRepeatRule.match
(AnalyzedSentence sentence) final RuleMatch[]
CommaWhitespaceRule.match
(AnalyzedSentence sentence) DemoRule.match
(AnalyzedSentence sentence) final RuleMatch[]
DoublePunctuationRule.match
(AnalyzedSentence sentence) EmptyLineRule.match
(List<AnalyzedSentence> sentences) final RuleMatch[]
GenericUnpairedBracketsRule.match
(List<AnalyzedSentence> sentences) LongParagraphRule.match
(List<AnalyzedSentence> sentences) LongSentenceRule.match
(AnalyzedSentence sentence) MultipleWhitespaceRule.match
(List<AnalyzedSentence> sentences) OpenNMTRule.match
(AnalyzedSentence sentence) ParagraphRepeatBeginningRule.match
(List<AnalyzedSentence> sentences) PunctuationMarkAtParagraphEnd.match
(List<AnalyzedSentence> sentences) ReadabilityRule.match
(List<AnalyzedSentence> sentences) abstract RuleMatch[]
Rule.match
(AnalyzedSentence sentence) Check whether the given sentence matches this error rule, i.e.SentenceWhitespaceRule.match
(List<AnalyzedSentence> sentences) abstract RuleMatch[]
TextLevelRule.match
(List<AnalyzedSentence> sentences) Deprecated.TextLevelRule.match
(List<AnalyzedSentence> sentences, AnnotatedText annotatedText) final RuleMatch[]
TextLevelRule.match
(AnalyzedSentence sentence) UppercaseSentenceStartRule.match
(List<AnalyzedSentence> sentences) WhiteSpaceAtBeginOfParagraph.match
(AnalyzedSentence sentence) WhiteSpaceBeforeParagraphEnd.match
(List<AnalyzedSentence> sentences) final RuleMatch[]
WhitespaceBeforePunctuationRule.match
(AnalyzedSentence sentence) WordRepeatBeginningRule.match
(List<AnalyzedSentence> sentences) WordRepeatRule.match
(AnalyzedSentence sentence) WrongWordInContextRule.match
(AnalyzedSentence sentence) protected final RuleMatch[]
Rule.toRuleMatchArray
(List<RuleMatch> ruleMatches) Methods in org.languagetool.rules that return types with arguments of type RuleMatchModifier and TypeMethodDescriptionDictionaryMatchFilter.filter
(List<RuleMatch> ruleMatches, AnnotatedText text) Deprecated.use and implementfilter(List<RuleMatch> ruleMatches, AnnotatedText text)
RuleMatchFilter.filter
(List<RuleMatch> ruleMatches, AnnotatedText text) AbstractSimpleReplaceRule.findMatches
(AnalyzedTokenReadings tokenReadings, AnalyzedSentence sentence) Methods in org.languagetool.rules with parameters of type RuleMatchModifier and TypeMethodDescriptionAbstractDateCheckFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) AbstractFutureDateFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) AbstractNewYearDateFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) @Nullable RuleMatch
DateRangeChecker.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) PartialPosTagFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> args, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) @Nullable RuleMatch
ShortenedYearRangeChecker.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) WhitespaceCheckFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) int
Compare by start position.YMDDateHelper.correctDate
(RuleMatch match, Map<String, String> args) private int
CleanOverlappingFilter.getMatchPriority
(RuleMatch r) private boolean
RuleWithMaxFilter.haveSameRule
(RuleMatch match, RuleMatch nextMatch) private boolean
SameRuleGroupFilter.haveSameRuleGroup
(RuleMatch match, RuleMatch nextMatch) (package private) final boolean
private boolean
SameRuleGroupFilter.overlapAndMatch
(RuleMatch match, RuleMatch nextMatch) (package private) boolean
void
RuleMatch.setOffsetPosition
(int fromPos, int toPos, RuleMatch ruleMatch) Method parameters in org.languagetool.rules with type arguments of type RuleMatchModifier and TypeMethodDescriptionprivate @Nullable RuleMatch
GenericUnpairedBracketsRule.createMatch
(List<RuleMatch> ruleMatches, UnsyncStack<SymbolLocator> ruleMatchStack, int startPos, String symbol, AnalyzedSentence sentence, List<AnalyzedSentence> sentences) DictionaryMatchFilter.filter
(List<RuleMatch> ruleMatches, AnnotatedText text) Deprecated.use and implementfilter(List<RuleMatch> ruleMatches, AnnotatedText text)
RuleMatchFilter.filter
(List<RuleMatch> ruleMatches, AnnotatedText text) private void
AbstractUnitConversionRule.matchUnits
(AnalyzedSentence sentence, List<RuleMatch> matches, List<Map.Entry<Integer, Integer>> ignoreRanges, boolean isMetric) protected final RuleMatch[]
Rule.toRuleMatchArray
(List<RuleMatch> ruleMatches) private void
AbstractUnitConversionRule.tryConversion
(AnalyzedSentence sentence, List<RuleMatch> matches, Pattern unitPattern, Double customValue, javax.measure.Unit customUnit, Matcher unitMatcher, List<Map.Entry<Integer, Integer>> ignoreRanges) Constructors in org.languagetool.rules with parameters of type RuleMatch -
Uses of RuleMatch in org.languagetool.rules.bitext
Methods in org.languagetool.rules.bitext that return RuleMatchModifier and TypeMethodDescription@Nullable RuleMatch[]
BitextRule.match
(AnalyzedSentence sentence) This method makes no sense for bitext, thus it always returnsnull
.abstract RuleMatch[]
BitextRule.match
(AnalyzedSentence sourceText, AnalyzedSentence targetText) DifferentLengthRule.match
(AnalyzedSentence sourceText, AnalyzedSentence targetText) DifferentPunctuationRule.match
(AnalyzedSentence sourceText, AnalyzedSentence targetText) SameTranslationRule.match
(AnalyzedSentence sourceText, AnalyzedSentence targetText) -
Uses of RuleMatch in org.languagetool.rules.neuralnetwork
Methods in org.languagetool.rules.neuralnetwork that return RuleMatchModifier and TypeMethodDescriptionprivate @NotNull RuleMatch
NeuralNetworkRule.createRuleMatch
(AnalyzedTokenReadings token, Suggestion suggestion, float[] y, AnalyzedSentence sentence) NeuralNetworkRule.match
(AnalyzedSentence sentence) -
Uses of RuleMatch in org.languagetool.rules.ngrams
Methods in org.languagetool.rules.ngrams that return RuleMatchModifier and TypeMethodDescriptionConfusionProbabilityRule.match
(AnalyzedSentence sentence) NgramProbabilityRule.match
(AnalyzedSentence sentence) Methods in org.languagetool.rules.ngrams with parameters of type RuleMatchModifier and TypeMethodDescriptionprotected boolean
NgramProbabilityRule.acceptMatch
(RuleMatch match, Probability p, AnalyzedSentence sentence) Overwrite this method to discard matches by returningfalse
. -
Uses of RuleMatch in org.languagetool.rules.patterns
Methods in org.languagetool.rules.patterns that return RuleMatchModifier and TypeMethodDescriptionabstract @Nullable RuleMatch
RuleFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) Returns the original rule match or a modified one, ornull
if the rule match is filtered out.private @Nullable RuleMatch
PatternRuleMatcher.createRuleMatch
(List<Integer> tokenPositions, AnalyzedTokenReadings[] tokens, int firstMatchToken, int lastMatchToken, int firstMarkerMatchToken, int lastMarkerMatchToken, AnalyzedSentence sentence) AbstractPatternRule.match
(AnalyzedSentence sentence) final RuleMatch[]
PatternRule.match
(AnalyzedSentence sentence) PatternRuleMatcher.match
(AnalyzedSentence sentence) RegexPatternRule.match
(AnalyzedSentence sentenceObj) RuleFilter.FakeRule.match
(AnalyzedSentence sentence) RuleMatcher.match
(AnalyzedSentence sentence) @Nullable RuleMatch
RuleFilterEvaluator.runFilter
(String filterArgs, RuleMatch ruleMatch, AnalyzedTokenReadings[] patternTokens, int patternTokenPos, List<Integer> tokenPositions) Methods in org.languagetool.rules.patterns with parameters of type RuleMatchModifier and TypeMethodDescriptionabstract @Nullable RuleMatch
RuleFilter.acceptRuleMatch
(RuleMatch match, Map<String, String> arguments, int patternTokenPos, AnalyzedTokenReadings[] patternTokens) Returns the original rule match or a modified one, ornull
if the rule match is filtered out.@Nullable RuleMatch
RuleFilterEvaluator.runFilter
(String filterArgs, RuleMatch ruleMatch, AnalyzedTokenReadings[] patternTokens, int patternTokenPos, List<Integer> tokenPositions) -
Uses of RuleMatch in org.languagetool.rules.patterns.bitext
Methods in org.languagetool.rules.patterns.bitext that return RuleMatchModifier and TypeMethodDescriptionBitextPatternRule.match
(AnalyzedSentence sentence) This method always returns an empty array.BitextPatternRule.match
(AnalyzedSentence sourceSentence, AnalyzedSentence targetSentence) -
Uses of RuleMatch in org.languagetool.rules.spelling
Methods in org.languagetool.rules.spelling that return RuleMatchModifier and TypeMethodDescriptionprotected RuleMatch
SpellingCheckRule.createWrongSplitMatch
(AnalyzedSentence sentence, List<RuleMatch> ruleMatchesSoFar, int pos, String coveredWord, String suggestion1, String suggestion2, int prevPos) abstract RuleMatch[]
SpellingCheckRule.match
(AnalyzedSentence sentence) SymSpellRule.match
(AnalyzedSentence sentence) Methods in org.languagetool.rules.spelling with parameters of type RuleMatchModifier and TypeMethodDescriptionprotected static void
SpellingCheckRule.addSuggestionsToRuleMatch
(String word, List<String> userCandidates, List<String> candidates, @Nullable SuggestionsOrderer orderer, RuleMatch match) Method parameters in org.languagetool.rules.spelling with type arguments of type RuleMatchModifier and TypeMethodDescriptionprotected RuleMatch
SpellingCheckRule.createWrongSplitMatch
(AnalyzedSentence sentence, List<RuleMatch> ruleMatchesSoFar, int pos, String coveredWord, String suggestion1, String suggestion2, int prevPos) -
Uses of RuleMatch in org.languagetool.rules.spelling.hunspell
Methods in org.languagetool.rules.spelling.hunspell that return RuleMatch -
Uses of RuleMatch in org.languagetool.rules.spelling.morfologik
Methods in org.languagetool.rules.spelling.morfologik that return RuleMatchMethods in org.languagetool.rules.spelling.morfologik that return types with arguments of type RuleMatchModifier and TypeMethodDescriptionMorfologikSpellerRule.getRuleMatches
(String word, int startPos, AnalyzedSentence sentence, List<RuleMatch> ruleMatchesSoFar, int idx, AnalyzedTokenReadings[] tokens) Method parameters in org.languagetool.rules.spelling.morfologik with type arguments of type RuleMatchModifier and TypeMethodDescriptionMorfologikSpellerRule.getRuleMatches
(String word, int startPos, AnalyzedSentence sentence, List<RuleMatch> ruleMatchesSoFar, int idx, AnalyzedTokenReadings[] tokens) -
Uses of RuleMatch in org.languagetool.tools
Methods in org.languagetool.tools that return types with arguments of type RuleMatchModifier and TypeMethodDescriptionTools.checkBitext
(String src, String trg, JLanguageTool srcLt, JLanguageTool trgLt, List<BitextRule> bRules) Checks the bilingual input (bitext).Methods in org.languagetool.tools with parameters of type RuleMatchModifier and TypeMethodDescriptionprivate void
RuleMatchesAsJsonSerializer.writeContext
(com.fasterxml.jackson.core.JsonGenerator g, RuleMatch match, AnnotatedText text, ContextTools contextTools) private void
RuleMatchesAsJsonSerializer.writeReplacements
(com.fasterxml.jackson.core.JsonGenerator g, RuleMatch match) private void
Method parameters in org.languagetool.tools with type arguments of type RuleMatchModifier and TypeMethodDescriptionstatic String
Tools.correctTextFromMatches
(String contents, List<RuleMatch> matches) RuleMatchesAsJsonSerializer.ruleMatchesToJson
(List<RuleMatch> matches, String text, int contextSize, DetectedLanguage detectedLang) RuleMatchesAsJsonSerializer.ruleMatchesToJson
(List<RuleMatch> matches, List<RuleMatch> hiddenMatches, String text, int contextSize, DetectedLanguage detectedLang, String incompleteResultsReason) RuleMatchesAsJsonSerializer.ruleMatchesToJson
(List<RuleMatch> matches, List<RuleMatch> hiddenMatches, AnnotatedText text, int contextSize, DetectedLanguage detectedLang, String incompleteResultsReason) RuleMatchAsXmlSerializer.ruleMatchesToXml
(List<RuleMatch> ruleMatches, String text, int contextSize, Language lang) Deprecated.Get an XML representation of the given rule matches.RuleMatchAsXmlSerializer.ruleMatchesToXml
(List<RuleMatch> ruleMatches, String text, int contextSize, Language lang, Language motherTongue) Deprecated.Get an XML representation of the given rule matches.RuleMatchAsXmlSerializer.ruleMatchesToXml
(List<RuleMatch> ruleMatches, String text, int contextSize, StringTools.ApiPrintMode xmlMode, Language lang, List<String> unknownWords) Deprecated.Get an XML representation of the given rule matches.RuleMatchAsXmlSerializer.ruleMatchesToXmlSnippet
(List<RuleMatch> ruleMatches, String text, int contextSize) Deprecated.Get the XML snippet (i.e.private void
RuleMatchesAsJsonSerializer.writeMatchesSection
(String sectionName, com.fasterxml.jackson.core.JsonGenerator g, List<RuleMatch> matches, AnnotatedText text, ContextTools contextTools)
TextLevelRule.match(List, AnnotatedText)
instead