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

    Show / Hide Table of Contents

    Method AllocatePayload

    AllocatePayload(uint, out PayloadHandle, out NativeArray<byte>, bool)

    Allocate a block of memory from the container.

    Declaration
    public bool AllocatePayload(uint requestedSize, out PayloadHandle payloadHandle, out NativeArray<byte> payloadArray, bool disjointedBuffer = false)
    Parameters
    Type Name Description
    uint requestedSize

    Size of memory block in bytes to allocate.

    PayloadHandle payloadHandle

    Handle to the memory block, if allocation was successful.

    NativeArray<byte> payloadArray

    NativeArray allowing read/write access into the memory block.

    bool disjointedBuffer

    True to specify allocation is the "head" of a Disjointed Payload.

    Returns
    Type Description
    bool

    True if allocation was successful and false if not

    Remarks

    Actual size of the allocation is slightly larger than requestedSize, as additional bytes are needed for the memory block's header.

    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)