コード例 #1
0
 private String getTreeAsStringOrg(final String testMachine) throws BCompoundException {
   final BParser parser = new BParser("testcase");
   final Start startNode = parser.parse(testMachine, false);
   final Ast2String ast2String = new Ast2String();
   startNode.apply(ast2String);
   final String string = ast2String.toString();
   return string;
 }
コード例 #2
0
 private String getTreeAsString(final String testMachine)
     throws BCompoundException, LexerException, IOException {
   final BParser parser = new BParser("testcase");
   Start ast = parser.eparse(testMachine, new Definitions());
   final Ast2String ast2String = new Ast2String();
   ast.apply(ast2String);
   final String string = ast2String.toString();
   return string;
 }