Class DateTimeJsonConverter
DateTime converter for JSON serialization.
Inheritance
System.Object
System.Text.Json.Serialization.JsonConverter
System.Text.Json.Serialization.JsonConverter<System.DateTime>
DateTimeJsonConverter
Inherited Members
System.Text.Json.Serialization.JsonConverter<System.DateTime>.CanConvert(System.Type)
System.Text.Json.Serialization.JsonConverter<System.DateTime>.HandleNull
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Redis.OM.Modeling
Assembly: Redis.OM.dll
Syntax
public class DateTimeJsonConverter : JsonConverter<DateTime>
Methods
| Improve this Doc View SourceRead(ref Utf8JsonReader, Type, JsonSerializerOptions)
Declaration
public override DateTime Read(ref Utf8JsonReader reader, Type typeToConvert, JsonSerializerOptions options)
Parameters
Type | Name | Description |
---|---|---|
System.Text.Json.Utf8JsonReader | reader | |
System.Type | typeToConvert | |
System.Text.Json.JsonSerializerOptions | options |
Returns
Type | Description |
---|---|
System.DateTime |
Overrides
System.Text.Json.Serialization.JsonConverter<System.DateTime>.Read(System.Text.Json.Utf8JsonReader, System.Type, System.Text.Json.JsonSerializerOptions)
|
Improve this Doc
View Source
Write(Utf8JsonWriter, DateTime, JsonSerializerOptions)
Declaration
public override void Write(Utf8JsonWriter writer, DateTime value, JsonSerializerOptions options)
Parameters
Type | Name | Description |
---|---|---|
System.Text.Json.Utf8JsonWriter | writer | |
System.DateTime | value | |
System.Text.Json.JsonSerializerOptions | options |
Overrides
System.Text.Json.Serialization.JsonConverter<System.DateTime>.Write(System.Text.Json.Utf8JsonWriter, System.DateTime, System.Text.Json.JsonSerializerOptions)