Class ParserFactory


  • public final class ParserFactory
    extends java.lang.Object
    Implements a factory for Parser.
    Author:
    Simon Thoresen Hult
    • Method Detail

      • newInstance

        public static Parser newInstance​(Query.Type type,
                                         ParserEnvironment environment)
        Creates a Parser appropriate for the given Query.Type, providing the Parser with access to the ParserEnvironment given.
        Parameters:
        type - the query type for which to create a Parser
        environment - the environment settings to attach to the Parser
        Returns:
        the created Parser