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

◆ GetParsedValueLength()

override int System.Net.Http.Headers.Int32NumberHeaderParser.GetParsedValueLength ( string value,
int startIndex,
object storeValue,
out object parsedValue )
inlineprotected

Definition at line 19 of file Int32NumberHeaderParser.cs.

20 {
21 parsedValue = null;
22 int numberLength = HttpRuleParser.GetNumberLength(value, startIndex, allowDecimal: false);
23 if (numberLength == 0 || numberLength > 10)
24 {
25 return 0;
26 }
27 int result = 0;
28 if (!HeaderUtilities.TryParseInt32(value, startIndex, numberLength, out result))
29 {
30 return 0;
31 }
32 parsedValue = result;
33 return numberLength;
34 }

References System.Net.Http.HttpRuleParser.GetNumberLength(), System.startIndex, System.Net.Http.Headers.HeaderUtilities.TryParseInt32(), and System.value.