All Implemented Interfaces:
Serializable

@Entity(name="Athlete") public class Athlete extends BaseEntity<Long>
The Athlete entity represents an individual competitor in the system.

The Athlete's fields are defined as follows:

  • id : the unique identifier of the Athlete that is automatically generated and is the primary key.
  • longName : the athlete's longest available name, which may not be the full name for historical records.
  • birthName : the athlete's name at birth, if different from the current name. Used to identify athletes who changed names (e.g., after marriage).
  • knownName : the athlete's known or preferred name.
  • gender : the AthleteGender of the athlete.
  • country : the athlete's Country of representation.
  • yearOfBirth : the athlete's year of birth.
See Also:
  • Constructor Details

    • Athlete

      public Athlete()
  • Method Details

    • getLongName

      public String getLongName()
    • setLongName

      public void setLongName(String longName)
    • getBirthName

      public String getBirthName()
    • setBirthName

      public void setBirthName(String birthName)
    • getKnownName

      public String getKnownName()
    • setKnownName

      public void setKnownName(String knownName)
    • getGender

      public AthleteGender getGender()
    • setGender

      public void setGender(AthleteGender gender)
    • getCountry

      public Country getCountry()
    • setCountry

      public void setCountry(Country country)
    • getYearOfBirth

      public Integer getYearOfBirth()
    • setYearOfBirth

      public void setYearOfBirth(Integer yearOfBirth)
    • equals

      public boolean equals(Object o)
      Description copied from class: BaseEntity
      Equality is based on the entity's identifier. Two entities are considered equal if they are of the same class and have the same non-null identifier.

      If the ID is null, we treat it as a transient (new) object. Transient objects are only equal if they are the exact same instance.

      Overrides:
      equals in class BaseEntity<Long>
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class BaseEntity<Long>
    • toString

      public String toString()
      Overrides:
      toString in class Object