@Test public void testParse() { String sql = "use sharding_db"; UseStatement useStatement = (UseStatement) ParseEngine.parse(sql); assertThat(useStatement.getSchemeName().getIdentifier().getValue(), is("sharding_db")); }
public static ASTNode parse(final String sql) { ParseTree parseTree = createParseTree(sql); return new SQLVisitor().visit(parseTree.getChild(0)); }
ParseEngine { public static ASTNode parse(final String sql) { ParseTree parseTree = createParseTree(sql); return new SQLVisitor().visit(parseTree.getChild(0)); } }
ParseEngine { public static ASTNode parse(final String sql) { ParseTree parseTree = createParseTree(sql); return new SQLVisitor().visit(parseTree.getChild(0)); }  }
ParseEngine { public static ASTNode parse(final String sql) { ParseTree parseTree = createParseTree(sql); return new SQLVisitor().visit(parseTree.getChild(0)); }  static ASTNode parse(final String sql); }
ParseEngine { public static ASTNode parse(final String sql) { ParseTree parseTree = createParseTree(sql); return new SQLVisitor().visit(parseTree.getChild(0)); }  static ASTNode parse(final String sql);  }