Package graphql.parser
Class NodeToRuleCapturingParser
java.lang.Object
graphql.parser.Parser
graphql.parser.NodeToRuleCapturingParser
A parser that will capture parsing context data which can be later used for accessing tokens that are discarded
during the conventional parsing process (like comments).
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class graphql.parser.Parser
CHANNEL_COMMENTS, CHANNEL_WHITESPACE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected GraphqlAntlrToLanguage
getAntlrToLanguage
(org.antlr.v4.runtime.CommonTokenStream tokens, MultiSourceReader multiSourceReader, ParserEnvironment environment) Allows you to override the ANTLR to AST code.Methods inherited from class graphql.parser.Parser
parse, parse, parseDocument, parseDocument, parseDocument, parseFieldDefinition, parseType, parseValue
-
Constructor Details
-
NodeToRuleCapturingParser
public NodeToRuleCapturingParser()
-
-
Method Details
-
getAntlrToLanguage
protected GraphqlAntlrToLanguage getAntlrToLanguage(org.antlr.v4.runtime.CommonTokenStream tokens, MultiSourceReader multiSourceReader, ParserEnvironment environment) Description copied from class:Parser
Allows you to override the ANTLR to AST code.- Overrides:
getAntlrToLanguage
in classParser
- Parameters:
tokens
- the token streammultiSourceReader
- the source of the query documentenvironment
- the parser environment- Returns:
- a new GraphqlAntlrToLanguage instance
-
getParserContext
-