Пример #1
0
        //private WebClientX _Client;
        /// <summary>创建客户端</summary>
        /// <param name="url">路径</param>
        /// <returns></returns>
        protected virtual async Task <String> Request(String url)
        {
            //if (_Client == null)
            //{
            //    _Client = new WebClientX();
            //    _Client.Log = Log;
            //}

            //return await _Client.DownloadStringAsync(url);

            return(LastHtml = await WebClientX.GetStringAsync(url));
        }
Пример #2
0
 /// <summary>创建客户端</summary>
 /// <param name="url">路径</param>
 /// <returns></returns>
 protected virtual async Task <String> Request(String url)
 {
     return(LastHtml = await WebClientX.GetStringAsync(url));
 }