Class BitextRule

    • Constructor Detail

      • BitextRule

        public BitextRule()
    • Method Detail

      • getMessage

        public abstract String getMessage()
      • setSourceLanguage

        public final void setSourceLanguage​(Language lang)
        Set the source language. If the language is not supported by LT, you need to use the default tokenizers etc.
        Parameters:
        lang - Source Language
      • getSourceLanguage

        public final Language getSourceLanguage()
      • setCorrectBitextExamples

        public final void setCorrectBitextExamples​(List<StringPair> correctExamples)
        Set the examples that are correct and thus do not trigger the rule.
      • getCorrectBitextExamples

        public final List<StringPair> getCorrectBitextExamples()
        Get example sentences that are correct and thus will not match this rule.
      • setIncorrectBitextExamples

        public final void setIncorrectBitextExamples​(List<IncorrectBitextExample> incorrectExamples)
        Set the examples that are incorrect and thus do trigger the rule.
      • getIncorrectBitextExamples

        public final List<IncorrectBitextExample> getIncorrectBitextExamples()
        Get example sentences that are incorrect and thus will match this rule.