## net.dontdrinkandroot.lastfm.api.model
Class Album

    java.lang.Object
      net.dontdrinkandroot.lastfm.api.model.LfmEntity
          net.dontdrinkandroot.lastfm.api.model.Album

All Implemented Interfaces:
  java.io.Serializable, ArtistEntity, Entity, IdEntity, ImageEntity, ListenersEntity, MbidEntity, MusicBrainzEntity, NameEntity, PlayCountEntity, RankEntity, ReleaseDateEntity, StreamableEntity, TagsEntity, TracksEntity, UrlEntity, UserPlayCountEntity, WikiEntity

    public class Album

extends LfmEntity
implements ImageEntity, MusicBrainzEntity, NameEntity, UrlEntity, PlayCountEntity, IdEntity, UserPlayCountEntity, ArtistEntity, ReleaseDateEntity, WikiEntity, TagsEntity, TracksEntity, StreamableEntity

See Also:
  Serialized Form

Field Summary
`static java.util.Map<ImageSize,java.net.URL>` `DEFAULT_IMAGES`

Constructor Summary
`Album(org.w3c.dom.Element albumElement)` Create an Album from a dom4j Element.

Method Summary
`static PostQuery<java.lang.Boolean>` `addTags(java.lang.String artist, java.lang.String album, java.util.List<java.lang.String> tags, java.lang.String sk)` Tag an album using a list of user supplied tags.
`boolean` `equals(java.lang.Object obj)`
`Artist` `getArtist()`
`static UnauthenticatedGetQuery<Affiliations>` `getBuylinks(java.lang.String artist, java.lang.String album, java.lang.String mbid, net.dontdrinkandroot.utils.ISO_3166_1_alpha2 country)` Get a list of Buy Links for a particular Album.
`java.lang.Long` `getId()`
`java.util.Map<ImageSize,java.net.URL>` `getImages()`
`static UnauthenticatedGetQuery<Album>` `getInfo(java.lang.String artist, java.lang.String album, java.lang.String mbid, java.lang.String username, net.dontdrinkandroot.utils.ISO_3166_1_alpha2 lang)` Get the metadata for an album on Last.fm using the album name or a musicbrainz id.
`java.lang.Integer` `getListeners()`
`java.lang.String` `getMbid()`
`java.lang.String` `getName()`
`java.lang.Integer` `getPlayCount()`
`java.lang.Integer` `getRank()`
`java.util.Date` `getReleaseDate()`
`static UnauthenticatedGetQuery<PaginatedResult<java.util.List<Shout>>>` `getShouts(java.lang.String artist, java.lang.String album, java.lang.String mbid, java.lang.Integer limit, java.lang.Integer page)` Get shouts for this album.
`Streamable` `getStreamable()`
`java.util.List<Tag>` `getTags()`
`static UnauthenticatedGetQuery<java.util.ArrayList<Tag>>` `getTags(java.lang.String artist, java.lang.String album, java.lang.String mbid, java.lang.String user)` Get the tags applied by an individual user to an album on Last.fm.
`static UnauthenticatedGetQuery<java.util.ArrayList<Tag>>` `getTopTags(java.lang.String artist, java.lang.String album, java.lang.String mbid)` Get the top tags for an album on Last.fm, ordered by popularity.
`java.util.List<Track>` `getTracks()`
`java.net.URL` `getUrl()`
`java.lang.Integer` `getUserPlayCount()`
`Wiki` `getWiki()`
`int` `hashCode()`
`static PostQuery<java.lang.Boolean>` `removeTag(java.lang.String artist, java.lang.String album, java.lang.String tag, java.lang.String sk)` Remove a user's tag from an album.
`static UnauthenticatedGetQuery<PaginatedResult<java.util.List<Album>>>` `search(java.lang.String album, java.lang.Integer limit, java.lang.Integer page)` Search for an album by name.
`void` `setArtist(Artist artist)`
`void` `setId(java.lang.Long id)`
`void` `setImages(java.util.Map<ImageSize,java.net.URL> images)`
`void` `setListeners(java.lang.Integer listeners)`
`void` `setMbid(java.lang.String mbid)`
`void` `setName(java.lang.String name)`
`void` `setPlayCount(java.lang.Integer playCount)`
`void` `setRank(java.lang.Integer rank)`
`void` `setReleaseDate(java.util.Date releaseDate)`
`void` `setStreamable(Streamable streamable)`
`void` `setTags(java.util.List<Tag> tags)`
`void` `setTracks(java.util.List<Track> tracks)`
`void` `setUrl(java.net.URL url)`
`void` `setUserPlayCount(java.lang.Integer userPlayCount)`
`void` `setWiki(Wiki wiki)`
`static PostQuery<java.lang.Boolean>` `share(java.lang.String artist, java.lang.String album, java.util.List<java.lang.String> recipient, java.lang.Boolean publicViewable, java.lang.String message, java.lang.String sk)` Share an album with one or more Last.fm users or other friends.

