Skip to content
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

Support for @JsonDeserialize(builder=..) #527

Merged
merged 8 commits into from
Aug 4, 2023
Merged

Support for @JsonDeserialize(builder=..) #527

merged 8 commits into from
Aug 4, 2023

Conversation

graemerocher
Copy link
Contributor

@graemerocher graemerocher commented Jul 21, 2023

Draft PR for builder support, some open questions:

  • Don't know how to support pre-instantiation hook
  • Unsure about strict nullable

build.gradle.kts Outdated Show resolved Hide resolved
@yawkat
Copy link
Member

yawkat commented Jul 24, 2023

what exactly are the pre-instantiate hooks used for (theyre used in data right)?

i think builders should have the same behavior as creator methods wrt pre-instantiate hooks. i think atm the hook is called after the creator but before any more properties are set.

@graemerocher
Copy link
Contributor Author

I am not sure about these pre-instantiate hooks myself, @dstepanov will have to confirm

@dstepanov
Copy link
Contributor

The hook is used to perform possible validation before the constructor is invoked. In this case, we need to think about how we would trigger the builder method validation.

@graemerocher graemerocher marked this pull request as ready for review August 3, 2023 17:30
@graemerocher graemerocher added the type: enhancement New feature or request label Aug 3, 2023
@sonarcloud
Copy link

sonarcloud bot commented Aug 3, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 3 Code Smells

54.9% 54.9% Coverage
4.9% 4.9% Duplication

idea Catch issues before they fail your Quality Gate with our IDE extension sonarlint SonarLint

@graemerocher graemerocher merged commit b724d0a into master Aug 4, 2023
6 of 7 checks passed
@graemerocher graemerocher deleted the builders branch August 4, 2023 06:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants