docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method DeserializeListsToDictionary

    DeserializeListsToDictionary<TKey, TValue>(List<TKey>, List<TValue>, Dictionary<TKey, TValue>)

    Deserialize the given lists into the given dictionary.

    Declaration
    protected static void DeserializeListsToDictionary<TKey, TValue>(List<TKey> keys, List<TValue> values, Dictionary<TKey, TValue> container)
    Parameters
    Type Name Description
    List<TKey> keys

    A list of keys. It is cleared after the dictionary has been filled.

    List<TValue> values

    A list of values. It is cleared after the dictionary has been filled.

    Dictionary<TKey, TValue> container

    The dictionary that will be filled with serialized data. It is cleared even if the given lists are empty.

    Type Parameters
    Name Description
    TKey
    TValue
    Exceptions
    Type Condition
    ArgumentNullException

    Thrown if any of the argument is null.

    SerializationException

    Thrown if the given lists have a different item count.

    In This Article
    Back to top
    Copyright © 2024 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)