public SetlistFmApi(string apiKey) { _xmlDeserializer = new SetlistFmXmlDeserializer(); _jsonDeserializer = new SetlistFmJsonDeserializer(); _apiKey = apiKey; _client = new RestClient(); _client.BaseUrl = new Uri(_baseUrl); Format = DataFormat.Xml; _client.ClearHandlers(); _client.AddHandler("text/xml", _xmlDeserializer); _client.AddHandler("application/xml", _xmlDeserializer); _client.AddHandler("application/json", _jsonDeserializer); _client.AddHandler("text/json", _jsonDeserializer); _client.AddHandler("text/x-json", _jsonDeserializer); _client.AddHandler("text/javascript", _jsonDeserializer); _client.AddHandler("*", _xmlDeserializer); }
public SetlistFmJsonDeserializer() { _badgerFisher = new BadgerFisher(); _deserializer = new SetlistFmXmlDeserializer(); }