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

◆ WriteNumberIndented() [6/10]

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

Definition at line 1442 of file Utf8JsonWriter.cs.

1443 {
1445 int num = indentation + escapedPropertyName.Length * 3 + 31 + 5 + s_newLineLength;
1446 if (_memory.Length - BytesPending < num)
1447 {
1448 Grow(num);
1449 }
1450 Span<byte> span = _memory.Span;
1451 if (_currentDepth < 0)
1452 {
1453 span[BytesPending++] = 44;
1454 }
1455 if (_tokenType != 0)
1456 {
1458 }
1459 JsonWriterHelper.WriteIndentation(span.Slice(BytesPending), indentation);
1461 span[BytesPending++] = 34;
1463 span[BytesPending++] = 34;
1464 span[BytesPending++] = 58;
1465 span[BytesPending++] = 32;
1466 int bytesWritten;
1469 }
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().

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