/**
* Sets up the Java parser.
* @param javaFile the Java contents to parse.
* @return the {@link JavaParser} instance.
* @throws RecognitionException if the comment cannot be parsed.
* @throws IOException if the file could not be read.
*/
@SuppressWarnings("unchecked")
@NotNull
protected JavaParser setUpParser(@NotNull final File javaFile)
throws RecognitionException,
IOException
{
@NotNull final JavaParser result;
@NotNull final JavaLexer t_Lexer =
new JavaLexer(new ANTLRFileStream(javaFile.getAbsolutePath()));
@NotNull final CommonTokenStream t_Tokens = new CommonTokenStream(t_Lexer);
result = new JavaParser(t_Tokens);
return result;
}
AbstractTemplatesTest.java 文件源码
java
阅读 20
收藏 0
点赞 0
评论 0
项目:queryj
作者:
评论列表
文章目录