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

◆ WriteStringValueIndented() [1/3]

void System.Text.Json.Utf8JsonWriter.WriteStringValueIndented ( DateTime value)
inlineprivate

Definition at line 4411 of file Utf8JsonWriter.cs.

4412 {
4414 int num = indentation + 33 + 3 + s_newLineLength;
4415 if (_memory.Length - BytesPending < num)
4416 {
4417 Grow(num);
4418 }
4419 Span<byte> span = _memory.Span;
4420 if (_currentDepth < 0)
4421 {
4422 span[BytesPending++] = 44;
4423 }
4424 if (_tokenType != JsonTokenType.PropertyName)
4425 {
4426 if (_tokenType != 0)
4427 {
4429 }
4430 JsonWriterHelper.WriteIndentation(span.Slice(BytesPending), indentation);
4432 }
4433 span[BytesPending++] = 34;
4434 JsonWriterHelper.WriteDateTimeTrimmed(span.Slice(BytesPending), value, out var bytesWritten);
4436 span[BytesPending++] = 34;
4437 }
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.value, System.Text.Json.JsonWriterHelper.WriteDateTimeTrimmed(), System.Text.Json.JsonWriterHelper.WriteIndentation(), and System.Text.Json.Utf8JsonWriter.WriteNewLine().

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