Record Class OrganizerDTO
java.lang.Object
java.lang.Record
com.endurancetrio.business.event.dto.OrganizerDTO
- Record Components:
id- the unique identifier of the organizername- the name of the organizerorganizerType- the type of the organizer (e.g. CLUB, PRIVATE, PUBLIC)city- the city of the organizer's headquarterscounty- the county of the organizer's headquartersdistrict- the district of the organizer's headquarters
public record OrganizerDTO(Long id, String name, String organizerType, String city, String county, String district)
extends Record
The
OrganizerDTO represents an organizer of an event.-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncity()Returns the value of thecityrecord component.county()Returns the value of thecountyrecord component.district()Returns the value of thedistrictrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.name()Returns the value of thenamerecord component.Returns the value of theorganizerTyperecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
OrganizerDTO
public OrganizerDTO(Long id, String name, String organizerType, String city, String county, String district) Creates an instance of aOrganizerDTOrecord class.- Parameters:
id- the value for theidrecord componentname- the value for thenamerecord componentorganizerType- the value for theorganizerTyperecord componentcity- the value for thecityrecord componentcounty- the value for thecountyrecord componentdistrict- the value for thedistrictrecord component
-
-
Method Details
-
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. -
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. -
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). -
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
name
Returns the value of thenamerecord component.- Returns:
- the value of the
namerecord component
-
organizerType
Returns the value of theorganizerTyperecord component.- Returns:
- the value of the
organizerTyperecord component
-
city
Returns the value of thecityrecord component.- Returns:
- the value of the
cityrecord component
-
county
Returns the value of thecountyrecord component.- Returns:
- the value of the
countyrecord component
-
district
Returns the value of thedistrictrecord component.- Returns:
- the value of the
districtrecord component
-