27 references to MaximumFormatDateTimeOffsetLength
System.Text.Json (27)
System\Text\Json\JsonConstants.cs (1)
97
public const int MaximumDateTimeOffsetParseLength = (
MaximumFormatDateTimeOffsetLength
+
System\Text\Json\Writer\JsonWriterHelper.Date.cs (4)
17
Span<byte> tempSpan = stackalloc byte[JsonConstants.
MaximumFormatDateTimeOffsetLength
];
26
Span<byte> tempSpan = stackalloc byte[JsonConstants.
MaximumFormatDateTimeOffsetLength
];
53
buffer.Length == JsonConstants.
MaximumFormatDateTimeOffsetLength
);
88
else if (buffer.Length == JsonConstants.
MaximumFormatDateTimeOffsetLength
)
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.DateTime.cs (9)
215
Debug.Assert(escapedPropertyName.Length < (int.MaxValue / JsonConstants.MaxExpansionFactorWhileTranscoding) - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 6);
219
int maxRequired = (escapedPropertyName.Length * JsonConstants.MaxExpansionFactorWhileTranscoding) + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 6;
249
Debug.Assert(escapedPropertyName.Length < int.MaxValue - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 6);
251
int minRequired = escapedPropertyName.Length + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 5; // 2 quotes for property name, 2 quotes for date, and 1 colon
286
Debug.Assert(escapedPropertyName.Length < (int.MaxValue / JsonConstants.MaxExpansionFactorWhileTranscoding) - indent - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 7 - _newLineLength);
290
int maxRequired = indent + (escapedPropertyName.Length * JsonConstants.MaxExpansionFactorWhileTranscoding) + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 7 + _newLineLength;
335
Debug.Assert(escapedPropertyName.Length < int.MaxValue - indent - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 7 - _newLineLength);
337
int minRequired = indent + escapedPropertyName.Length + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 6; // 2 quotes for property name, 2 quotes for date, 1 colon, and 1 space
381
Span<byte> buffer = stackalloc byte[JsonConstants.
MaximumFormatDateTimeOffsetLength
];
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.DateTimeOffset.cs (9)
214
Debug.Assert(escapedPropertyName.Length < (int.MaxValue / JsonConstants.MaxExpansionFactorWhileTranscoding) - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 6);
218
int maxRequired = (escapedPropertyName.Length * JsonConstants.MaxExpansionFactorWhileTranscoding) + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 6;
248
Debug.Assert(escapedPropertyName.Length < int.MaxValue - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 6);
250
int minRequired = escapedPropertyName.Length + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 5; // 2 quotes for property name, 2 quotes for date, and 1 colon
285
Debug.Assert(escapedPropertyName.Length < (int.MaxValue / JsonConstants.MaxExpansionFactorWhileTranscoding) - indent - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 7 - _newLineLength);
289
int maxRequired = indent + (escapedPropertyName.Length * JsonConstants.MaxExpansionFactorWhileTranscoding) + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 7 + _newLineLength;
334
Debug.Assert(escapedPropertyName.Length < int.MaxValue - indent - JsonConstants.
MaximumFormatDateTimeOffsetLength
- 7 - _newLineLength);
336
int minRequired = indent + escapedPropertyName.Length + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 6; // 2 quotes for property name, 2 quotes for date, 1 colon, and 1 space
380
Span<byte> buffer = stackalloc byte[JsonConstants.
MaximumFormatDateTimeOffsetLength
];
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.DateTime.cs (2)
44
int maxRequired = JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 3; // 2 quotes, and optionally, 1 list separator
72
int maxRequired = indent + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 3 + _newLineLength;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.DateTimeOffset.cs (2)
45
int maxRequired = JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 3; // 2 quotes, and optionally, 1 list separator
73
int maxRequired = indent + JsonConstants.
MaximumFormatDateTimeOffsetLength
+ 3 + _newLineLength;