Skip to content

fix: disable generateUpdateHelpers in the ElementaryBuilder template - #334

Merged
AndreasIgel merged 1 commit into
java-helpers:mainfrom
igel-devin-ai:devin/1791181717-elementary-update-helpers
Oct 5, 2026
Merged

AndreasIgel merged 1 commit into
java-helpers:mainfrom
igel-devin-ai:devin/1791181717-elementary-update-helpers

Conversation

@igel-devin-ai

@igel-devin-ai igel-devin-ai commented Oct 5, 2026 •

Copy link
Copy Markdown
Collaborator

Summary

Fixes #333 — follow-up to #31 (the update-helpers feature, implemented in #223, postdates this template).

@ElementaryBuilder — the example's minimal template, documented on BookDto as generating a setter-only builder — predates the generateUpdateHelpers option and never disabled it. @ElementaryBuilder-annotated types therefore still got xyzUpdate(UnaryOperator<T>) methods (visible in the committed BookDtoBuilder: authorUpdate, pagesUpdate, …).

Adds generateUpdateHelpers = OptionState.DISABLED to the template (matching the built-in @SimpleMinimalBuilder) and regenerates the committed example builders — BookDtoBuilder is now setter-only as documented.

Verification

mvn -pl example clean compile regenerates BookDtoBuilder without the update methods and the UnaryOperator import; no other generated builder is touched.

Written by Devin

@ElementaryBuilder predates the update-helpers option and documented a
setter-only builder, but never disabled generateUpdateHelpers — so
@ElementaryBuilder-annotated types got xyzUpdate(UnaryOperator<T>)
methods anyway (visible in the committed BookDtoBuilder). Align it
with @SimpleMinimalBuilder.

Fixes java-helpers#333
@sonarqubecloud

sonarqubecloud Bot commented Oct 5, 2026

Copy link
Copy Markdown

@AndreasIgel
AndreasIgel merged commit 1690051 into java-helpers:main Oct 5, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ElementaryBuilder template misses generateUpdateHelpers=DISABLED — update helpers leak into the setter-only builder

2 participants