Skip to content

Groovydoc: Fail to generate javadoc #340

@cliviu

Description

@cliviu

Hi,
I have classes containing Java records. I cannot generate javadoc for them using gmavenplus and groovydoc. I get the following message:

Attempting to ignore error parsing Java source file: mypackage/MyRecord.java
Consider reporting the error to the Groovy project: https://issues.apache.org/jira/browse/GROOVY
... or directly to the JavaParser project: https://github.com/javaparser/javaparser/issues
Error: (line 3,col 1) Record Declarations are not supported. Pay attention that this feature is supported starting from 'JAVA_14' language level. If you need that feature the language level must be configured in the configuration before parsing the source files.

I have configured the languageLevel like this

              `<execution>
                    <id>attach-docs</id>
                    <phase>prepare-package</phase>
                    <goals>
                        <goal>groovydoc</goal>
                    </goals>
                    <configuration>
                        <languageLevel>JAVA_17</languageLevel>
                    </configuration>
                </execution>`

but then ...

Failed to execute goal org.codehaus.gmavenplus:gmavenplus-plugin:4.2.1:groovydoc (attach-docs) on project xxx: Execution attach-docs of goal org.codehaus.gmavenplus:gmavenplus-plugin:4.2.1:groovydoc failed: argument type mismatch ->

What am I doing wrong?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions