Class Tagger


  • public class Tagger
    extends Object
    A wrapper around opennlp.tools.postag.POSTaggerME.
    • Constructor Detail

      • Tagger

        public Tagger​(String taggerModelUrl)
        Constructor.
        Parameters:
        taggerModelUrl - the URL of a POS tagging model
      • Tagger

        public Tagger​(InputStream taggerStream)
        Constructor.
        Parameters:
        taggerStream - the input stream of the POS tagging model
    • Method Detail

      • getPosTagger

        public opennlp.tools.postag.POSTaggerME getPosTagger()
                                                      throws IOException
        Get the POS tagger.
        Returns:
        a opennlp.tools.postag.POSTaggerME
        Throws:
        IOException - if inputString or taggerStream is invalid