Within a Java/Quarkus project, I generate models from a YAML, using this openapi-generator-maven-plugin (version 7.22.0).
In POJOs, there's annotation @jakarta.annotation.Generated. But Enum don't have this one
My issue is with plugin ErrorProne, there's a flag available XepDisableWarningsInGeneratedCode, which allows us to ignore warnings triggered by generated code. ErrorProne.info
But since my generated Enums don't have this annotation, Warnings are triggered
I can add annotation @generated in openapi-generator-maven-plugin with the additionalEnumTypeAnnotations
I'm wondering why generated Enum don't have this annotation by default, like POJOs ?
See there : https://github.com/OpenAPITools/openapi-generator/blob/fd651513978c5f2ac7028caee9c5caa841d0b6c1/modules/openapi-generator/src/main/resources/JavaSpring/enumClass.mustache for a correction, to use generatedAnnotation ? I'm not familiar with "mustache" language
Within a Java/Quarkus project, I generate models from a YAML, using this openapi-generator-maven-plugin (version 7.22.0).
In POJOs, there's annotation
@jakarta.annotation.Generated. But Enum don't have this oneMy issue is with plugin ErrorProne, there's a flag available
XepDisableWarningsInGeneratedCode, which allows us to ignore warnings triggered by generated code. ErrorProne.infoBut since my generated Enums don't have this annotation, Warnings are triggered
I can add annotation @generated in openapi-generator-maven-plugin with the
additionalEnumTypeAnnotationsI'm wondering why generated Enum don't have this annotation by default, like POJOs ?
See there : https://github.com/OpenAPITools/openapi-generator/blob/fd651513978c5f2ac7028caee9c5caa841d0b6c1/modules/openapi-generator/src/main/resources/JavaSpring/enumClass.mustache for a correction, to use generatedAnnotation ? I'm not familiar with "mustache" language