-
-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Copy Javadoc to @Builder setters #2008
Conversation
Looks good! |
Thanks! 😄 |
this is now available in edge release: https://projectlombok.org/download-edge |
@rzwitserloot thanks for this! I've just given it a try and noticed that it's not elevating the Javadoc if
Any way around this? |
In fact, it doesn't seem to work at all, regardless of how I use Class with:
Produces the builder method:
With delombok plugin:
|
I don't know if this is related, but I don't get Javadoc either. Using Lombok 1.18.12 in Eclipse 2020-03, none of the following classes generates Javadoc on the
|
Re-implementation of #2004 on top of the fixes made in ccfab5e. Fixes #1033. Fixes #1445.
Forum discussion: https://groups.google.com/forum/#!topic/project-lombok/aZx5wJp891k
This still makes no attempt to include
@Singular
versions of builder methods, because that requires some nontrivial decision making. Had the plural version been equivalent to the standard non-@Singular
version, it would be simple enough to copy the docstring to the plural method and auto-generate docstrings for the singular and clearer referencing that of the plural. Unfortunately, the plural version is subtly but importantly different - it doesn't replace the collection but instead adds elements to it - so it's probably not a good idea to just drop a standard setter docstring on it.An alternative approach to extending this to
@Singular
methods would be to add a couple of new docstring section types:SINGULAR
,PLURAL
,CLEAR
for example, and not generate a docstring if the corresponding section doesn't exist.Anyway, extending this to
@Singular
versions can just as well be done in a separate PR.