javadoc generics snafu

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

javadoc generics snafu

mgainty
i am attempting to have maven-javadoc-plugin to skip generation of doc for <T> generics here is the error:

[DEBUG] Configuring mojo org.apache.maven.plugins:maven-javadoc-plugin:2.8:jar from plugin realm ClassRealm[plugin>org.apache.maven.plugins:maven-javadoc-plugin:2.8, parent: sun.misc.Launcher$AppClassLoader@33909752]
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-javadoc-plugin:2.8:jar' with basic configurator -->
[DEBUG]   (f) aggregate = false
[DEBUG]   (f) attach = true
[DEBUG]   (f) author = true
[DEBUG]   (f) bootclasspathArtifacts = []
[DEBUG]   (f) bottom = Copyright &#169; {inceptionYear}-{currentYear} {organizationName}. All Rights Reserved.
[DEBUG]   (f) breakiterator = true
[DEBUG]   (f) debug = false
[DEBUG]   (f) defaultManifestFile = /spring/spring-hateoas/target/classes/META-INF/MANIFEST.MF
[DEBUG]   (f) detectJavaApiLink = true
[DEBUG]   (f) detectLinks = false
[DEBUG]   (f) detectOfflineLinks = true
[DEBUG]   (f) docfilessubdirs = true
[DEBUG]   (f) docletArtifact = groupId = 'null'
artifactId = 'null'
version = 'null'
[DEBUG]   (f) docletArtifacts = []
[DEBUG]   (f) doctitle = Spring Hateoas 0.9.0.RELEASE API
[DEBUG]   (f) encoding = UTF-8
[DEBUG]   (f) failOnError = true
[DEBUG]   (f) finalName = spring-hateoas-0.9.0.RELEASE
[DEBUG]   (f) groups = []
[DEBUG]   (f) header = Spring Hateoas
[DEBUG]   (f) includeDependencySources = false
[DEBUG]   (f) includeTransitiveDependencySources = false
[DEBUG]   (f) isOffline = true
[DEBUG]   (f) jarOutputDirectory = /spring/spring-hateoas/target
[DEBUG]   (f) javaApiLinks = {}
[DEBUG]   (f) javadocDirectory = /spring/spring-hateoas/src/main/javadoc
[DEBUG]   (f) javadocOptionsDir = /spring/spring-hateoas/target/javadoc-bundle-options
[DEBUG]   (f) keywords = false
[DEBUG]   (f) links = [http://static.springframework.org/spring/docs/3.1.x/javadoc-api, http://download.oracle.com/javase/1.5.0/docs/api]
[DEBUG]   (f) linksource = false
[DEBUG]   (f) localRepository =       id: local
      url: file:///etc/MGainty/.m2/repository/
   layout: default
snapshots: [enabled => true, update => always]
 releases: [enabled => true, update => always]

[DEBUG]   (f) nocomment = false
[DEBUG]   (f) nodeprecated = false
[DEBUG]   (f) nodeprecatedlist = false
[DEBUG]   (f) nohelp = false
[DEBUG]   (f) noindex = false
[DEBUG]   (f) nonavbar = false
[DEBUG]   (f) nooverview = false
[DEBUG]   (f) nosince = false
[DEBUG]   (f) notimestamp = false
[DEBUG]   (f) notree = false
[DEBUG]   (f) offlineLinks = []
[DEBUG]   (f) old = false
[DEBUG]   (f) outputDirectory = /spring/spring-hateoas/target/apidocs
[DEBUG]   (f) overview = /spring/spring-hateoas/src/main/javadoc/overview.html
[DEBUG]   (f) project = MavenProject: org.springframework.hateoas:spring-hateoas:0.9.0.RELEASE @ /spring/spring-hateoas/pom.xml
[DEBUG]   (f) quiet = true
[DEBUG]   (f) reactorProjects = [MavenProject: org.springframework.hateoas:spring-hateoas:0.9.0.RELEASE @ C:\spring\spring-hateoas\pom.xml]
[DEBUG]   (f) remoteRepositories = [      id: spring-libs-release
      url: http://repo.spring.io/libs-release
   layout: default
snapshots: [enabled => true, update => daily]
 releases: [enabled => true, update => daily]
,       id: central
      url: https://repo.maven.apache.org/maven2
   layout: default
snapshots: [enabled => false, update => daily]
 releases: [enabled => true, update => daily]
]
[DEBUG]   (f) resourcesArtifacts = []
[DEBUG]   (f) serialwarn = false
[DEBUG]   (f) session = org.apache.maven.execution.MavenSession@2e185cd7
[DEBUG]   (f) settings = org.apache.maven.execution.SettingsAdapter@7b1b1784
[DEBUG]   (f) show = protected
[DEBUG]   (f) skip = false
[DEBUG]   (f) source = 1.5
[DEBUG]   (f) sourceDependencyCacheDir = /spring/spring-hateoas/target/distro-javadoc-sources
[DEBUG]   (f) splitindex = false
[DEBUG]   (f) stylesheet = java
[DEBUG]   (f) stylesheetfile = /spring/spring-hateoas/src/main/javadoc/spring-javadoc.css
[DEBUG]   (f) tagletArtifact = groupId = 'null'
artifactId = 'null'
version = 'null'
[DEBUG]   (f) tagletArtifacts = []
[DEBUG]   (f) taglets = []
[DEBUG]   (f) tags = []
[DEBUG]   (f) use = true
[DEBUG]   (f) useDefaultManifestFile = false
[DEBUG]   (f) useStandardDocletOptions = true
[DEBUG]   (f) validateLinks = false
[DEBUG]   (f) verbose = false
[DEBUG]   (f) version = true
[DEBUG]   (f) windowtitle = Spring Hateoas 0.9.0.RELEASE API
[DEBUG] -- end configuration --
[DEBUG] Found Java API link: http://download.oracle.com/javase/6/docs/api/
[DEBUG] Trying to add links for modules...
[WARNING] Unable to find the resource '/spring/spring-hateoas/src/main/javadoc/spring-javadoc.css'. Using default Javadoc resources.
[DEBUG] /JDK18~1.0_1/jre/../bin/javadoc.exe @options @packages
[INFO]
7 errors
96 warnings
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 17.722 s
[INFO] Finished at: 2018-12-19T18:55:21-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.8:jar (default) on project spring-hateoas: MavenReportException: Error while creating archive:
[ERROR] Exit code: 1 - /spring-/hateoas/src/main/java/org/springframework/hateoas/PagedResources.java:88:

warning: no @param for <T>

[ERROR]  public static <T extends Resource<S>, S> PagedResources<S> wrap(Iterable<S> content, PageMetadata metadata) {

how do i teach javadoc to 'skip generation of javadoc for generic declarations'

Happy Holidays to all
martin
Reply | Threaded
Open this post in threaded view
|

Re: javadoc generics snafu

mgainty
doclint:-reference suppresses ALL errors on @param

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin>
 <configuration>
             <additionalparam>-Xdoclint:-reference</additionalparam>
             <additionalOptions>-Xdoclint:-reference/access</additionalOptions>
</configuration>

so in the end all @param errors are bypassed
instead of just bypassing faulty <T> declarations

its a 5min hack that will have to hold while i'm looking for more appropriate solution
MX

________________________________
From: Martin Gainty <[hidden email]>
Sent: Wednesday, December 19, 2018 7:10 PM
To: [hidden email]
Subject: javadoc generics snafu

i am attempting to have maven-javadoc-plugin to skip generation of doc for <T> generics here is the error:

[DEBUG] Configuring mojo org.apache.maven.plugins:maven-javadoc-plugin:2.8:jar from plugin realm ClassRealm[plugin>org.apache.maven.plugins:maven-javadoc-plugin:2.8, parent: sun.misc.Launcher$AppClassLoader@33909752]
[DEBUG] Configuring mojo 'org.apache.maven.plugins:maven-javadoc-plugin:2.8:jar' with basic configurator -->
[DEBUG]   (f) aggregate = false
[DEBUG]   (f) attach = true
[DEBUG]   (f) author = true
[DEBUG]   (f) bootclasspathArtifacts = []
[DEBUG]   (f) bottom = Copyright &#169; {inceptionYear}-{currentYear} {organizationName}. All Rights Reserved.
[DEBUG]   (f) breakiterator = true
[DEBUG]   (f) debug = false
[DEBUG]   (f) defaultManifestFile = /spring/spring-hateoas/target/classes/META-INF/MANIFEST.MF
[DEBUG]   (f) detectJavaApiLink = true
[DEBUG]   (f) detectLinks = false
[DEBUG]   (f) detectOfflineLinks = true
[DEBUG]   (f) docfilessubdirs = true
[DEBUG]   (f) docletArtifact = groupId = 'null'
artifactId = 'null'
version = 'null'
[DEBUG]   (f) docletArtifacts = []
[DEBUG]   (f) doctitle = Spring Hateoas 0.9.0.RELEASE API
[DEBUG]   (f) encoding = UTF-8
[DEBUG]   (f) failOnError = true
[DEBUG]   (f) finalName = spring-hateoas-0.9.0.RELEASE
[DEBUG]   (f) groups = []
[DEBUG]   (f) header = Spring Hateoas
[DEBUG]   (f) includeDependencySources = false
[DEBUG]   (f) includeTransitiveDependencySources = false
[DEBUG]   (f) isOffline = true
[DEBUG]   (f) jarOutputDirectory = /spring/spring-hateoas/target
[DEBUG]   (f) javaApiLinks = {}
[DEBUG]   (f) javadocDirectory = /spring/spring-hateoas/src/main/javadoc
[DEBUG]   (f) javadocOptionsDir = /spring/spring-hateoas/target/javadoc-bundle-options
[DEBUG]   (f) keywords = false
[DEBUG]   (f) links = [http://static.springframework.org/spring/docs/3.1.x/javadoc-api, http://download.oracle.com/javase/1.5.0/docs/api]
[DEBUG]   (f) linksource = false
[DEBUG]   (f) localRepository =       id: local
      url: file:///etc/MGainty/.m2/repository/
   layout: default
snapshots: [enabled => true, update => always]
 releases: [enabled => true, update => always]

[DEBUG]   (f) nocomment = false
[DEBUG]   (f) nodeprecated = false
[DEBUG]   (f) nodeprecatedlist = false
[DEBUG]   (f) nohelp = false
[DEBUG]   (f) noindex = false
[DEBUG]   (f) nonavbar = false
[DEBUG]   (f) nooverview = false
[DEBUG]   (f) nosince = false
[DEBUG]   (f) notimestamp = false
[DEBUG]   (f) notree = false
[DEBUG]   (f) offlineLinks = []
[DEBUG]   (f) old = false
[DEBUG]   (f) outputDirectory = /spring/spring-hateoas/target/apidocs
[DEBUG]   (f) overview = /spring/spring-hateoas/src/main/javadoc/overview.html
[DEBUG]   (f) project = MavenProject: org.springframework.hateoas:spring-hateoas:0.9.0.RELEASE @ /spring/spring-hateoas/pom.xml
[DEBUG]   (f) quiet = true
[DEBUG]   (f) reactorProjects = [MavenProject: org.springframework.hateoas:spring-hateoas:0.9.0.RELEASE @ C:\spring\spring-hateoas\pom.xml]
[DEBUG]   (f) remoteRepositories = [      id: spring-libs-release
      url: http://repo.spring.io/libs-release
   layout: default
snapshots: [enabled => true, update => daily]
 releases: [enabled => true, update => daily]
,       id: central
      url: https://repo.maven.apache.org/maven2
   layout: default
snapshots: [enabled => false, update => daily]
 releases: [enabled => true, update => daily]
]
[DEBUG]   (f) resourcesArtifacts = []
[DEBUG]   (f) serialwarn = false
[DEBUG]   (f) session = org.apache.maven.execution.MavenSession@2e185cd7
[DEBUG]   (f) settings = org.apache.maven.execution.SettingsAdapter@7b1b1784
[DEBUG]   (f) show = protected
[DEBUG]   (f) skip = false
[DEBUG]   (f) source = 1.5
[DEBUG]   (f) sourceDependencyCacheDir = /spring/spring-hateoas/target/distro-javadoc-sources
[DEBUG]   (f) splitindex = false
[DEBUG]   (f) stylesheet = java
[DEBUG]   (f) stylesheetfile = /spring/spring-hateoas/src/main/javadoc/spring-javadoc.css
[DEBUG]   (f) tagletArtifact = groupId = 'null'
artifactId = 'null'
version = 'null'
[DEBUG]   (f) tagletArtifacts = []
[DEBUG]   (f) taglets = []
[DEBUG]   (f) tags = []
[DEBUG]   (f) use = true
[DEBUG]   (f) useDefaultManifestFile = false
[DEBUG]   (f) useStandardDocletOptions = true
[DEBUG]   (f) validateLinks = false
[DEBUG]   (f) verbose = false
[DEBUG]   (f) version = true
[DEBUG]   (f) windowtitle = Spring Hateoas 0.9.0.RELEASE API
[DEBUG] -- end configuration --
[DEBUG] Found Java API link: http://download.oracle.com/javase/6/docs/api/
[DEBUG] Trying to add links for modules...
[WARNING] Unable to find the resource '/spring/spring-hateoas/src/main/javadoc/spring-javadoc.css'. Using default Javadoc resources.
[DEBUG] /JDK18~1.0_1/jre/../bin/javadoc.exe @options @packages
[INFO]
7 errors
96 warnings
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 17.722 s
[INFO] Finished at: 2018-12-19T18:55:21-05:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:2.8:jar (default) on project spring-hateoas: MavenReportException: Error while creating archive:
[ERROR] Exit code: 1 - /spring-/hateoas/src/main/java/org/springframework/hateoas/PagedResources.java:88:

warning: no @param for <T>

[ERROR]  public static <T extends Resource<S>, S> PagedResources<S> wrap(Iterable<S> content, PageMetadata metadata) {

how do i teach javadoc to 'skip generation of javadoc for generic declarations'

Happy Holidays to all
martin