1 write to Value
System.Text.Json (1)
System\Text\Json\Nodes\JsonValueOfT.cs (1)
20Value = value;
37 references to Value
System.Text.Json (37)
System\Text\Json\Nodes\JsonNode.To.cs (3)
49return jsonString.Value; 52if (this is JsonValueOfElement { Value.ValueKind: JsonValueKind.String } jsonElement) 54return jsonElement.Value.GetString()!;
System\Text\Json\Nodes\JsonValueOfElement.cs (25)
19internal override JsonElement? UnderlyingElement => Value; 20internal override JsonNode DeepCloneCore() => new JsonValueOfElement(Value.Clone(), Options); 21private protected override JsonValueKind GetValueKindCore() => Value.ValueKind; 27return JsonElement.DeepEquals(Value, otherElement); 44ThrowHelper.ThrowInvalidOperationException_NodeUnableToConvertElement(Value.ValueKind, typeof(TypeToConvert)); 54if (Value is TypeToConvert element) 60switch (Value.ValueKind) 65success = Value.TryGetInt32(out int result); 72success = Value.TryGetInt64(out long result); 79success = Value.TryGetDouble(out double result); 86success = Value.TryGetInt16(out short result); 93success = Value.TryGetDecimal(out decimal result); 100success = Value.TryGetByte(out byte result); 107success = Value.TryGetSingle(out float result); 114success = Value.TryGetUInt32(out uint result); 121success = Value.TryGetUInt16(out ushort result); 128success = Value.TryGetUInt64(out ulong result); 135success = Value.TryGetSByte(out sbyte result); 144string? result = Value.GetString(); 152success = Value.TryGetDateTime(out DateTime result); 159success = Value.TryGetDateTimeOffset(out DateTimeOffset result); 166success = Value.TryGetGuid(out Guid result); 173string? result = Value.GetString(); 187value = (TypeToConvert)(object)Value.GetBoolean(); 204Value.WriteTo(writer);
System\Text\Json\Nodes\JsonValueOfT.cs (3)
26if (Value is T returnValue) 41if (Value is T returnValue) 141public TValue? Value => _node.Value;
System\Text\Json\Nodes\JsonValueOfTCustomized.cs (2)
27internal override JsonNode DeepCloneCore() => JsonSerializer.SerializeToNode(Value, _jsonTypeInfo)!; 44jsonTypeInfo.Serialize(writer, Value);
System\Text\Json\Nodes\JsonValueOfTPrimitive.cs (4)
28internal override JsonNode DeepCloneCore() => new JsonValuePrimitive<TValue>(Value, _converter, Options); 36return EqualityComparer<TValue>.Default.Equals(Value, v); 54converter.WriteNumberWithCustomHandling(writer, Value, options.NumberHandling); 58converter.Write(writer, Value, options);