de.umass.lastfm
Class MusicEntry
java.lang.Object
de.umass.lastfm.ImageHolder
de.umass.lastfm.MusicEntry
- Direct Known Subclasses:
- Album, Artist, Track
public abstract class MusicEntry
- extends ImageHolder
MusicEntry
is the abstract superclass for Track
, Artist
and Album
. It encapsulates data and provides
methods used in all subclasses, for example: name, playcount, images and more.
- Author:
- Janni Kovacs
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
name
protected String name
url
protected String url
mbid
protected String mbid
playcount
protected int playcount
userPlaycount
protected int userPlaycount
listeners
protected int listeners
streamable
protected boolean streamable
id
protected String id
percentageChange
protected int percentageChange
- This property is only available on hype charts, like
Chart.getHypedArtists(String)
or Group.getHype(String, String)
tags
protected Collection<String> tags
MusicEntry
protected MusicEntry(String name,
String url)
MusicEntry
protected MusicEntry(String name,
String url,
String mbid,
int playcount,
int listeners,
boolean streamable)
getListeners
public int getListeners()
getMbid
public String getMbid()
getName
public String getName()
getId
public String getId()
getPlaycount
public int getPlaycount()
getUserPlaycount
public int getUserPlaycount()
isStreamable
public boolean isStreamable()
getUrl
public String getUrl()
getTags
public Collection<String> getTags()
getPercentageChange
public int getPercentageChange()
- Returns the value of the "percentage change" fields in weekly hype charts responses, such as in
Group.getHype(String, String)
or Chart.getHypedArtists(String)
.
- Returns:
- Weekly percentage change
loadStandardInfo
protected static void loadStandardInfo(MusicEntry entry,
DomElement element)
- Loads all generic information from an XML
DomElement
into the given MusicEntry
instance, i.e. the following
tags:
- playcount/plays
- listeners
- streamable
- name
- url
- mbid
- image
- tags
- Parameters:
entry
- An entryelement
- XML source element
getWikiLastChanged
public Date getWikiLastChanged()
getWikiSummary
public String getWikiSummary()
getWikiText
public String getWikiText()