Пример #1
0
 public HttpResponseEmpty(HttpServer server, int code)
     : base(server)
 {
     Head.StatusCode = code;
 }
Пример #2
0
 public HttpResponseString(HttpServer server, string content)
     : base(server)
 {
     buffer           = Encoding.Default.GetBytes(content);
     Head.ContentType = "text/plain";
 }
Пример #3
0
 public HttpResponseNoAnswer(HttpServer server)
     : base(server)
 {
 }
Пример #4
0
 public HttpResponseStream(HttpServer server, MemoryStream stream)
     : base(server)
 {
     this.Head.ContentType = "image/png";
     this.stream           = stream;
 }
Пример #5
0
 public HttpResponseRedirect(HttpServer server, string location)
     : base(server, 307)
 {
     Head.Location = location;
 }
Пример #6
0
 public HttpResponse(HttpServer server)
 {
     this.server = server;
     Head        = new HttpResponseHead();
 }