1 override of GetValue
System.Text.Json (1)
System\Text\Json\Nodes\JsonValueOfT.cs (1)
23
public override T
GetValue
<T>()
64 references to GetValue
Aspire.Hosting.Tests (1)
Azure\AzureBicepProvisionerTests.cs (1)
53
Assert.Equal(20, parameters["age"]?["value"]?.
GetValue
<int>());
ConfigurationSchemaGenerator (1)
ConfigSchemaEmitter.cs (1)
421
if (propertyNodeType?.GetValueKind() == JsonValueKind.String && propertyNodeType.
GetValue
<string>() == "boolean")
dotnet-user-jwts (1)
Helpers\SigningKeysHandler.cs (1)
85
var toRemove = signingKeys.SingleOrDefault(key => key["Issuer"].
GetValue
<string>() == issuer);
Microsoft.AspNetCore.Authentication.JwtBearer.Tools.Tests (20)
UserJwtsTests.cs (20)
76
Assert.Equal("dotnet-user-jwts", appSettings["Authentication"]["Schemes"]["Bearer"]["ValidIssuer"].
GetValue
<string>());
79
Assert.Equal("new-issuer", appSettings["Authentication"]["Schemes"]["Bearer"]["ValidIssuer"].
GetValue
<string>());
214
Assert.Equal("baz", fooField["Bar"].
GetValue
<string>());
432
Assert.Equal(32, signingKey["Length"].
GetValue
<int>());
433
Assert.True(Convert.TryFromBase64String(signingKey["Value"].
GetValue
<string>(), new byte[32], out var _));
435
Assert.Equal("baz", fooField["Bar"].
GetValue
<string>());
460
Assert.Equal(32, signingKey["Length"].
GetValue
<int>());
461
Assert.True(Convert.TryFromBase64String(signingKey["Value"].
GetValue
<string>(), new byte[32], out var _));
463
Assert.Equal("baz", fooField["Bar"].
GetValue
<string>());
499
Assert.Equal(32, signingKey["Length"].
GetValue
<int>());
500
Assert.True(Convert.TryFromBase64String(signingKey["Value"].
GetValue
<string>(), new byte[32], out var _));
501
Assert.Equal("test-issuer", signingKey["Issuer"].
GetValue
<string>());
522
Assert.NotNull(signingKeys.SingleOrDefault(signingKey => signingKey["Issuer"].
GetValue
<string>() == "test-issuer"));
523
Assert.NotNull(signingKeys.SingleOrDefault(signingKey => signingKey["Issuer"].
GetValue
<string>() == "test-issuer-2"));
542
Assert.Equal("test-issuer", signingKey1["Issuer"].
GetValue
<string>());
543
Assert.Equal(32, signingKey1["Length"].
GetValue
<int>());
544
Assert.True(Convert.TryFromBase64String(signingKey1["Value"].
GetValue
<string>(), new byte[32], out var _));
546
Assert.Equal("test-issuer", signingKey2["Issuer"].
GetValue
<string>());
547
Assert.Equal(32, signingKey2["Length"].
GetValue
<int>());
548
Assert.True(Convert.TryFromBase64String(signingKey2["Value"].
GetValue
<string>(), new byte[32], out var _));
Microsoft.AspNetCore.Http.Extensions.Tests (2)
RequestDelegateFactoryTests.cs (1)
1391
Assert.Equal(nameof(JsonTodoChild), deserializedResponseBody["$type"]!.
GetValue
<string>());
RequestDelegateGenerator\RequestDelegateCreationTests.Responses.cs (1)
680
Assert.Equal(nameof(JsonTodoChild), node["$type"]!.
GetValue
<string>());
Microsoft.AspNetCore.OpenApi (3)
Extensions\JsonNodeSchemaExtensions.cs (3)
101
var targetKey = schema[OpenApiSchemaKeywords.TypeKeyword]?.
GetValue
<string>() == "array" ? OpenApiSchemaKeywords.MaxItemsKeyword : OpenApiSchemaKeywords.MaxLengthKeyword;
106
var targetKey = schema[OpenApiSchemaKeywords.TypeKeyword]?.
GetValue
<string>() == "array" ? OpenApiSchemaKeywords.MinItemsKeyword : OpenApiSchemaKeywords.MinLengthKeyword;
111
var targetKeySuffix = schema[OpenApiSchemaKeywords.TypeKeyword]?.
GetValue
<string>() == "array" ? "Items" : "Length";
System.Text.Json (36)
System\Text\Json\Nodes\JsonArray.cs (2)
137
/// Returns an enumerable that wraps calls to <see cref="JsonNode.
GetValue
{T}"/>.
145
yield return item is null ? (T)(object?)null! : item.
GetValue
<T>();
System\Text\Json\Nodes\JsonNode.Operators.cs (33)
255
public static explicit operator bool(JsonNode value) => value.
GetValue
<bool>();
262
public static explicit operator bool?(JsonNode? value) => value?.
GetValue
<bool>();
269
public static explicit operator byte(JsonNode value) => value.
GetValue
<byte>();
276
public static explicit operator byte?(JsonNode? value) => value?.
GetValue
<byte>();
283
public static explicit operator char(JsonNode value) => value.
GetValue
<char>();
290
public static explicit operator char?(JsonNode? value) => value?.
GetValue
<char>();
297
public static explicit operator DateTime(JsonNode value) => value.
GetValue
<DateTime>();
304
public static explicit operator DateTime?(JsonNode? value) => value?.
GetValue
<DateTime>();
311
public static explicit operator DateTimeOffset(JsonNode value) => value.
GetValue
<DateTimeOffset>();
318
public static explicit operator DateTimeOffset?(JsonNode? value) => value?.
GetValue
<DateTimeOffset>();
325
public static explicit operator decimal(JsonNode value) => value.
GetValue
<decimal>();
332
public static explicit operator decimal?(JsonNode? value) => value?.
GetValue
<decimal>();
339
public static explicit operator double(JsonNode value) => value.
GetValue
<double>();
346
public static explicit operator double?(JsonNode? value) => value?.
GetValue
<double>();
353
public static explicit operator Guid(JsonNode value) => value.
GetValue
<Guid>();
360
public static explicit operator Guid?(JsonNode? value) => value?.
GetValue
<Guid>();
367
public static explicit operator short(JsonNode value) => value.
GetValue
<short>();
374
public static explicit operator short?(JsonNode? value) => value?.
GetValue
<short>();
381
public static explicit operator int(JsonNode value) => value.
GetValue
<int>();
388
public static explicit operator int?(JsonNode? value) => value?.
GetValue
<int>();
395
public static explicit operator long(JsonNode value) => value.
GetValue
<long>();
402
public static explicit operator long?(JsonNode? value) => value?.
GetValue
<long>();
410
public static explicit operator sbyte(JsonNode value) => value.
GetValue
<sbyte>();
418
public static explicit operator sbyte?(JsonNode? value) => value?.
GetValue
<sbyte>();
425
public static explicit operator float(JsonNode value) => value.
GetValue
<float>();
432
public static explicit operator float?(JsonNode? value) => value?.
GetValue
<float>();
439
public static explicit operator string?(JsonNode? value) => value?.
GetValue
<string>();
447
public static explicit operator ushort(JsonNode value) => value.
GetValue
<ushort>();
455
public static explicit operator ushort?(JsonNode? value) => value?.
GetValue
<ushort>();
463
public static explicit operator uint(JsonNode value) => value.
GetValue
<uint>();
471
public static explicit operator uint?(JsonNode? value) => value?.
GetValue
<uint>();
479
public static explicit operator ulong(JsonNode value) => value.
GetValue
<ulong>();
487
public static explicit operator ulong?(JsonNode? value) => value?.
GetValue
<ulong>();
System\Text\Json\Nodes\JsonValue.cs (1)
32
/// <seealso cref="JsonNode.
GetValue
{T}"></seealso>