Class Chart<T extends MusicEntry>


  • public class Chart<T extends MusicEntry>
    extends java.lang.Object
    Bean for Chart information. Contains a start date, an end date and a list of entries.
    Author:
    Janni Kovacs
    • Constructor Detail

      • Chart

        public Chart​(java.util.Date from,
                     java.util.Date to,
                     java.util.Collection<T> entries)
    • Method Detail

      • getEntries

        public java.util.Collection<T> getEntries()
      • getFrom

        public java.util.Date getFrom()
      • getTo

        public java.util.Date getTo()
      • getTopArtists

        public static PaginatedResult<Artist> getTopArtists​(java.lang.String apiKey)
        Get the top artists chart.
        Parameters:
        apiKey - A Last.fm API key
        Returns:
        Top artists chart
      • getTopArtists

        public static PaginatedResult<Artist> getTopArtists​(int page,
                                                            java.lang.String apiKey)
        Get the top artists chart.
        Parameters:
        page - The page to fetch
        apiKey - A Last.fm API key
        Returns:
        Top artists chart
      • getTopTags

        public static PaginatedResult<Tag> getTopTags​(java.lang.String apiKey)
        Get the top tags chart.
        Parameters:
        apiKey - A Last.fm API key
        Returns:
        Top tags chart
      • getTopTags

        public static PaginatedResult<Tag> getTopTags​(int page,
                                                      java.lang.String apiKey)
        Get the top tags chart.
        Parameters:
        page - The page to fetch
        apiKey - A Last.fm API key
        Returns:
        Top tags chart
      • getTopTracks

        public static PaginatedResult<Track> getTopTracks​(java.lang.String apiKey)
        Get the top tracks chart.
        Parameters:
        apiKey - A Last.fm API key
        Returns:
        Top tracks chart
      • getTopTracks

        public static PaginatedResult<Track> getTopTracks​(int page,
                                                          java.lang.String apiKey)
        Get the top tracks chart.
        Parameters:
        page - The page to fetch
        apiKey - A Last.fm API key
        Returns:
        Top tracks chart
      • getLovedTracks

        public static PaginatedResult<Track> getLovedTracks​(java.lang.String apiKey)
        Get the most loved tracks chart.
        Parameters:
        apiKey - A Last.fm API key
        Returns:
        Most loved tracks chart
      • getLovedTracks

        public static PaginatedResult<Track> getLovedTracks​(int page,
                                                            java.lang.String apiKey)
        Get the most loved tracks chart.
        Parameters:
        page - The page to fetch
        apiKey - A Last.fm API key
        Returns:
        Most loved tracks chart
      • getHypedTracks

        public static PaginatedResult<Track> getHypedTracks​(java.lang.String apiKey)
        Get the hyped tracks chart.
        Parameters:
        apiKey - A Last.fm API key
        Returns:
        Hyped tracks chart
      • getHypedTracks

        public static PaginatedResult<Track> getHypedTracks​(int page,
                                                            java.lang.String apiKey)
        Get the hyped tracks chart.
        Parameters:
        page - The page to fetch
        apiKey - A Last.fm API key
        Returns:
        Hyped tracks chart
      • getHypedArtists

        public static PaginatedResult<Artist> getHypedArtists​(java.lang.String apiKey)
        Get the hyped artists chart.
        Parameters:
        apiKey - A Last.fm API key
        Returns:
        Hyped artists chart
      • getHypedArtists

        public static PaginatedResult<Artist> getHypedArtists​(int page,
                                                              java.lang.String apiKey)
        Get the hyped artists chart.
        Parameters:
        page - The page to fetch
        apiKey - A Last.fm API key
        Returns:
        Hyped artists chart