Package org.languagetool.rules.pt
Class PortugueseClicheRule
java.lang.Object
org.languagetool.rules.Rule
org.languagetool.rules.AbstractSimpleReplaceRule2
org.languagetool.rules.pt.PortugueseClicheRule
A rule that matches words which should not be used and suggests correct ones instead.
Romanian implementations. Loads the list of words from
/ro/replace.txt.- Since:
- 3.6
-
Nested Class Summary
Nested classes/interfaces inherited from class org.languagetool.rules.AbstractSimpleReplaceRule2
AbstractSimpleReplaceRule2.CaseSensitivy -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Stringstatic final Stringprivate static final LocaleFields inherited from class org.languagetool.rules.AbstractSimpleReplaceRule2
language, subRuleSpecificIds -
Constructor Summary
ConstructorsConstructorDescriptionPortugueseClicheRule(ResourceBundle messages, String path, Language language) -
Method Summary
Modifier and TypeMethodDescriptionA short description of the error this rule can detect, usually in the language of the text that is checked.getId()A string used to identify the rule in e.g.locale used on case-conversiongetShort()getUrl()An optional URL describing the rule match in more detail.Methods inherited from class org.languagetool.rules.AbstractSimpleReplaceRule2
checkKeyWordsAreKnownToSpeller, checkKeyWordsAreUnknownToSpeller, getCaseSensitivy, getDescription, getFilePaths, getWrongWords, isCheckingCase, isException, isIgnoreShortUppercaseWords, isPunctuationStart, isRuleMatchException, isTokenException, match, separateKeyWordsBySpeller, setIgnoreShortUppercaseWords, setRuleHasSuggestions, useSubRuleSpecificIdsMethods inherited from class org.languagetool.rules.Rule
addExamplePair, addTags, addToneTags, cacheAntiPatterns, estimateContextForSureMatch, getAntiPatterns, getCategory, getCorrectExamples, getDistanceTokens, getErrorTriggeringExamples, getFullId, getIncorrectExamples, getLocQualityIssueType, getMinPrevMatches, getPriority, getRuleOptions, getSentenceWithImmunization, getSourceFile, getSubId, getTags, getToneTags, hasTag, hasToneTag, isDefaultOff, isDefaultTempOff, isDictionaryBasedSpellingRule, isGoalSpecific, isIncludedInHiddenMatches, isOfficeDefaultOff, isOfficeDefaultOn, isPremium, makeAntiPatterns, setCategory, setCorrectExamples, setDefaultOff, setDefaultOn, setDefaultTempOff, setDistanceTokens, setErrorTriggeringExamples, setExamplePair, setGoalSpecific, setIncludedInHiddenMatches, setIncorrectExamples, setLocQualityIssueType, setMinPrevMatches, setOfficeDefaultOff, setOfficeDefaultOn, setPremium, setPriority, setTags, setToneTags, setUrl, supportsLanguage, toRuleMatchArray, useInOffice
-
Field Details
-
PORTUGUESE_CLICHE_RULE
- See Also:
-
PT_LOCALE
-
path
-
-
Constructor Details
-
PortugueseClicheRule
-
-
Method Details
-
getFileNames
- Specified by:
getFileNamesin classAbstractSimpleReplaceRule2
-
getId
Description copied from class:RuleA 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-Zand the underscore.- Specified by:
getIdin classAbstractSimpleReplaceRule2
-
getDescription
Description copied from class:RuleA short description of the error this rule can detect, usually in the language of the text that is checked.- Specified by:
getDescriptionin classAbstractSimpleReplaceRule2- Returns:
- A string where
$matchwill be replaced with the matching word.
-
getShort
- Specified by:
getShortin classAbstractSimpleReplaceRule2
-
getMessage
- Specified by:
getMessagein classAbstractSimpleReplaceRule2- Returns:
- A string where
$matchwill be replaced with the matching word and$suggestionswill be replaced with the alternatives. This is the string shown to the user.
-
getSuggestionsSeparator
- Overrides:
getSuggestionsSeparatorin classAbstractSimpleReplaceRule2- Returns:
- the word used to separate multiple suggestions; used only before last suggestion, the rest are comma-separated.
-
getUrl
Description copied from class:RuleAn optional URL describing the rule match in more detail. Typically points to a dictionary or grammar website with explanations and examples. Will returnnullfor rules that have no URL. -
getLocale
Description copied from class:AbstractSimpleReplaceRule2locale used on case-conversion- Specified by:
getLocalein classAbstractSimpleReplaceRule2
-