Record Class BasicInformation
java.lang.Object
java.lang.Record
io.github.seenings.info.model.BasicInformation
- Record Components:
aliasName- 别名birthDate- 出生年月日sex- 性别stature- 身高weight- 体重currentResidence- 现居地birthPlace- 出生地maritalStatus- 婚姻状况
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thealiasNamerecord component.Returns the value of thebirthDaterecord component.Returns the value of thebirthPlacerecord component.Returns the value of thecurrentResidencerecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.Returns the value of themaritalStatusrecord component.sex()Returns the value of thesexrecord component.stature()Returns the value of thestaturerecord component.final StringtoString()Returns a string representation of this record class.weight()Returns the value of theweightrecord component.
-
Constructor Details
-
BasicInformation
public BasicInformation(String aliasName, LocalDate birthDate, Integer sex, Integer stature, Integer weight, List<String> currentResidence, List<String> birthPlace, Integer maritalStatus) Creates an instance of aBasicInformationrecord class.- Parameters:
aliasName- the value for thealiasNamerecord componentbirthDate- the value for thebirthDaterecord componentsex- the value for thesexrecord componentstature- the value for thestaturerecord componentweight- the value for theweightrecord componentcurrentResidence- the value for thecurrentResidencerecord componentbirthPlace- the value for thebirthPlacerecord componentmaritalStatus- the value for themaritalStatusrecord component
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object). -
aliasName
-
birthDate
-
sex
-
stature
-
weight
-
currentResidence
Returns the value of thecurrentResidencerecord component.- Returns:
- the value of the
currentResidencerecord component
-
birthPlace
Returns the value of thebirthPlacerecord component.- Returns:
- the value of the
birthPlacerecord component
-
maritalStatus
Returns the value of themaritalStatusrecord component.- Returns:
- the value of the
maritalStatusrecord component
-