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

◆ WriteStringIndented() [3/12]

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

Definition at line 2147 of file Utf8JsonWriter.cs.

2148 {
2150 int num = indentation + escapedPropertyName.Length + 36 + 6;
2151 int num2 = num + 1 + s_newLineLength;
2153 {
2154 Grow(num2);
2155 }
2156 Span<byte> span = _memory.Span;
2157 if (_currentDepth < 0)
2158 {
2159 span[BytesPending++] = 44;
2160 }
2161 if (_tokenType != 0)
2162 {
2164 }
2165 JsonWriterHelper.WriteIndentation(span.Slice(BytesPending), indentation);
2167 span[BytesPending++] = 34;
2168 escapedPropertyName.CopyTo(span.Slice(BytesPending));
2170 span[BytesPending++] = 34;
2171 span[BytesPending++] = 58;
2172 span[BytesPending++] = 32;
2173 span[BytesPending++] = 34;
2174 int bytesWritten;
2177 span[BytesPending++] = 34;
2178 }
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)
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.Buffers.Text.Utf8Formatter.TryFormat(), System.value, System.Text.Json.JsonWriterHelper.WriteIndentation(), and System.Text.Json.Utf8JsonWriter.WriteNewLine().