SimpleVersion
Search Results for

    Show / Hide Table of Contents

    Class DictionaryConverter<TKey, TValue>

    Enables reading/writing a dictionary as JSON. Implemented to support reading/writing non-standard keys.

    Inheritance
    System.Object
    System.Text.Json.Serialization.JsonConverter
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>
    DictionaryConverter<TKey, TValue>
    Inherited Members
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.CanConvert(System.Type)
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.Read(System.Text.Json.Utf8JsonReader, System.Type, System.Text.Json.JsonSerializerOptions)
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.ReadAsPropertyName(System.Text.Json.Utf8JsonReader, System.Type, System.Text.Json.JsonSerializerOptions)
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.Write(System.Text.Json.Utf8JsonWriter, System.Collections.Generic.Dictionary<TKey, TValue>, System.Text.Json.JsonSerializerOptions)
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.WriteAsPropertyName(System.Text.Json.Utf8JsonWriter, System.Collections.Generic.Dictionary<TKey, TValue>, System.Text.Json.JsonSerializerOptions)
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.HandleNull
    System.Text.Json.Serialization.JsonConverter.CanConvert(System.Type)
    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: SimpleVersion.Serialization.Converters
    Assembly: SimpleVersion.Core.dll
    Syntax
    public class DictionaryConverter<TKey, TValue> : JsonConverter<Dictionary<TKey, TValue>>
    Type Parameters
    Name Description
    TKey

    The type of the key.

    TValue

    The value type.

    Methods

    | Improve this Doc View Source

    Read(ref Utf8JsonReader, Type, JsonSerializerOptions)

    Declaration
    public override Dictionary<TKey, TValue> 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.Collections.Generic.Dictionary<TKey, TValue>
    Overrides
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.Read(System.Text.Json.Utf8JsonReader, System.Type, System.Text.Json.JsonSerializerOptions)
    | Improve this Doc View Source

    Write(Utf8JsonWriter, Dictionary<TKey, TValue>, JsonSerializerOptions)

    Declaration
    public override void Write(Utf8JsonWriter writer, Dictionary<TKey, TValue> value, JsonSerializerOptions options)
    Parameters
    Type Name Description
    System.Text.Json.Utf8JsonWriter writer
    System.Collections.Generic.Dictionary<TKey, TValue> value
    System.Text.Json.JsonSerializerOptions options
    Overrides
    System.Text.Json.Serialization.JsonConverter<System.Collections.Generic.Dictionary<TKey, TValue>>.Write(System.Text.Json.Utf8JsonWriter, System.Collections.Generic.Dictionary<TKey, TValue>, System.Text.Json.JsonSerializerOptions)

    Extension Methods

    TokenRuleExtensions.ResolveTokenRules<T>(T, IVersionContext, IEnumerable<ITokenRule<T>>)
    • Improve this Doc
    • View Source
    In This Article
    Back to top Generated by DocFX