public HttpResponseState(HttpStatusCode statusCode, string statusDescription, Uri requestUrl, Header[] headers, Cookie[] cookies, string contentType) { StatusCode = statusCode; StatusDescription = statusDescription; RequestUrl = requestUrl; Headers = headers; Cookies = cookies; ContentType = contentType; }
public HttpResponseState( HttpStatusCode statusCode, string statusDescription, Uri requestUrl, Header[] headers, Cookie[] cookies, string contentType, string server, string contentEncoding, DateTime lastModified) : this(statusCode, statusDescription, requestUrl, headers, cookies, contentType) { Server = server; ContentEncoding = contentEncoding; LastModified = lastModified; }
private void ApplyHeaderToRequest(Header header, HttpWebRequest request) { var headerName = header.Name; if (reservedHeaderApplicators.ContainsKey(headerName)) { reservedHeaderApplicators[headerName](request, header.Value); } else { request.Headers[header.Name] = header.Value; } }