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 - 婚姻状况

public record BasicInformation(String aliasName, LocalDate birthDate, Integer sex, Integer stature, Integer weight, List<String> currentResidence, List<String> birthPlace, Integer maritalStatus) extends Record
BasicInformation
Since:
2023-02-11
Author:
chixuehui
  • 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 a BasicInformation record class.
      Parameters:
      aliasName - the value for the aliasName record component
      birthDate - the value for the birthDate record component
      sex - the value for the sex record component
      stature - the value for the stature record component
      weight - the value for the weight record component
      currentResidence - the value for the currentResidence record component
      birthPlace - the value for the birthPlace record component
      maritalStatus - the value for the maritalStatus record component
  • Method Details

    • toString

      public final String toString()
      Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components.
      Specified by:
      toString in class Record
      Returns:
      a string representation of this object
    • hashCode

      public final int hashCode()
      Returns a hash code value for this object. The value is derived from the hash code of each of the record components.
      Specified by:
      hashCode in class Record
      Returns:
      a hash code value for this object
    • equals

      public final boolean equals(Object o)
      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 with Objects::equals(Object,Object).
      Specified by:
      equals in class Record
      Parameters:
      o - the object with which to compare
      Returns:
      true if this object is the same as the o argument; false otherwise.
    • aliasName

      public String aliasName()
      Returns the value of the aliasName record component.
      Returns:
      the value of the aliasName record component
    • birthDate

      public LocalDate birthDate()
      Returns the value of the birthDate record component.
      Returns:
      the value of the birthDate record component
    • sex

      public Integer sex()
      Returns the value of the sex record component.
      Returns:
      the value of the sex record component
    • stature

      public Integer stature()
      Returns the value of the stature record component.
      Returns:
      the value of the stature record component
    • weight

      public Integer weight()
      Returns the value of the weight record component.
      Returns:
      the value of the weight record component
    • currentResidence

      public List<String> currentResidence()
      Returns the value of the currentResidence record component.
      Returns:
      the value of the currentResidence record component
    • birthPlace

      public List<String> birthPlace()
      Returns the value of the birthPlace record component.
      Returns:
      the value of the birthPlace record component
    • maritalStatus

      public Integer maritalStatus()
      Returns the value of the maritalStatus record component.
      Returns:
      the value of the maritalStatus record component