Parser/QueryParser.cpp
void QueryParser::printNode(antlr4::ParserRuleContext *ctx, 
	const char *nodeTypeName)
{
	int dep = ctx->depth();

	// Print tabs according to node's depth in tree
	for (int i = 0; i < dep; i++)
		cout << '\t';

	// Print node type
	cout << "Type: " << nodeTypeName << ' ';

	// Print what text a node has matched
	cout << "Text: " << ctx->getText() << endl;

}
/**
	Print the info of the parse tree node pointed to by ctx.

	@param ctx pointer to the requested parse tree node's context.
	@param nodeTypeName type of the parse tree node.
*/
Print the info of the parse tree node pointed to by ctx.
Print the info of the parse tree node pointed to by ctx .
void QueryParser::printNode(antlr4::ParserRuleContext *ctx, 
	const char *nodeTypeName)
{
	int dep = ctx->depth();
	for (int i = 0; i < dep; i++)
		cout << '\t';
	cout << "Type: " << nodeTypeName << ' ';
	cout << "Text: " << ctx->getText() << endl;
}
void QueryParser :: printNode ( antlr4 :: ParserRuleContext * ctx , const char * nodeTypeName ) { int dep = ctx -> depth ( ) ; for ( int i = 0 ; i < dep ; i ++ ) cout << ' \t ' ; cout << " " << nodeTypeName << ' ' ; cout << " " << ctx -> getText ( ) << endl ; }
Print the info of the parse tree node pointed to by ctx.
Print the info of the parse tree node pointed to by ctx .
// Print tabs according to node's depth in tree // Print node type // Print what text a node has matched