class HiveLanguageParser {

  public void parse(String statement, NodeProcessor nodeProcessor) {
    Context parserContext;
    try {
      parserContext = new Context(hiveConf);
    } catch (IOException e) {
      throw new RuntimeException("Unable to create Context for parser", e);
    }
    ParseDriver parserDriver = new ParseDriver();

    ASTNode tree;
    try {
      tree = parserDriver.parse(statement, parserContext);
    } catch (ParseException e) {
      throw new HiveParseException(e);
    }
    // create a walker which walks the tree in a DFS manner while maintaining
    // the operator stack. The dispatcher
    // generates the plan from the operator tree
    Map<Rule, NodeProcessor> rules = new LinkedHashMap<>();
    // The dispatcher fires the processor corresponding to the closest matching
    // rule and passes the context along
    Dispatcher dispatcher = new DefaultRuleDispatcher(nodeProcessor, rules, null);
    GraphWalker walker = new DefaultGraphWalker(dispatcher);
    // Create a list of topop nodes
    List<Node> topNodes = new ArrayList<>();
    topNodes.add(tree);
    try {
      walker.startWalking(topNodes, null);
    } catch (SemanticException e) {
      throw new HiveSemanticException(e);
    }
  }

  public  HiveLanguageParser(HiveConf hiveConfiguration);

}