Methods inherited from class java.lang.Object
`clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### DEFAULT_IMAGES

    public static final transient java.util.Map<ImageSize,java.net.URL> DEFAULT_IMAGES

Constructor Detail

### Album

    public Album(org.w3c.dom.Element albumElement)

  Create an Album from a dom4j Element.

  Parameters:
    `albumElement` - The Element to convert.

Method Detail

### getName

    public final java.lang.String getName()

  Specified by:
    `getName` in interface `NameEntity`

### setName

    public final void setName(java.lang.String name)

  Specified by:
    `setName` in interface `NameEntity`

### getArtist

    public final Artist getArtist()

  Specified by:
    `getArtist` in interface `ArtistEntity`

### setArtist

    public final void setArtist(Artist artist)

  Specified by:
    `setArtist` in interface `ArtistEntity`

### getId

    public final java.lang.Long getId()

  Specified by:
    `getId` in interface `IdEntity`

### setId

    public final void setId(java.lang.Long id)

  Specified by:
    `setId` in interface `IdEntity`

### getMbid

    public final java.lang.String getMbid()

  Specified by:
    `getMbid` in interface `MbidEntity`

### setMbid

    public final void setMbid(java.lang.String mbid)

  Specified by:
    `setMbid` in interface `MbidEntity`

### getUrl

    public final java.net.URL getUrl()

  Specified by:
    `getUrl` in interface `UrlEntity`

### setUrl

    public final void setUrl(java.net.URL url)

  Specified by:
    `setUrl` in interface `UrlEntity`

### getReleaseDate

    public final java.util.Date getReleaseDate()

  Specified by:
    `getReleaseDate` in interface `ReleaseDateEntity`

### setReleaseDate

    public final void setReleaseDate(java.util.Date releaseDate)

  Specified by:
    `setReleaseDate` in interface `ReleaseDateEntity`

### getImages

    public final java.util.Map<ImageSize,java.net.URL> getImages()

  Specified by:
    `getImages` in interface `ImageEntity`

### setImages

    public final void setImages(java.util.Map<ImageSize,java.net.URL> images)

  Specified by:
    `setImages` in interface `ImageEntity`

### getUserPlayCount

    public final java.lang.Integer getUserPlayCount()

  Specified by:
    `getUserPlayCount` in interface `UserPlayCountEntity`

### setUserPlayCount

    public final void setUserPlayCount(java.lang.Integer userPlayCount)

  Specified by:
    `setUserPlayCount` in interface `UserPlayCountEntity`

### getListeners

    public final java.lang.Integer getListeners()

  Specified by:
    `getListeners` in interface `ListenersEntity`

### setListeners

    public final void setListeners(java.lang.Integer listeners)

  Specified by:
    `setListeners` in interface `ListenersEntity`

### getPlayCount

    public final java.lang.Integer getPlayCount()

  Specified by:
    `getPlayCount` in interface `PlayCountEntity`

### setPlayCount

    public final void setPlayCount(java.lang.Integer playCount)

  Specified by:
    `setPlayCount` in interface `PlayCountEntity`

### getTracks

    public final java.util.List<Track> getTracks()

  Specified by:
    `getTracks` in interface `TracksEntity`

### setTracks

    public final void setTracks(java.util.List<Track> tracks)

  Specified by:
    `setTracks` in interface `TracksEntity`

### getTags

    public final java.util.List<Tag> getTags()

  Specified by:
    `getTags` in interface `TagsEntity`

### setTags

    public final void setTags(java.util.List<Tag> tags)

  Specified by:
    `setTags` in interface `TagsEntity`

### getWiki

    public final Wiki getWiki()

  Specified by:
    `getWiki` in interface `WikiEntity`

### setWiki

    public final void setWiki(Wiki wiki)

  Specified by:
    `setWiki` in interface `WikiEntity`

### getRank

    public final java.lang.Integer getRank()

  Specified by:
    `getRank` in interface `RankEntity`

### setRank

    public final void setRank(java.lang.Integer rank)

  Specified by:
    `setRank` in interface `RankEntity`

### setStreamable

    public void setStreamable(Streamable streamable)

  Specified by:
    `setStreamable` in interface `StreamableEntity`

### getStreamable

    public Streamable getStreamable()

  Specified by:
    `getStreamable` in interface `StreamableEntity`

### hashCode

    public final int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### equals

    public final boolean equals(java.lang.Object obj)

  Overrides:
    `equals` in class `java.lang.Object`

### addTags

    public static PostQuery<java.lang.Boolean> addTags(java.lang.String artist,
                                                       java.lang.String album,
                                                       java.util.List<java.lang.String> tags,
                                                       java.lang.String sk)

  Tag an album using a list of user supplied tags.

  Parameters:
    `artist` - The artist name in question (Required).
    `album` - The album name in question (Required).
    `tags` - A list of user supplied tags to apply to this album. Accepts a maximum of 10 tags (Required).
    `sk` - A session key generated by authenticating a user via the authentication protocol (Required).
  Returns:

### getBuylinks

    public static UnauthenticatedGetQuery<Affiliations> getBuylinks(java.lang.String artist,
                                                                    java.lang.String album,
                                                                    java.lang.String mbid,
                                                                    net.dontdrinkandroot.utils.ISO_3166_1_alpha2 country)

  Get a list of Buy Links for a particular Album. It is required that you supply either the artist and track params or the mbid param.

  Parameters:
    `artist` - The artist name in question (Required unless mbid).
    `album` - The album in question (Required unless mbid).
    `mbid` - A MusicBrainz id for the album in question (Optional).
    `country` - A country name, as defined by the ISO 3166-1 country names standard (Optional).
  Returns:

### getInfo

    public static UnauthenticatedGetQuery<Album> getInfo(java.lang.String artist,
                                                         java.lang.String album,
                                                         java.lang.String mbid,
                                                         java.lang.String username,
                                                         net.dontdrinkandroot.utils.ISO_3166_1_alpha2 lang)

  Get the metadata for an album on Last.fm using the album name or a musicbrainz id. See `Playlist#fetch` on how to get the album playlist.

  Parameters:
    `artist` - The artist name in question (Optional).
    `album` - The album name in question (Optional).
    `mbid` - The musicbrainz id for the album (Optional).
    `username` - The username for the context of the request. If supplied, the user's playcount for this album is included in the response. (Optional).
    `lang` - The language to return the biography in, expressed as an ISO 639 alpha-2 code. (Optional).
  Returns:

