2010-09-28 03:40:01 +00:00
|
|
|
|
using System;
|
|
|
|
|
using System.Net;
|
|
|
|
|
|
2010-09-28 04:25:41 +00:00
|
|
|
|
namespace NzbDrone.Core.Providers
|
2010-09-28 03:40:01 +00:00
|
|
|
|
{
|
2010-09-28 04:25:41 +00:00
|
|
|
|
class HttpProvider : IHttpProvider
|
2010-09-28 03:40:01 +00:00
|
|
|
|
{
|
|
|
|
|
public string GetRequest(string request)
|
|
|
|
|
{
|
|
|
|
|
//Get the request and return as String Array
|
|
|
|
|
try
|
|
|
|
|
{
|
|
|
|
|
var webClient = new WebClient();
|
|
|
|
|
return webClient.DownloadString(request);
|
|
|
|
|
}
|
|
|
|
|
catch (Exception ex)
|
|
|
|
|
{
|
|
|
|
|
Console.WriteLine(ex);
|
|
|
|
|
return String.Empty;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|