You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description:
When using lombok and add javadoc on field inside a class, warnings are thrown when generating javadoc, which depends on delombok task.
To Reproduce:
Create a class with Value and Builder lombok annotation. Add javadoc on fields inside it and override some builder methods. For example,
/**
* Class used to store a unit of log.
*/
@Value
@Builder
public class Log {
@NonNull
private final Severity severity;
/**
* Should be specified.
*/
private final String message;
/**
* Optional field. {@link Log.Category#UNCATEGORIZED} by default.
*/
private final Category category;
public static class LogBuilder {
public LogBuilder message(@NonNull String pattern, Object... arguments) {
message = MessageFormat.format(pattern.replace("'", "''"), arguments);
if (!message.endsWith(".")) {
message = message + ".";
}
return this;
}
public Log build() {
if (category == null) {
category = Category.UNCATEGORIZED;
}
return new Log(severity, message, category);
}
}
}
Then run ./gradlew javadoc. Actual behaviour:
Task :javadoc
warning: no @return
public Category getCategory() {
^
warning: no @param for category
public LogBuilder category(final Category category) {
^
warning: no @return
public LogBuilder category(final Category category) {
^
3 warnings
if add java docs @param and @return to java docs on category field, only one warning will bet thrown:
Task :javadoc
warning: no @return
public LogBuilder category(final Category category) {
^
Expected behavior:
No warnings.
Version info (please complete the following information):
Lombok since 1.18.6v
java 11
gradle 6.0.1
The text was updated successfully, but these errors were encountered:
I have the same issue: "...warning: no @param for..." for the current last available lombok version.
Looks like @rzwitserloot 's commit 0b0656a only fixes issue related to @return
Description:
When using lombok and add javadoc on field inside a class, warnings are thrown when generating javadoc, which depends on delombok task.
To Reproduce:
Create a class with Value and Builder lombok annotation. Add javadoc on fields inside it and override some builder methods. For example,
Then run ./gradlew javadoc.
Actual behaviour:
if add java docs @param and @return to java docs on
category
field, only one warning will bet thrown:Expected behavior:
No warnings.
Version info (please complete the following information):
The text was updated successfully, but these errors were encountered: