Package org.localify.dto
Class RecommendedEventDto
java.lang.Object
org.localify.dto.RecommendedEventDto
Data Transfer Object for a recommended event.
Switched to a normal class to be able to implement #equals and use #distinct on streams.
-
Constructor Summary
ConstructorsConstructorDescriptionRecommendedEventDto(UUID id, String name, Double percentMatch, Instant startTime, VenueResponse venue, List<BasicArtistLocalResponse> artists, List<GenreResponse> genres, boolean isFavorite, boolean hasLocalArtistPerforming, String ticketUrl, List<RecommendedArtistDto.SimilarArtistDto> similar, Instant createdAt) Constructs a new RecommendedEventDto. -
Method Summary
Modifier and TypeMethodDescriptionbooleanGets the list of artists performing at the event.Gets the creation timestamp of the recommendation.Gets the list of genres associated with the event.getId()Gets the ID of the event.getName()Gets the name of the event.Gets the match percentage.Gets the list of similar artists.Gets the start time of the event.Gets the ticket URL for the event.getVenue()Gets the venue of the event.inthashCode()booleanChecks if the event is a favorite of the user.booleanChecks if a local artist is performing at the event.voidsetArtists(List<BasicArtistLocalResponse> artists) Sets the list of artists performing at the event.voidsetCreatedAt(Instant createdAt) Sets the creation timestamp of the recommendation.voidsetFavorite(boolean isFavorite) Sets whether the event is a favorite of the user.voidsetGenres(List<GenreResponse> genres) Sets the list of genres associated with the event.voidsetHasLocalArtistPerforming(boolean hasLocalArtistPerforming) Sets whether a local artist is performing at the event.voidSets the ID of the event.voidSets the name of the event.voidsetPercentMatch(Double percentMatch) Sets the match percentage.voidSets the list of similar artists.voidsetStartTime(Instant startTime) Sets the start time of the event.voidsetTicketUrl(String ticketUrl) Sets the ticket URL for the event.voidsetVenue(VenueResponse venue) Sets the venue of the event.
-
Constructor Details
-
RecommendedEventDto
public RecommendedEventDto(UUID id, String name, Double percentMatch, Instant startTime, VenueResponse venue, List<BasicArtistLocalResponse> artists, List<GenreResponse> genres, boolean isFavorite, boolean hasLocalArtistPerforming, String ticketUrl, List<RecommendedArtistDto.SimilarArtistDto> similar, Instant createdAt) Constructs a new RecommendedEventDto.- Parameters:
id- The ID of the event.name- The name of the event.percentMatch- The match percentage for the recommendation.startTime- The start time of the event.venue- The venue of the event.artists- The artists performing at the event.genres- The genres associated with the event.isFavorite- Whether the event is a favorite of the user.hasLocalArtistPerforming- Whether a local artist is performing at the event.ticketUrl- The URL to purchase tickets.similar- A list of similar artists.createdAt- The creation timestamp of the recommendation.
-
-
Method Details
-
getId
Gets the ID of the event.- Returns:
- The event ID.
-
setId
Sets the ID of the event.- Parameters:
id- The event ID.
-
getName
Gets the name of the event.- Returns:
- The event name.
-
setName
Sets the name of the event.- Parameters:
name- The event name.
-
getPercentMatch
Gets the match percentage.- Returns:
- The match percentage.
-
setPercentMatch
Sets the match percentage.- Parameters:
percentMatch- The match percentage.
-
getStartTime
Gets the start time of the event.- Returns:
- The start time.
-
setStartTime
Sets the start time of the event.- Parameters:
startTime- The start time.
-
getVenue
Gets the venue of the event.- Returns:
- The venue.
-
setVenue
Sets the venue of the event.- Parameters:
venue- The venue.
-
getArtists
Gets the list of artists performing at the event.- Returns:
- The list of artists.
-
setArtists
Sets the list of artists performing at the event.- Parameters:
artists- The list of artists.
-
getGenres
Gets the list of genres associated with the event.- Returns:
- The list of genres.
-
setGenres
Sets the list of genres associated with the event.- Parameters:
genres- The list of genres.
-
isFavorite
public boolean isFavorite()Checks if the event is a favorite of the user.- Returns:
- true if the event is a favorite, false otherwise.
-
setFavorite
public void setFavorite(boolean isFavorite) Sets whether the event is a favorite of the user.- Parameters:
isFavorite- true if the event is a favorite, false otherwise.
-
isHasLocalArtistPerforming
public boolean isHasLocalArtistPerforming()Checks if a local artist is performing at the event.- Returns:
- true if a local artist is performing, false otherwise.
-
setHasLocalArtistPerforming
public void setHasLocalArtistPerforming(boolean hasLocalArtistPerforming) Sets whether a local artist is performing at the event.- Parameters:
hasLocalArtistPerforming- true if a local artist is performing, false otherwise.
-
getTicketUrl
Gets the ticket URL for the event.- Returns:
- The ticket URL.
-
setTicketUrl
Sets the ticket URL for the event.- Parameters:
ticketUrl- The ticket URL.
-
getSimilar
Gets the list of similar artists.- Returns:
- The list of similar artists.
-
setSimilar
Sets the list of similar artists.- Parameters:
similar- The list of similar artists.
-
getCreatedAt
Gets the creation timestamp of the recommendation.- Returns:
- The creation timestamp.
-
setCreatedAt
Sets the creation timestamp of the recommendation.- Parameters:
createdAt- The creation timestamp.
-
equals
-
hashCode
public int hashCode()
-