Class KeyDataStore | Package Manager UI website
docs.unity3d.com
    Show / Hide Table of Contents

    Class KeyDataStore

    Inheritance
    System.Object
    KeyDataStore
    Namespace: UnityEditor.AddressableAssets
    Syntax
    public class KeyDataStore : ISerializationCallbackReceiver

    Properties

    Keys

    Declaration
    public IEnumerable<string> Keys { get; }
    Property Value
    Type Description
    System.Collections.Generic.IEnumerable<System.String>

    OnSetData

    Declaration
    public Action<string, object, bool> OnSetData { get; set; }
    Property Value
    Type Description
    Action<System.String, System.Object, System.Boolean>

    Methods

    GetData<T>(String, T, Boolean)

    Declaration
    public T GetData<T>(string key, T defaultValue, bool addDefault = false)
    Parameters
    Type Name Description
    System.String key
    T defaultValue
    System.Boolean addDefault
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    GetDataString(String, String)

    Declaration
    public string GetDataString(string key, string defaultValue)
    Parameters
    Type Name Description
    System.String key
    System.String defaultValue
    Returns
    Type Description
    System.String

    GetDataType(String)

    Declaration
    public Type GetDataType(string key)
    Parameters
    Type Name Description
    System.String key
    Returns
    Type Description
    Type

    OnAfterDeserialize()

    Declaration
    public void OnAfterDeserialize()

    OnBeforeSerialize()

    Declaration
    public void OnBeforeSerialize()

    SetData(String, Object)

    Declaration
    public void SetData(string key, object data)
    Parameters
    Type Name Description
    System.String key
    System.Object data

    SetDataFromString(String, String)

    Declaration
    public void SetDataFromString(string key, string data)
    Parameters
    Type Name Description
    System.String key
    System.String data
    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023