org.languagetool.rules.ca
Class CastellanismesReplaceRule

Object
  extended by Rule
      extended by AbstractSimpleReplaceRule
          extended by CastellanismesReplaceRule

public class CastellanismesReplaceRule
extends AbstractSimpleReplaceRule

A rule that matches words or phrases which should not be used and suggests correct ones instead. Catalan implementations for Castelianisms, kept separate for an individual error message. Loads the list of words from rules/ca/castellanismes.txt.

Author:
Jimmy O'Regan Based on pl/SimpleReplaceRule.java

Field Summary
static String CATALAN_CASTELLANISMES_REPLACE_RULE
           
 
Constructor Summary
CastellanismesReplaceRule(ResourceBundle messages)
           
 
Method Summary
 String getDescription()
           
 String getFileName()
           
 String getId()
          An ASCII-only string used to identify the rule in e.g. configuration files.
 Locale getLocale()
          locale used on case-conversion
 String getShort()
           
 String getSuggestion()
           
 boolean isCaseSensitive()
          use case-insensitive matching.
 
Methods inherited from class AbstractSimpleReplaceRule
getEncoding, match, reset
 
Methods inherited from class Rule
addRuleMatch, clearMatches, getCategory, getCorrectExamples, getIncorrectExamples, getMatches, getMatchesIndex, isDefaultOff, isInMatches, isInRemoved, isParagraphBackTrack, setAsDeleted, setCategory, setCorrectExamples, setDefaultOff, setIncorrectExamples, setParagraphBackTrack, supportsLanguage
 
Methods inherited from class Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CATALAN_CASTELLANISMES_REPLACE_RULE

public static final String CATALAN_CASTELLANISMES_REPLACE_RULE
See Also:
Constant Field Values
Constructor Detail

CastellanismesReplaceRule

public CastellanismesReplaceRule(ResourceBundle messages)
                          throws IOException
Throws:
IOException
Method Detail

getFileName

public final String getFileName()
Specified by:
getFileName in class AbstractSimpleReplaceRule

getId

public final String getId()
Description copied from class: Rule
An ASCII-only 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.

Overrides:
getId in class AbstractSimpleReplaceRule

getDescription

public String getDescription()
Overrides:
getDescription in class AbstractSimpleReplaceRule

getShort

public String getShort()
Overrides:
getShort in class AbstractSimpleReplaceRule

getSuggestion

public String getSuggestion()
Overrides:
getSuggestion in class AbstractSimpleReplaceRule

isCaseSensitive

public boolean isCaseSensitive()
use case-insensitive matching.

Overrides:
isCaseSensitive in class AbstractSimpleReplaceRule
Returns:
true if the rule is case-sensitive, false otherwise.

getLocale

public Locale getLocale()
locale used on case-conversion

Overrides:
getLocale in class AbstractSimpleReplaceRule
Returns:
the locale used for case conversion when AbstractSimpleReplaceRule.isCaseSensitive() is set to false.


Copyright © 2005-2011 Daniel Naber