Class ArtistSong

java.lang.Object
org.localify.artist.join.ArtistSong

@Entity public class ArtistSong extends Object
Represents the join table between artists and songs.
  • Constructor Details

    • ArtistSong

      public ArtistSong()
      Default constructor for JPA.
    • ArtistSong

      public ArtistSong(Artist artist, Song song)
      Constructs a new ArtistSong with the given artist and song.
      Parameters:
      artist - The artist.
      song - The song.
  • Method Details

    • getArtist

      public Artist getArtist()
      Gets the artist.
      Returns:
      The artist.
    • getSong

      public Song getSong()
      Gets the song.
      Returns:
      The song.
    • getCreatedAt

      public Instant getCreatedAt()
      Gets the creation timestamp.
      Returns:
      The creation timestamp.
    • getKey

      public ArtistSong.Key getKey()
      Gets the composite primary key.
      Returns:
      The composite primary key.
    • setArtist

      public ArtistSong setArtist(Artist artist)
      Sets the artist.
      Parameters:
      artist - The artist.
      Returns:
      This ArtistSong instance.
    • setSong

      public ArtistSong setSong(Song song)
      Sets the song.
      Parameters:
      song - The song.
      Returns:
      This ArtistSong instance.