Class SentimentFactory

java.lang.Object
opennlp.tools.util.BaseToolFactory
opennlp.tools.sentiment.SentimentFactory

public class SentimentFactory extends BaseToolFactory
Class for creating sentiment factories for training.
  • Constructor Details

    • SentimentFactory

      public SentimentFactory()
  • Method Details

    • validateArtifactMap

      public void validateArtifactMap() throws opennlp.tools.util.InvalidFormatException
      Validates the artifact map --> nothing to validate.
      Specified by:
      validateArtifactMap in class BaseToolFactory
      Throws:
      opennlp.tools.util.InvalidFormatException - Thrown if validation found invalid states.
    • createContextGenerator

      public SentimentContextGenerator createContextGenerator()
      Creates a new context generator.
      Returns:
      a context generator for Sentiment Analysis
    • getTokenizer

      public opennlp.tools.tokenize.Tokenizer getTokenizer()
      Returns:
      Retrieves the Tokenizer.