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

◆ WriteStringIndented() [9/12]

void System.Text.Json.Utf8JsonWriter.WriteStringIndented ( ReadOnlySpan< char > escapedPropertyName,
Guid value )
inlineprivate

Definition at line 2116 of file Utf8JsonWriter.cs.

2117 {
2119 int num = indentation + escapedPropertyName.Length * 3 + 36 + 7 + s_newLineLength;
2120 if (_memory.Length - BytesPending < num)
2121 {
2122 Grow(num);
2123 }
2124 Span<byte> span = _memory.Span;
2125 if (_currentDepth < 0)
2126 {
2127 span[BytesPending++] = 44;
2128 }
2129 if (_tokenType != 0)
2130 {
2132 }
2133 JsonWriterHelper.WriteIndentation(span.Slice(BytesPending), indentation);
2135 span[BytesPending++] = 34;
2137 span[BytesPending++] = 34;
2138 span[BytesPending++] = 58;
2139 span[BytesPending++] = 32;
2140 span[BytesPending++] = 34;
2141 int bytesWritten;
2144 span[BytesPending++] = 34;
2145 }
static bool TryFormat(bool value, Span< byte > destination, out int bytesWritten, StandardFormat format=default(StandardFormat))
static readonly int s_newLineLength
void Grow(int requiredSize)
void WriteNewLine(Span< byte > output)
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._tokenType, System.Text.Json.Utf8JsonWriter.BytesPending, System.Text.Json.Dictionary, System.Text.Json.Utf8JsonWriter.Grow(), System.Text.Json.Utf8JsonWriter.Indentation, System.Memory< T >.Length, System.Text.Json.Utf8JsonWriter.s_newLineLength, System.Memory< T >.Span, System.Text.Json.Utf8JsonWriter.TranscodeAndWrite(), System.Buffers.Text.Utf8Formatter.TryFormat(), System.value, System.Text.Json.JsonWriterHelper.WriteIndentation(), and System.Text.Json.Utf8JsonWriter.WriteNewLine().