Package org.localify.user.dto
Record Class UserHistoryResponse.HistoryEventResponse
java.lang.Object
java.lang.Record
org.localify.user.dto.UserHistoryResponse.HistoryEventResponse
- Record Components:
id- The event's ID.name- The event's name.startTime- The event's start time.endTime- The event's end time.applePlaylistId- The ID of the event's Apple Music playlist.spotifyPlaylistId- The ID of the event's Spotify playlist.venue- The event's venue.
- Enclosing class:
- UserHistoryResponse
public static record UserHistoryResponse.HistoryEventResponse(UUID id, String name, String startTime, Instant endTime, String applePlaylistId, String spotifyPlaylistId, VenueResponse venue)
extends Record
Represents a recently viewed event.
-
Constructor Summary
ConstructorsConstructorDescriptionHistoryEventResponse(UUID id, String name, String startTime, Instant endTime, String applePlaylistId, String spotifyPlaylistId, VenueResponse venue) Creates an instance of aHistoryEventResponserecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of theapplePlaylistIdrecord component.endTime()Returns the value of theendTimerecord 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 thespotifyPlaylistIdrecord component.Returns the value of thestartTimerecord component.final StringtoString()Returns a string representation of this record class.venue()Returns the value of thevenuerecord component.
-
Constructor Details
-
HistoryEventResponse
public HistoryEventResponse(UUID id, String name, String startTime, Instant endTime, @Nullable String applePlaylistId, @Nullable String spotifyPlaylistId, @Nullable VenueResponse venue) Creates an instance of aHistoryEventResponserecord class.- Parameters:
id- the value for theidrecord componentname- the value for thenamerecord componentstartTime- the value for thestartTimerecord componentendTime- the value for theendTimerecord componentapplePlaylistId- the value for theapplePlaylistIdrecord componentspotifyPlaylistId- the value for thespotifyPlaylistIdrecord componentvenue- the value for thevenuerecord 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
-
startTime
Returns the value of thestartTimerecord component.- Returns:
- the value of the
startTimerecord component
-
endTime
Returns the value of theendTimerecord component.- Returns:
- the value of the
endTimerecord component
-
applePlaylistId
Returns the value of theapplePlaylistIdrecord component.- Returns:
- the value of the
applePlaylistIdrecord component
-
spotifyPlaylistId
Returns the value of thespotifyPlaylistIdrecord component.- Returns:
- the value of the
spotifyPlaylistIdrecord component
-
venue
Returns the value of thevenuerecord component.- Returns:
- the value of the
venuerecord component
-