Search in sources :

Example 1 with ModifierFilter

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;
}
Also used : ListBuffer(com.sun.tools.javac.util.ListBuffer) ModifierFilter(com.sun.tools.javadoc.ModifierFilter) Method(java.lang.reflect.Method) RootDoc(com.sun.javadoc.RootDoc)

Aggregations

RootDoc (com.sun.javadoc.RootDoc)1 ListBuffer (com.sun.tools.javac.util.ListBuffer)1 ModifierFilter (com.sun.tools.javadoc.ModifierFilter)1 Method (java.lang.reflect.Method)1