record 클래스에 대해 설명해주세요. #102
gyungchan-jo
started this conversation in
Java
Replies: 2 comments
-
|
record 클래스는 Java 14부터 도입된 불변 데이터를 표현하기 위한 간단한 버전의 클래스입니다. 필드는 final로 선언되어 값을 변경할 수 없고, equals(), hashCode(), toString(), getter()가 자동으로 생성됩니다. 주로 DTO나 불변성이 필요한 경우에 사용합니다. |
Beta Was this translation helpful? Give feedback.
0 replies
-
|
record는 불변 데이터를 간단하게 표현하기 위한 새로운 형태의 클래스입니다. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
.
Beta Was this translation helpful? Give feedback.
All reactions