-
-
Notifications
You must be signed in to change notification settings - Fork 92
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
BE: Chore: use record classes #703
base: main
Are you sure you want to change the base?
Conversation
c083660
to
fc1e8cc
Compare
d4e3423
to
c1870b6
Compare
c1870b6
to
0e85faa
Compare
@Haarolean What is blocking the merge of this change? Thanks in advance! |
public SchemaDescription(String schema, Map<String, Object> additionalProperties) { | ||
this.schema = schema; | ||
this.additionalProperties = additionalProperties; | ||
public SchemaDescription { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need a default constructor here?..
*/ | ||
public final class DeserializeResult { | ||
public record DeserializeResult(String result, io.kafbat.ui.serde.api.DeserializeResult.Type type, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
io.kafbat.ui.serde.api.DeserializeResult.Type
- can we import this?
String result
- @nullable
won't hurt I guess considering the comment we had on line 16
@@ -67,11 +68,6 @@ public boolean equals(Object o) { | |||
&& additionalProperties.equals(that.additionalProperties); | |||
} | |||
|
|||
@Override | |||
public int hashCode() { | |||
return Objects.hash(result, type, additionalProperties); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why?
What changes did you make? (Give an overview)
Refactors the code to take advantage of records
Is there anything you'd like reviewers to focus on?
How Has This Been Tested? (put an "x" (case-sensitive!) next to an item)
Checklist (put an "x" (case-sensitive!) next to all the items, otherwise the build will fail)
A picture of a cute animal (not mandatory but encouraged)