Legend

Class
Struct
Enum
Interface
Delegate
Constructor
Method
Property
Event
Field

Sealed class: RT.Servers.HttpResponseContent

Summary

Encapsulates an HTTP response, to be sent by HttpServer to the HTTP client that sent the original request. A request handler must return an HttpResponse object to the HttpServer when handling a request.

Constructors

HttpResponseContent(HttpStatusCode status, HttpResponseHeaders headers, Func<Stream> contentStreamDelegate = null)
Encapsulates an HTTP response, to be sent by HttpServer to the HTTP client that sent the original request. A request handler must return an HttpResponse object to the HttpServer when handling a request.

Instance methods

StreamRetrieves the stream object containing the response body.
HttpResponseContent Modifies the HttpResponseContent.UseGzip option in this response object and returns the same object.

Instance properties

HttpStatusCodeThe HTTP status code. For example, 200 OK, 404 Not Found, 500 Internal Server Error. Default is 200 OK.

Instance fields

UseGzipOptionSpecifies whether gzip should be used.