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

◆ ConsumePropertyName()

bool System.Text.Json.Utf8JsonReader.ConsumePropertyName ( )
inlineprivate

Definition at line 873 of file Utf8JsonReader.cs.

874 {
876 if (!ConsumeString())
877 {
878 return false;
879 }
880 if (!HasMoreData(ExceptionResource.ExpectedValueAfterPropertyNameNotFound))
881 {
882 return false;
883 }
884 byte b = _buffer[_consumed];
885 if (b <= 32)
886 {
888 if (!HasMoreData(ExceptionResource.ExpectedValueAfterPropertyNameNotFound))
889 {
890 return false;
891 }
893 }
894 if (b != 58)
895 {
896 ThrowHelper.ThrowJsonReaderException(ref this, ExceptionResource.ExpectedSeparatorAfterPropertyNameNotFound, b);
897 }
898 _consumed++;
900 _tokenType = JsonTokenType.PropertyName;
901 return true;
902 }

References System.Text.Json.Utf8JsonReader._buffer, System.Text.Json.Utf8JsonReader._bytePositionInLine, System.Text.Json.Utf8JsonReader._consumed, System.Text.Json.Utf8JsonReader._tokenType, System.Text.Json.Utf8JsonReader._trailingCommaBeforeComment, System.Text.Json.Utf8JsonReader.ConsumeString(), System.Text.Json.Dictionary, System.Text.Json.Utf8JsonReader.HasMoreData(), System.Text.Json.Utf8JsonReader.SkipWhiteSpace(), and System.Text.Json.ThrowHelper.ThrowJsonReaderException().

Referenced by System.Text.Json.Utf8JsonReader.ConsumeNextToken(), System.Text.Json.Utf8JsonReader.ConsumeNextTokenFromLastNonCommentToken(), System.Text.Json.Utf8JsonReader.ConsumeNextTokenUntilAfterAllCommentsAreSkipped(), and System.Text.Json.Utf8JsonReader.ReadSingleSegment().