use of com.sun.tools.javadoc.ModifierFilter in project checkstyle by checkstyle.
the class TokenTypesDocletTest method getRootDoc.
private static RootDoc getRootDoc(JavadocTool javadocTool, ListBuffer<String[]> options, ListBuffer<String> names) throws Exception {
final Method getRootDocImpl = getMethodGetRootDocImplByReflection();
final RootDoc rootDoc;
if (System.getProperty("java.version").startsWith("1.7.")) {
rootDoc = (RootDoc) getRootDocImpl.invoke(javadocTool, "", "UTF-8", new ModifierFilter(ModifierFilter.ALL_ACCESS), names.toList(), options.toList(), false, new ListBuffer<String>().toList(), new ListBuffer<String>().toList(), false, false, false);
} else {
rootDoc = (RootDoc) getRootDocImpl.invoke(javadocTool, "", "UTF-8", new ModifierFilter(ModifierFilter.ALL_ACCESS), names.toList(), options.toList(), new ListBuffer<JavaFileObject>().toList(), false, new ListBuffer<String>().toList(), new ListBuffer<String>().toList(), false, false, false);
}
return rootDoc;
}
Aggregations