Skip to content
Snippets Groups Projects

Full-project, detailed Javadoc generation

1 file
+ 64
1
Compare changes
  • Side-by-side
  • Inline
+ 64
1
@@ -74,7 +74,7 @@ allprojects {
spotbugs {
toolVersion = '3.1.12'
sourceSets = [ sourceSets.main ]
}
@@ -122,6 +122,69 @@ allprojects {
}
}
task fullJavadoc(type: Javadoc) {
options.addBooleanOption('html5', true)
options.encoding 'UTF-8'
options.JFlags [ '-Dhttp.agent=autadoc' ] // javadoc.io blocks the standard Java User-Agent
options.showAll() // Also include private fields
options.source '11' // Enable Java 11 compatibility
options.addBooleanOption('keywords', true) // HTML meta keywords
options.addBooleanOption('use', true) // Type and package usage overviews
options.addBooleanOption('linksource', true) // Include the source and link to it
// Linking the javadoc here when adding a new dependency is not required, but it allows
// the javadoc tool to generate a hyperlink for that class/package/whatever. Having a direct
// link to the dependency's javadoc helps discoverability (and makes the documentation ever
// so slightly more readable), but nothing breaks if the tool can't find a link.
options.addMultilineStringsOption('link').setValue([
'https://docs.oracle.com/en/java/javase/11/docs/api/',
'https://docs.spring.io/spring-framework/docs/current/javadoc-api/',
'https://docs.spring.io/spring-data/commons/docs/current/api/',
'https://docs.spring.io/spring-data/mongodb/docs/current/api/',
'https://docs.spring.io/spring-security/site/docs/current/api/',
'https://build.shibboleth.net/nexus/content/sites/site/java-opensaml/3.4.2/apidocs/',
'https://www.slf4j.org/apidocs/',
'https://freemarker.apache.org/docs/api/',
'https://tomcat.apache.org/tomcat-9.0-doc/api/',
'https://tomcat.apache.org/tomcat-9.0-doc/servletapi/',
'https://hc.apache.org/httpcomponents-client-ga/httpclient/apidocs/',
'https://commons.apache.org/proper/commons-compress/javadocs/api-1.18/',
'https://commons.apache.org/proper/commons-fileupload/javadocs/api-release/',
'https://commons.apache.org/proper/commons-csv/apidocs/',
'http://findbugs.sourceforge.net/api/',
'https://fasterxml.github.io/jackson-core/javadoc/2.9/',
'https://fasterxml.github.io/jackson-databind/javadoc/2.9/',
'https://fasterxml.github.io/jackson-annotations/javadoc/2.9/',
'https://prometheus.github.io/client_java/',
'https://static.javadoc.io/com.j2html/j2html/1.4.0/',
'https://static.javadoc.io/org.xerial/sqlite-jdbc/3.27.2.1/',
'https://static.javadoc.io/io.github.azagniotov/ant-style-path-matcher/1.0.0/',
'https://static.javadoc.io/net.sourceforge.plantuml/plantuml/8059/',
'https://static.javadoc.io/com.github.javaparser/javaparser-core/3.13.10/',
'https://static.javadoc.io/net.sourceforge.pmd/pmd-core/6.10.0/',
'https://static.javadoc.io/com.thoughtworks.qdox/qdox/2.0-M10',
'https://static.javadoc.io/com.github.mauricioaniche/ck/0.3.1/',
'https://static.javadoc.io/nl.f00f/test-smell-detector/0.0.3/',
'https://static.javadoc.io/nl.f00f/auta-srf/2.0.0/',
'https://static.javadoc.io/net.wukl/cacodi/1.2.0/',
'https://static.javadoc.io/com.google.code.gson/gson/2.8.5/',
'https://static.javadoc.io/com.google.code.findbugs/jsr305/3.0.1/',
'https://static.javadoc.io/org.yaml/snakeyaml/1.19/',
'https://static.javadoc.io/org.jetbrains/annotations/17.0.0/'
])
// test-common has test classes in its main source set, so filter this out because it is
// not useful (and even generates very confusing javadoc because of package conflicts)
source allprojects.collect { it.name != 'test-common' ? it.sourceSets.main.allJava : [] }
// Only include production classes, not test classes
classpath = files(allprojects.collect { it.sourceSets.main.compileClasspath })
// TODO: this doesn't work. Excluding the source files also doesn't work. Help.
options.addStringOption('exclude', 'nl.tudelft.ewi.auta.checker.grammar.*')
}
tasks.downloadLicenses.dependsOn ':worker:downloadLicenses', ':core:downloadLicenses'
task stage(dependsOn: ['build', 'clean'])
Loading