public XmlElement[] TestEcho(string echoParameter, string echoValue)
{
Hashtable parameters = new Hashtable();
parameters.Add("method", "flickr.test.echo");
parameters.Add("api_key", _apiKey);
if( echoParameter != null && echoParameter.Length > 0 )
{
parameters.Add(echoParameter, echoValue);
}
FlickrNet.Response response = GetResponseCache(parameters);
if( response.Status == ResponseStatus.OK )
{
// Remove the api_key element from the array.
XmlElement[] elements = new XmlElement[response.AllElements.Length - 1];
int c = 0;
foreach(XmlElement element in response.AllElements)
{
if(element.Name != "api_key" )
elements[c++] = element;
}
return elements;
}
else
{
throw new FlickrException(response.Error);
}
}