nz.ac.waikato.mcennis.rat.graph.artist.decider
Class LastFMDecider

java.lang.Object
  extended by nz.ac.waikato.mcennis.rat.graph.artist.decider.ArtistDeciderBase
      extended by nz.ac.waikato.mcennis.rat.graph.artist.decider.LastFMDecider
All Implemented Interfaces:
ArtistDecider, ParsedObject

public class LastFMDecider
extends ArtistDeciderBase

Class for using LastFM related-artist REST service for determining whether or not an string is an artist or not.


Method Summary
 void lookup(java.lang.String name)
          Lookup the artist on LastFM using the web crawler and pre-determined parser.
static LastFMDecider newInstance()
          acquire a reference to this singleton object
 void setParser(java.lang.String type)
          Sets parser type to either to be the XML parser (parsing related artists) or parsing the artist bio page (parsing HTML).
 void setProxy(boolean p)
          Should a proxy be used
 
Methods inherited from class nz.ac.waikato.mcennis.rat.graph.artist.decider.ArtistDeciderBase
addArtist, addChecked, isArtist, isChecked, output
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

newInstance

public static LastFMDecider newInstance()
acquire a reference to this singleton object

Returns:
reference to the LastFMDecider object

setParser

public void setParser(java.lang.String type)
Sets parser type to either to be the XML parser (parsing related artists) or parsing the artist bio page (parsing HTML).

Parameters:
type - name of potential artist

lookup

public void lookup(java.lang.String name)
Lookup the artist on LastFM using the web crawler and pre-determined parser.

Specified by:
lookup in class ArtistDeciderBase
Parameters:
name - string to be looked up.

setProxy

public void setProxy(boolean p)
Should a proxy be used

Parameters:
p - true/false on proxy.