Beispiel #1
0
        public string GetTorrentURL(TorrentInfo info)
        {
            IAsyncResult asyncResult = this.BeginGetTorrentURL(info, null);

            asyncResult.AsyncWaitHandle.WaitOne();
            return(this.EndGetTorrentURL(asyncResult));
        }
Beispiel #2
0
        public IAsyncResult BeginGetTorrentURL(TorrentInfo info, AsyncCallback callBack, object userState)
        {
            WebRequest wReq = WebRequest.Create(
                String.Format("http://exhentai.org/gallerytorrents.php?gid={0}&t={1{&gtid={2}",
                              info.Token.gid,
                              info.Token.token,
                              info.gtid));

            wReq.Proxy  = this.Proxy;
            wReq.Method = "GET";
            wReq.Headers.Set("cookie", this.m_cookie);

            return(new ApiResult(wReq, ExHentai.KeyTorrentUrl, callBack, userState));
        }
Beispiel #3
0
 public string GetTorrentURL(TorrentInfo info)
 {
     IAsyncResult asyncResult = this.BeginGetTorrentURL(info, null);
     asyncResult.AsyncWaitHandle.WaitOne();
     return this.EndGetTorrentURL(asyncResult);
 }
Beispiel #4
0
        public IAsyncResult BeginGetTorrentURL(TorrentInfo info, AsyncCallback callBack, object userState)
        {
            WebRequest wReq = WebRequest.Create(
                String.Format("http://exhentai.org/gallerytorrents.php?gid={0}&t={1{&gtid={2}",
                    info.Token.gid,
                    info.Token.token,
                    info.gtid));
            wReq.Proxy = this.Proxy;
            wReq.Method = "GET";
            wReq.Headers.Set("cookie", this.m_cookie);

            return new ApiResult(wReq, ExHentai.KeyTorrentUrl, callBack, userState);
        }
Beispiel #5
0
 public IAsyncResult BeginGetTorrentURL(TorrentInfo info, AsyncCallback callBack)
 {
     return this.BeginGetTorrentURL(info, callBack, null);
 }
Beispiel #6
0
 public IAsyncResult BeginGetTorrentURL(TorrentInfo info, AsyncCallback callBack)
 {
     return(this.BeginGetTorrentURL(info, callBack, null));
 }