mirror of
https://github.com/KevinWG/OSS.Tools.git
synced 2026-10-23 10:22:29 +08:00
27 lines
601 B
C#
27 lines
601 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.Linq;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using OSS.Http.Models;
|
|
|
|
namespace OSS.Http.Test
|
|
{
|
|
class Program
|
|
{
|
|
static void Main(string[] args)
|
|
{
|
|
var req = new OsHttpRequest();
|
|
|
|
req.Uri = new Uri("http://www.baidu.com");
|
|
|
|
var result = req.SendRest();
|
|
result.Wait();
|
|
var content = result.Result.Content.ReadAsStringAsync();
|
|
content.Wait();
|
|
Console.WriteLine(content.Result);
|
|
Console.Read();
|
|
}
|
|
}
|
|
}
|