Class HunspellNoSuggestionRule
- java.lang.Object
-
- org.languagetool.rules.Rule
-
- org.languagetool.rules.spelling.SpellingCheckRule
-
- org.languagetool.rules.spelling.hunspell.HunspellRule
-
- org.languagetool.rules.spelling.hunspell.HunspellNoSuggestionRule
-
public class HunspellNoSuggestionRule extends HunspellRule
LikeHunspellRule
, but does not offer suggestions for incorrect words as that is very slow with Hunspell.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
RULE_ID
-
Fields inherited from class org.languagetool.rules.spelling.hunspell.HunspellRule
FILE_EXTENSION, hunspellDict, needsInit, nonWordPattern, suggestionsOrderer
-
Fields inherited from class org.languagetool.rules.spelling.SpellingCheckRule
ignoreWordsWithLength, language, languageModel, LANGUAGETOOL, LANGUAGETOOLER, wordListLoader
-
-
Constructor Summary
Constructors Constructor Description HunspellNoSuggestionRule(java.util.ResourceBundle messages, Language language, UserConfig userConfig, java.util.List<Language> altLanguages)
HunspellNoSuggestionRule(java.util.ResourceBundle messages, Language language, UserConfig userConfig, java.util.List<Language> altLanguages, IncorrectExample incorrectExample, CorrectExample correctedExample)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getDescription()
A short description of the error this rule can detect, usually in the language of the text that is checked.java.lang.String
getId()
A string used to identify the rule in e.g.java.util.List<java.lang.String>
getSuggestions(java.lang.String word)
-
Methods inherited from class org.languagetool.rules.spelling.hunspell.HunspellRule
getActiveChecks, getDictFilenameInResources, getSentenceTextWithoutUrlsAndImmunizedTokens, init, isAcceptedWordFromLanguage, isMisspelled, isQuotedCompound, match, sortSuggestionByQuality, tokenizeText
-
Methods inherited from class org.languagetool.rules.spelling.SpellingCheckRule
acceptedInAlternativeLanguage, acceptPhrases, addIgnoreTokens, addIgnoreWords, addProhibitedWords, addSuggestionsToRuleMatch, createWrongSplitMatch, expandLine, filterDupes, filterSuggestions, getAdditionalProhibitFileNames, getAdditionalSpellingFileNames, getAdditionalSuggestions, getAdditionalTopSuggestions, getAlternativeLangSpellingRules, getAntiPatterns, getIgnoreFileName, getLanguageVariantSpellingFileName, getProhibitFileName, getSpellingFileName, ignoreToken, ignoreWord, ignoreWord, isDictionaryBasedSpellingRule, isEMail, isProhibited, isUrl, reorderSuggestions, setConsiderIgnoreWords, setConvertsCase, startsWithIgnoredWord
-
Methods inherited from class org.languagetool.rules.Rule
addExamplePair, estimateContextForSureMatch, getCategory, getConfigureText, getCorrectExamples, getDefaultValue, getErrorTriggeringExamples, getIncorrectExamples, getLocQualityIssueType, getMaxConfigurableValue, getMinConfigurableValue, getSentenceWithImmunization, getUrl, hasConfigurableValue, isDefaultOff, isDefaultTempOff, isOfficeDefaultOff, isOfficeDefaultOn, makeAntiPatterns, setCategory, setCorrectExamples, setDefaultOff, setDefaultOn, setDefaultTempOff, setErrorTriggeringExamples, setIncorrectExamples, setLocQualityIssueType, setOfficeDefaultOff, setOfficeDefaultOn, setUrl, supportsLanguage, toRuleMatchArray, useInOffice
-
-
-
-
Field Detail
-
RULE_ID
public static final java.lang.String RULE_ID
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
HunspellNoSuggestionRule
public HunspellNoSuggestionRule(java.util.ResourceBundle messages, Language language, UserConfig userConfig, java.util.List<Language> altLanguages)
-
HunspellNoSuggestionRule
public HunspellNoSuggestionRule(java.util.ResourceBundle messages, Language language, UserConfig userConfig, java.util.List<Language> altLanguages, IncorrectExample incorrectExample, CorrectExample correctedExample)
- Since:
- 3.3
-
-
Method Detail
-
getId
public java.lang.String getId()
Description copied from class:Rule
A string used to identify the rule in e.g. configuration files. This string is supposed to be unique and to stay the same in all upcoming versions of LanguageTool. It's supposed to contain only the charactersA-Z
and the underscore.- Overrides:
getId
in classHunspellRule
-
getDescription
public java.lang.String getDescription()
Description copied from class:Rule
A short description of the error this rule can detect, usually in the language of the text that is checked.- Overrides:
getDescription
in classHunspellRule
-
getSuggestions
public java.util.List<java.lang.String> getSuggestions(java.lang.String word) throws java.io.IOException
- Overrides:
getSuggestions
in classHunspellRule
- Throws:
java.io.IOException
-
-