Record Class ArtistResponse
java.lang.Object
java.lang.Record
org.localify.data.ingest.response.ArtistResponse
- Record Components:
dataSource- The data source of the response.id- The ID of the artist in the data source.localifyId- The Localify ID of the artist.musicServiceIds- A map of music service data sources to their corresponding IDs for the artist.originExplanation- The explanation for the artist's origin (e.g., "Hometown", "Born").origin- A string describing the artist's origin city or location.genres- A list of genres associated with the artist.upcomingEventIds- A list of IDs for the artist's upcoming events.previousEventIds- A list of IDs for the artist's previous events.
- All Implemented Interfaces:
Serializable
public record ArtistResponse(DataSource dataSource, String id, UUID localifyId, @NotNull Map<DataSource,String> musicServiceIds, ArtistCityExplanation originExplanation, String origin, @NotNull List<String> genres, @NotNull List<String> upcomingEventIds, @NotNull List<String> previousEventIds)
extends Record
implements Serializable
Represents an artist response from a scraper.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionArtistResponse(DataSource dataSource, String id, UUID localifyId, @NotNull Map<DataSource, String> musicServiceIds, ArtistCityExplanation originExplanation, String origin, @NotNull List<String> genres, @NotNull List<String> upcomingEventIds, @NotNull List<String> previousEventIds) Creates an instance of aArtistResponserecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thedataSourcerecord component.final booleanIndicates whether some other object is "equal to" this one.genres()Returns the value of thegenresrecord component.final inthashCode()Returns a hash code value for this object.id()Returns the value of theidrecord component.Returns the value of thelocalifyIdrecord component.@NotNull Map<DataSource,String> Returns the value of themusicServiceIdsrecord component.origin()Returns the value of theoriginrecord component.Returns the value of theoriginExplanationrecord component.Returns the value of thepreviousEventIdsrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of theupcomingEventIdsrecord component.
-
Constructor Details
-
ArtistResponse
public ArtistResponse(DataSource dataSource, String id, UUID localifyId, @NotNull @NotNull Map<DataSource, String> musicServiceIds, ArtistCityExplanation originExplanation, String origin, @NotNull @NotNull List<String> genres, @NotNull @NotNull List<String> upcomingEventIds, @NotNull @NotNull List<String> previousEventIds) Creates an instance of aArtistResponserecord class.- Parameters:
dataSource- the value for thedataSourcerecord componentid- the value for theidrecord componentlocalifyId- the value for thelocalifyIdrecord componentmusicServiceIds- the value for themusicServiceIdsrecord componentoriginExplanation- the value for theoriginExplanationrecord componentorigin- the value for theoriginrecord componentgenres- the value for thegenresrecord componentupcomingEventIds- the value for theupcomingEventIdsrecord componentpreviousEventIds- the value for thepreviousEventIdsrecord 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). -
dataSource
Returns the value of thedataSourcerecord component.- Returns:
- the value of the
dataSourcerecord component
-
id
Returns the value of theidrecord component.- Returns:
- the value of the
idrecord component
-
localifyId
Returns the value of thelocalifyIdrecord component.- Returns:
- the value of the
localifyIdrecord component
-
musicServiceIds
Returns the value of themusicServiceIdsrecord component.- Returns:
- the value of the
musicServiceIdsrecord component
-
originExplanation
Returns the value of theoriginExplanationrecord component.- Returns:
- the value of the
originExplanationrecord component
-
origin
Returns the value of theoriginrecord component.- Returns:
- the value of the
originrecord component
-
genres
Returns the value of thegenresrecord component.- Returns:
- the value of the
genresrecord component
-
upcomingEventIds
Returns the value of theupcomingEventIdsrecord component.- Returns:
- the value of the
upcomingEventIdsrecord component
-
previousEventIds
Returns the value of thepreviousEventIdsrecord component.- Returns:
- the value of the
previousEventIdsrecord component
-