ResponseStream class
Writes a response body in pieces, so the client receives each piece while the handler is still producing the rest.
public sealed class ResponseStream
Public Members
| name | description |
|---|---|
| Complete() | Ends the body and returns the response for the handler to return. |
| WriteAsync(…) | Sends one piece of the body, and completes when Isoplane has accepted all of it. |
Remarks
Stream creates one, and shows the whole pattern: write each piece with WriteAsync, then return Complete from the handler.
The writer takes bytes. Encode text first, for example with Encoding.UTF8.GetBytes.
See Also
- namespace Isoplane