{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Method SetDataForKey | AR Subsystems | 4.2.9
docs.unity.cn
Search Results for

    Show / Hide Table of Contents

    Method SetDataForKey

    SetDataForKey(XRReferenceImageLibrary, string, byte[])

    Associate binary data with a string key.

    Declaration
    public static void SetDataForKey(this XRReferenceImageLibrary library, string key, byte[] data)
    Parameters
    Type Name Description
    XRReferenceImageLibrary library

    The XRReferenceImageLibrary being extended.

    string key

    The key which can be used to later retrieve data.

    byte[] data

    The data to associate with key.

    Remarks

    Providers use this to associate provider-specific data with the library. During Player Build (in an IPreprocessBuildWithReport.OnPreprocessBuild callback), the data store is first cleared. Each enabled provider then has an opportunity to add one or more entries for itself.

    Providers can use this to store a serialized version of the image library specific to that provider. Retrieve data with dataStore.

    Exceptions
    Type Condition
    ArgumentNullException

    Thrown if key is null.

    In This Article
    Back to top
    Copyright © 2023 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)