/// <summary> /// 创建 <see cref="ResponseObjectContentBase{T}"/> 的新实例(HttpObjectResponseContent) /// </summary> public ResponseObjectContent(HttpContext context, HttpClient client) : base(context, client) { if (!HttpSetting.DisableComptatibleCheck) { HttpSetting.CheckObjectTypeSupport(typeof(T)); } }
/// <summary> /// 创建 <see cref="HttpClient" /> 的新实例(HttpClient) /// </summary> public HttpClient(HttpSetting setting = null, HttpHandler handler = null, CookieContainer cookieContainer = null) { Setting = setting ?? new HttpSetting(); CookieContainer = cookieContainer ?? new CookieContainer(4096, 100, 4096); HttpHandler = handler ?? new HttpHandler(); }
/// <summary> /// 创建 <see cref="HttpClient" /> 的新实例(HttpClient) /// </summary> public HttpClient(HttpSetting setting, HttpHandler handler = null, CookieContainer cookieContainer = null) { Setting = setting; CookieContainer = cookieContainer ?? new CookieContainer(); HttpHandler = handler ?? new HttpHandler(); }