12 references to MaximumFormatDecimalLength
System.Text.Json (12)
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.Decimal.cs (9)
217
Debug.Assert(escapedPropertyName.Length < (int.MaxValue / JsonConstants.MaxExpansionFactorWhileTranscoding) - JsonConstants.
MaximumFormatDecimalLength
- 4);
221
int maxRequired = (escapedPropertyName.Length * JsonConstants.MaxExpansionFactorWhileTranscoding) + JsonConstants.
MaximumFormatDecimalLength
+ 4;
248
Debug.Assert(escapedPropertyName.Length < int.MaxValue - JsonConstants.
MaximumFormatDecimalLength
- 4);
250
int minRequired = escapedPropertyName.Length + JsonConstants.
MaximumFormatDecimalLength
+ 3; // 2 quotes for property name, and 1 colon
282
Debug.Assert(escapedPropertyName.Length < (int.MaxValue / JsonConstants.MaxExpansionFactorWhileTranscoding) - indent - JsonConstants.
MaximumFormatDecimalLength
- 5 - _newLineLength);
286
int maxRequired = indent + (escapedPropertyName.Length * JsonConstants.MaxExpansionFactorWhileTranscoding) + JsonConstants.
MaximumFormatDecimalLength
+ 5 + _newLineLength;
328
Debug.Assert(escapedPropertyName.Length < int.MaxValue - indent - JsonConstants.
MaximumFormatDecimalLength
- 5 - _newLineLength);
330
int minRequired = indent + escapedPropertyName.Length + JsonConstants.
MaximumFormatDecimalLength
+ 4; // 2 quotes for property name, 1 colon, and 1 space
371
Span<byte> utf8PropertyName = stackalloc byte[JsonConstants.
MaximumFormatDecimalLength
];
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.Decimal.cs (3)
44
int maxRequired = JsonConstants.
MaximumFormatDecimalLength
+ 1; // Optionally, 1 list separator
68
int maxRequired = indent + JsonConstants.
MaximumFormatDecimalLength
+ 1 + _newLineLength; // Optionally, 1 list separator and 1-2 bytes for new line
99
Span<byte> utf8Number = stackalloc byte[JsonConstants.
MaximumFormatDecimalLength
];