Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ Write() [2/2]

override void System.Net.Http.HttpConnection.ChunkedEncodingWriteStream.Write ( ReadOnlySpan< byte > buffer)
inlinevirtual

Reimplemented from System.IO.Stream.

Definition at line 379 of file HttpConnection.cs.

380 {
381 base.BytesWritten += buffer.Length;
383 if (buffer.Length == 0)
384 {
385 connectionOrThrow.Flush();
386 return;
387 }
388 connectionOrThrow.WriteHexInt32Async(buffer.Length, async: false).GetAwaiter().GetResult();
389 connectionOrThrow.WriteTwoBytesAsync(13, 10, async: false).GetAwaiter().GetResult();
391 connectionOrThrow.WriteTwoBytesAsync(13, 10, async: false).GetAwaiter().GetResult();
392 }
HttpConnection(HttpConnectionPool pool, Socket socket, Stream stream, TransportContext transportContext)

References System.buffer, and System.Net.Http.HttpContentStream.GetConnectionOrThrow().