Beispiel #1
0
        internal HttpResponse(HttpContext context)
        {
            _context = context ?? throw new ArgumentNullException("context");

            CacheControl      = "private";
            CharSet           = "utf-8";
            ContentType       = "text/html";
            ExpiresAbsolute   = DateTime.MinValue;
            HeadersEncoding   = Encoding.UTF8;
            Headers           = new NameValueCollection();
            OutputStream      = new HttpOutputStream(new MemoryStream());
            StatusCode        = 200;
            StatusDescription = "OK";
            Cookies           = new HttpCookieCollection();
        }
Beispiel #2
0
        internal HttpResponse(HttpContext context)
        {
            if (context == null)
                throw new ArgumentNullException("context");

            _context = context;

            CacheControl = "private";
            CharSet = "utf-8";
            ContentType = "text/html";
            ExpiresAbsolute = DateTime.MinValue;
            HeadersEncoding = Encoding.UTF8;
            Headers = new NameValueCollection();
            OutputStream = new HttpOutputStream(new MemoryStream());
            StatusCode = 200;
            StatusDescription = "OK";
            Cookies = new HttpCookieCollection();
        }