150 references to String
Aspire.Dashboard (1)
Components\Dialogs\TextVisualizerDialog.razor.cs (1)
213case JsonTokenType.String:
Microsoft.AspNetCore.Grpc.JsonTranscoding (8)
Internal\Json\DurationConverter.cs (1)
20if (reader.TokenType != JsonTokenType.String)
Internal\Json\EnumConverter.cs (1)
23case JsonTokenType.String:
Internal\Json\FieldMaskConverter.cs (1)
24if (reader.TokenType != JsonTokenType.String)
Internal\Json\Int64Converter.cs (1)
18if (reader.TokenType == JsonTokenType.String)
Internal\Json\NullValueConverter.cs (1)
19case JsonTokenType.String:
Internal\Json\TimestampConverter.cs (1)
20if (reader.TokenType != JsonTokenType.String)
Internal\Json\UInt64Converter.cs (1)
19if (reader.TokenType == JsonTokenType.String)
Internal\Json\ValueConverter.cs (1)
41case JsonTokenType.String:
Microsoft.AspNetCore.Http.Connections.Common (3)
NegotiateProtocol.cs (1)
298case JsonTokenType.String:
src\SignalR\common\Shared\SystemTextJsonExtensions.cs (2)
76if (reader.TokenType != JsonTokenType.String) 78throw new InvalidDataException($"Expected '{propertyName}' to be of type {JsonTokenType.String}.");
Microsoft.AspNetCore.OpenApi (1)
Schemas\OpenApiJsonSchema.Helpers.cs (1)
129if (reader.TokenType == JsonTokenType.String)
Microsoft.AspNetCore.SignalR.Common (2)
src\SignalR\common\Shared\SystemTextJsonExtensions.cs (2)
76if (reader.TokenType != JsonTokenType.String) 78throw new InvalidDataException($"Expected '{propertyName}' to be of type {JsonTokenType.String}.");
Microsoft.AspNetCore.SignalR.Protocols.Json (6)
Protocol\JsonHubProtocol.cs (4)
197if (reader.TokenType != JsonTokenType.String) 199throw new InvalidDataException($"Expected '{TargetPropertyName}' to be of type {JsonTokenType.String}."); 499if (reader.TokenType != JsonTokenType.String) 501throw new InvalidDataException($"Expected header '{propertyName}' to be of type {JsonTokenType.String}.");
src\SignalR\common\Shared\SystemTextJsonExtensions.cs (2)
76if (reader.TokenType != JsonTokenType.String) 78throw new InvalidDataException($"Expected '{propertyName}' to be of type {JsonTokenType.String}.");
Microsoft.AspNetCore.SignalR.StackExchangeRedis (2)
src\SignalR\common\Shared\SystemTextJsonExtensions.cs (2)
76if (reader.TokenType != JsonTokenType.String) 78throw new InvalidDataException($"Expected '{propertyName}' to be of type {JsonTokenType.String}.");
Microsoft.CodeAnalysis.LanguageServer.Protocol (7)
Protocol\Converters\FormattingOptionsConverter.cs (1)
105JsonTokenType.String => reader.GetString(),
Protocol\Converters\NaturalObjectConverter.cs (1)
54case JsonTokenType.String:
Protocol\Converters\StringEnumConverter.cs (1)
40if (reader.TokenType == JsonTokenType.String)
Protocol\Converters\SumConverter.cs (2)
108JsonTokenType.String or 297case JsonTokenType.String:
Protocol\Converters\TextDocumentSyncConverter.cs (1)
31else if (reader.TokenType == JsonTokenType.String)
Protocol\Internal\Converters\ObjectContentConverter.cs (1)
68else if (reader.TokenType == JsonTokenType.String)
Microsoft.Extensions.DependencyModel (3)
Utf8JsonReaderExtensions.cs (3)
28if (reader.TokenType == JsonTokenType.String) 76while (reader.Read() && reader.TokenType == JsonTokenType.String) 97if (reader.TokenType != JsonTokenType.String)
Microsoft.JSInterop (1)
Infrastructure\ByteArrayJsonConverter.cs (1)
26if (reader.TokenType == JsonTokenType.String && reader.TryGetBytesFromBase64(out var bytes))
Microsoft.ML.SearchSpace (1)
Converter\ParameterConverter.cs (1)
22case JsonTokenType.String:
System.Text.Json (115)
src\libraries\System.Text.Json\Common\JsonNumberHandling.cs (2)
21/// Numbers can be read from <see cref="JsonTokenType.String"/> tokens. 37/// The "NaN", "Infinity", and "-Infinity" <see cref="JsonTokenType.String"/> tokens can be read as
System\Text\Json\Document\JsonDocument.cs (12)
236if (includeQuotes && row.TokenType == JsonTokenType.String) 271if (row.TokenType == JsonTokenType.String) 350isPropertyName ? JsonTokenType.PropertyName : JsonTokenType.String, 404CheckExpectedType(JsonTokenType.String, row.TokenType); 667CheckExpectedType(JsonTokenType.String, row.TokenType); 702CheckExpectedType(JsonTokenType.String, row.TokenType); 737CheckExpectedType(JsonTokenType.String, row.TokenType); 814case JsonTokenType.String: 845case JsonTokenType.String: 883Debug.Assert(row.TokenType == JsonTokenType.String || row.TokenType == JsonTokenType.PropertyName); 1068Debug.Assert(tokenType >= JsonTokenType.String && tokenType <= JsonTokenType.Null); 1077if (tokenType == JsonTokenType.String)
System\Text\Json\Document\JsonDocument.MetadataDb.cs (1)
388if (start.TokenType == JsonTokenType.String)
System\Text\Json\Document\JsonDocument.Parse.cs (2)
550case JsonTokenType.String: 737if (tokenType == JsonTokenType.String || tokenType == JsonTokenType.Number)
System\Text\Json\Document\JsonElement.cs (2)
386return _parent.GetString(_idx, JsonTokenType.String); 1671case JsonTokenType.String:
System\Text\Json\JsonHelpers.cs (1)
23Debug.Assert(reader.TokenType is JsonTokenType.String or JsonTokenType.PropertyName);
System\Text\Json\Reader\JsonReaderHelper.cs (3)
59case JsonTokenType.String: 76(tokenType - JsonTokenType.String) <= (JsonTokenType.Null - JsonTokenType.String);
System\Text\Json\Reader\Utf8JsonReader.cs (8)
440/// (i.e. other than <see cref="JsonTokenType.String"/> or <see cref="JsonTokenType.PropertyName"/>). 470/// (i.e. other than <see cref="JsonTokenType.String"/> or <see cref="JsonTokenType.PropertyName"/>). 511/// (i.e. other than <see cref="JsonTokenType.String"/> or <see cref="JsonTokenType.PropertyName"/>). 692return tokenType == JsonTokenType.PropertyName || tokenType == JsonTokenType.String; 1301_tokenType = JsonTokenType.String; 1400_tokenType = JsonTokenType.String; 2575JsonTokenType.String => nameof(JsonTokenType.String),
System\Text\Json\Reader\Utf8JsonReader.MultiSegment.cs (3)
767_tokenType = JsonTokenType.String; 946_tokenType = JsonTokenType.String; 1097_tokenType = JsonTokenType.String;
System\Text\Json\Reader\Utf8JsonReader.TryGet.cs (21)
22/// (i.e. other than <see cref="JsonTokenType.String"/>, <see cref="JsonTokenType.PropertyName"/> or 34if (TokenType != JsonTokenType.String && TokenType != JsonTokenType.PropertyName) 64/// (i.e. other than <see cref="JsonTokenType.String"/> or <see cref="JsonTokenType.PropertyName"/>. 71if (_tokenType is not (JsonTokenType.String or JsonTokenType.PropertyName)) 81Debug.Assert(_tokenType is JsonTokenType.String or JsonTokenType.PropertyName or JsonTokenType.Number); 128/// (i.e. other than <see cref="JsonTokenType.String"/> or <see cref="JsonTokenType.PropertyName"/>. 135if (_tokenType is not (JsonTokenType.String or JsonTokenType.PropertyName)) 145Debug.Assert(_tokenType is JsonTokenType.String or JsonTokenType.PropertyName or JsonTokenType.Number); 197Debug.Assert(_tokenType is JsonTokenType.String or JsonTokenType.PropertyName); 279/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 725/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 758/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 791/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 824/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 829if (TokenType != JsonTokenType.String) 1231/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 1236if (TokenType != JsonTokenType.String) 1296/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 1301if (TokenType != JsonTokenType.String) 1362/// Thrown if trying to get the value of a JSON token that is not a <see cref="JsonTokenType.String"/>. 1367if (TokenType != JsonTokenType.String)
System\Text\Json\Serialization\Converters\Node\JsonNodeConverter.cs (1)
43case JsonTokenType.String:
System\Text\Json\Serialization\Converters\Value\ByteConverter.cs (1)
40if (reader.TokenType == JsonTokenType.String && (JsonNumberHandling.AllowReadingFromString & handling) != 0)
System\Text\Json\Serialization\Converters\Value\CharConverter.cs (1)
15if (reader.TokenType is not (JsonTokenType.String or JsonTokenType.PropertyName))
System\Text\Json\Serialization\Converters\Value\DateOnlyConverter.cs (1)
17if (reader.TokenType != JsonTokenType.String)
System\Text\Json\Serialization\Converters\Value\DecimalConverter.cs (1)
39if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\DoubleConverter.cs (1)
40if (reader.TokenType == JsonTokenType.String)
System\Text\Json\Serialization\Converters\Value\EnumConverter.cs (2)
106case JsonTokenType.String when (_converterOptions & EnumConverterOptions.AllowStrings) != 0: 238Debug.Assert(reader.TokenType is JsonTokenType.String or JsonTokenType.PropertyName);
System\Text\Json\Serialization\Converters\Value\HalfConverter.cs (1)
87if (reader.TokenType == JsonTokenType.String)
System\Text\Json\Serialization\Converters\Value\Int128Converter.cs (1)
81if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\Int16Converter.cs (1)
41if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\Int32Converter.cs (1)
41if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\Int64Converter.cs (1)
40if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\SByteConverter.cs (1)
40if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\SingleConverter.cs (1)
41if (reader.TokenType == JsonTokenType.String)
System\Text\Json\Serialization\Converters\Value\TimeOnlyConverter.cs (2)
19if (reader.TokenType != JsonTokenType.String) 35Debug.Assert(reader.TokenType is JsonTokenType.String or JsonTokenType.PropertyName);
System\Text\Json\Serialization\Converters\Value\TimeSpanConverter.cs (2)
19if (reader.TokenType != JsonTokenType.String) 35Debug.Assert(reader.TokenType is JsonTokenType.String or JsonTokenType.PropertyName);
System\Text\Json\Serialization\Converters\Value\UInt128Converter.cs (1)
81if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\UInt16Converter.cs (1)
41if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\UInt32Converter.cs (1)
41if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\UInt64Converter.cs (1)
40if (reader.TokenType == JsonTokenType.String &&
System\Text\Json\Serialization\Converters\Value\VersionConverter.cs (2)
27if (reader.TokenType != JsonTokenType.String) 37Debug.Assert(reader.TokenType is JsonTokenType.PropertyName or JsonTokenType.String);
System\Text\Json\Serialization\JsonSerializer.Read.HandleMetadata.cs (3)
214if (reader.TokenType != JsonTokenType.String) 228if (reader.TokenType != JsonTokenType.String) 246case JsonTokenType.String:
System\Text\Json\Serialization\JsonSerializer.Read.Utf8JsonReader.cs (1)
409case JsonTokenType.String:
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.Bytes.cs (3)
28_tokenType = JsonTokenType.String; 78_tokenType = JsonTokenType.String; 102_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.DateTime.cs (3)
32_tokenType = JsonTokenType.String; 84_tokenType = JsonTokenType.String; 109_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.DateTimeOffset.cs (3)
31_tokenType = JsonTokenType.String; 83_tokenType = JsonTokenType.String; 108_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.Guid.cs (3)
31_tokenType = JsonTokenType.String; 83_tokenType = JsonTokenType.String; 108_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteProperties.String.cs (9)
436_tokenType = JsonTokenType.String; 526_tokenType = JsonTokenType.String; 550_tokenType = JsonTokenType.String; 622_tokenType = JsonTokenType.String; 672_tokenType = JsonTokenType.String; 712_tokenType = JsonTokenType.String; 762_tokenType = JsonTokenType.String; 802_tokenType = JsonTokenType.String; 874_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.Bytes.cs (1)
29_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.DateTime.cs (1)
39_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.DateTimeOffset.cs (1)
40_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.Guid.cs (1)
39_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.Raw.cs (2)
161_tokenType = JsonTokenType.String; 252_tokenType = JsonTokenType.String;
System\Text\Json\Writer\Utf8JsonWriter.WriteValues.String.cs (4)
26_tokenType = JsonTokenType.String; 79_tokenType = JsonTokenType.String; 226_tokenType = JsonTokenType.String; 364_tokenType = JsonTokenType.String;