### getShouts

    public static UnauthenticatedGetQuery<PaginatedResult<java.util.List<Shout>>> getShouts(java.lang.String artist,
                                                                                            java.lang.String album,
                                                                                            java.lang.String mbid,
                                                                                            java.lang.Integer limit,
                                                                                            java.lang.Integer page)

  Get shouts for this album.

  Parameters:
    `artist` - The artist name (Required unless mbid).
    `album` - The album title (Required unless mbid).
    `mbid` - The musicbrainz id for the artist (Optional).
    `limit` - The number of results to fetch per page (Optional). Defaults to 50.
    `page` - The page number to fetch (Optional). Defaults to first page.
  Returns:

### getTags

    public static UnauthenticatedGetQuery<java.util.ArrayList<Tag>> getTags(java.lang.String artist,
                                                                            java.lang.String album,
                                                                            java.lang.String mbid,
                                                                            java.lang.String user)

  Get the tags applied by an individual user to an album on Last.fm.

  Parameters:
    `artist` - The artist name in question (Required).
    `album` - The album name in question (Required).
    `mbid` - The musicbrainz id for the album (Optional).
    `user` - The user to look up (Required).
  Returns:

### getTopTags

    public static UnauthenticatedGetQuery<java.util.ArrayList<Tag>> getTopTags(java.lang.String artist,
                                                                               java.lang.String album,
                                                                               java.lang.String mbid)

  Get the top tags for an album on Last.fm, ordered by popularity.

  Parameters:
    `artist` - The artist name in question (Required).
    `album` - The album name in question (Required).
    `mbid` - The musicbrainz id for the album (Optional).
  Returns:

### removeTag

    public static PostQuery<java.lang.Boolean> removeTag(java.lang.String artist,
                                                         java.lang.String album,
                                                         java.lang.String tag,
                                                         java.lang.String sk)

  Remove a user's tag from an album.

  Parameters:
    `artist` - The artist name in question (Required).
    `album` - The album name in question (Required).
    `tag` - A single user tag to remove from this album. (Required).
    `sk` - A session key generated by authenticating a user via the authentication protocol. (Required).
  Returns:

### search

    public static UnauthenticatedGetQuery<PaginatedResult<java.util.List<Album>>> search(java.lang.String album,
                                                                                         java.lang.Integer limit,
                                                                                         java.lang.Integer page)

  Search for an album by name. Returns album matches sorted by relevance.

  Parameters:
    `album` - The album name (Required).
    `limit` - The number of results to fetch per page (Optional). Defaults to 30.
    `page` - The page number to fetch (Optional). Defaults to first page.
  Returns:

### share

    public static PostQuery<java.lang.Boolean> share(java.lang.String artist,
                                                     java.lang.String album,
                                                     java.util.List<java.lang.String> recipient,
                                                     java.lang.Boolean publicViewable,
                                                     java.lang.String message,
                                                     java.lang.String sk)

  Share an album with one or more Last.fm users or other friends.

  Parameters:
    `artist` - An artist name (Required).
    `album` - An album name (Required).
    `recipient` - Email Address | Last.fm Username - A comma delimited list of email addresses or Last.fm usernames (Required). Maximum is 10.
    `publicViewable` - Optionally show in the sharing users activity feed. Defaults to 0 (false) (Optional).
    `message` - An optional message to send with the recommendation (Optional). If not supplied a default message will be used.
  Returns:

Copyright © 2013 dontdrinkandroot. All Rights Reserved.