Package opennlp.tools.parser

# Class ParserFactory

java.lang.Object
opennlp.tools.parser.ParserFactory

public class ParserFactory extends Object

- ## Method Summary

  Modifier and Type
  Method
  Description
  `static opennlp.tools.parser.Parser`
  `create(ParserModel model)`
  Instantiates a `Parser` via a given `model` and default configuration parameters (see: `AbstractBottomUpParser`).
  `static opennlp.tools.parser.Parser`
  `create(ParserModel model, int beamSize, double advancePercentage)`
  Instantiates a `Parser` via a given `model` and other configuration parameters.

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Method Details

  - ### create

    public static opennlp.tools.parser.Parser create(ParserModel model, int beamSize, double advancePercentage)
    Instantiates a `Parser` via a given `model` and other configuration parameters.
    Parameters:
      `model` - The `ParserModel` to use.
      `beamSize` - The number of different parses kept during parsing.
      `advancePercentage` - The minimal amount of probability mass which advanced outcomes must represent. Only outcomes which contribute to the top `advancePercentage` will be explored.
    Returns:
      A valid `Parser` instance.
    Throws:
      `IllegalStateException` - Thrown if the `ParserType` is not supported.
    See Also:
      - `Parser`
      - `ParserModel`

  - ### create

    public static opennlp.tools.parser.Parser create(ParserModel model)
    Instantiates a `Parser` via a given `model` and default configuration parameters (see: `AbstractBottomUpParser`).
    Parameters:
      `model` - The `ParserModel` to use.
    Returns:
      A valid `Parser` instance.
    Throws:
      `IllegalStateException` - Thrown if the `ParserType` is not supported.
    See Also:
      - `Parser`
      - `AbstractBottomUpParser`