{!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 RetrievePayloadFromHandle | Unity Logging | 1.1.0-pre.3
docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Method RetrievePayloadFromHandle

    RetrievePayloadFromHandle(PayloadHandle, out NativeArray<byte>)

    Retrieves a NativeArray for the allocated memory block referenced by the specified handle.

    Declaration
    public bool RetrievePayloadFromHandle(PayloadHandle blockHandle, out NativeArray<byte> blockArray)
    Parameters
    Type Name Description
    PayloadHandle blockHandle

    Valid handle to the memory block to retrieve.

    NativeArray<byte> blockArray

    If successful, NativeArray as a view into the memory block.

    Returns
    Type Description
    bool

    True if successfully retrieved memory block and false if not.

    Remarks

    NativeArray is read-only. See RetrievePayloadFromHandle(PayloadHandle, bool, out NativeArray<byte>).

    RetrievePayloadFromHandle(PayloadHandle, bool, out NativeArray<byte>)

    Retrieves a NativeArray for the allocated memory block referenced by the specified handle.

    Declaration
    public bool RetrievePayloadFromHandle(PayloadHandle blockHandle, bool readWriteAccess, out NativeArray<byte> blockArray)
    Parameters
    Type Name Description
    PayloadHandle blockHandle

    Valid handle to the memory block to retrieve.

    bool readWriteAccess

    True to give read-write access to the NativeArray and false for read-only access.

    NativeArray<byte> blockArray

    If successful, NativeArray as a view into the memory block.

    Returns
    Type Description
    bool

    True if successfully retrieved memory block and false if not.

    Remarks

    The returned NativeArray is a view into the allocated memory block and not a copy, allows for safe access to them memory block. Access to the NativeArray can be specified as either read-only or read-write.

    NOTE: Since the NativeArray is a view into a segment of native memory, a buffer overrun will corrupt the container causing undefined behavior.

    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)