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

◆ WriteBase64Minimized() [3/3]

void System.Text.Json.Utf8JsonWriter.WriteBase64Minimized ( ReadOnlySpan< char > escapedPropertyName,
ReadOnlySpan< byte > bytes )
inlineprivate

Definition at line 735 of file Utf8JsonWriter.cs.

736 {
739 if (_memory.Length - BytesPending < num)
740 {
741 Grow(num);
742 }
743 Span<byte> span = _memory.Span;
744 if (_currentDepth < 0)
745 {
746 span[BytesPending++] = 44;
747 }
748 span[BytesPending++] = 34;
750 span[BytesPending++] = 34;
751 span[BytesPending++] = 58;
752 span[BytesPending++] = 34;
754 span[BytesPending++] = 34;
755 }
static int GetMaxEncodedToUtf8Length(int length)
Definition Base64.cs:502
void Grow(int requiredSize)
void Base64EncodeAndWrite(ReadOnlySpan< byte > bytes, Span< byte > output, int encodingLength)
void TranscodeAndWrite(ReadOnlySpan< char > escapedPropertyName, Span< byte > output)
unsafe Span< T > Span
Definition Memory.cs:28

References System.Text.Json.Utf8JsonWriter._currentDepth, System.Text.Json.Utf8JsonWriter._memory, System.Text.Json.Utf8JsonWriter.Base64EncodeAndWrite(), System.bytes, System.Text.Json.Utf8JsonWriter.BytesPending, System.Text.Json.Dictionary, System.Buffers.Text.Base64.GetMaxEncodedToUtf8Length(), System.Text.Json.Utf8JsonWriter.Grow(), System.Memory< T >.Length, System.Memory< T >.Span, and System.Text.Json.Utf8JsonWriter.TranscodeAndWrite().

Referenced by System.Text.Json.Utf8JsonWriter.WriteBase64ByOptions(), System.Text.Json.Utf8JsonWriter.WriteBase64ByOptions(), and System.Text.Json.Utf8JsonWriter.WriteBase64ByOptions().