Class EsperantoTagger

java.lang.Object
org.languagetool.tagging.eo.EsperantoTagger
All Implemented Interfaces:
Tagger

public class EsperantoTagger extends Object implements Tagger
A part-of-speech tagger for Esperanto.
  • Field Details

    • manualTagger

      private ManualTagger manualTagger
    • setTransitiveVerbs

      private Set<String> setTransitiveVerbs
    • setIntransitiveVerbs

      private Set<String> setIntransitiveVerbs
    • patternVerb

      private static final Pattern patternVerb
    • patternPrefix

      private static final Pattern patternPrefix
    • patternSuffix

      private static final Pattern patternSuffix
    • patternParticiple

      private static final Pattern patternParticiple
    • setNonParticiple

      private Set<String> setNonParticiple
    • patternTabelvorto

      private static final Pattern patternTabelvorto
    • patternTabelvortoAdverb

      private static final Pattern patternTabelvortoAdverb
  • Constructor Details

    • EsperantoTagger

      public EsperantoTagger()
  • Method Details

    • xSystemToUnicode

      private static String xSystemToUnicode(String s)
    • loadWords

      private Set<String> loadWords(InputStream stream) throws IOException
      Load list of words from UTF-8 file (one word per line).
      Throws:
      IOException
    • lazyInit

      private void lazyInit() throws IOException
      Throws:
      IOException
    • findTransitivity

      private String findTransitivity(String verb)
    • tag

      public List<AnalyzedTokenReadings> tag(List<String> sentenceTokens) throws IOException
      Description copied from interface: Tagger
      Returns a list of AnalyzedTokens that assigns each term in the sentence some kind of part-of-speech information (not necessarily just one tag).

      Note that this method takes exactly one sentence. Its implementation may implement special cases for the first word of a sentence, which is usually written with an uppercase letter.

      Specified by:
      tag in interface Tagger
      Parameters:
      sentenceTokens - the text as returned by a WordTokenizer
      Throws:
      IOException
    • createNullToken

      public AnalyzedTokenReadings createNullToken(String token, int startPos)
      Description copied from interface: Tagger
      Create the AnalyzedToken used for whitespace and other non-words. Use null as the POS tag for this token.
      Specified by:
      createNullToken in interface Tagger
    • createToken

      public AnalyzedToken createToken(String token, String posTag)
      Description copied from interface: Tagger
      Create a token specific to the language of the implementing class.
      Specified by:
      createToken in interface Tagger