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

            asyncResult.AsyncWaitHandle.WaitOne();
            return(this.EndGetTorrentURL(asyncResult));
        }
Example #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));
        }
Example #3
0
 public string GetTorrentURL(TorrentInfo info)
 {
     IAsyncResult asyncResult = this.BeginGetTorrentURL(info, null);
     asyncResult.AsyncWaitHandle.WaitOne();
     return this.EndGetTorrentURL(asyncResult);
 }
Example #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);
        }
Example #5
0
 public IAsyncResult BeginGetTorrentURL(TorrentInfo info, AsyncCallback callBack)
 {
     return this.BeginGetTorrentURL(info, callBack, null);
 }
Example #6
0
 public IAsyncResult BeginGetTorrentURL(TorrentInfo info, AsyncCallback callBack)
 {
     return(this.BeginGetTorrentURL(info, callBack, null));
 }