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

    Show / Hide Table of Contents

    Method CopyStringToPayloadBuffer

    CopyStringToPayloadBuffer(string, ref LogMemoryManager, bool, bool, bool)

    Allocates memory in the LogMemoryManager and copies data into it with headers.

    Declaration
    public static PayloadHandle CopyStringToPayloadBuffer(string source, ref LogMemoryManager memAllocator, bool prependTypeId = false, bool prependLength = false, bool deferredRelease = false)
    Parameters
    Type Name Description
    string source

    String that stores the data in UTF16

    LogMemoryManager memAllocator

    MemoryManager where to allocate the PayloadHandle

    bool prependTypeId

    If true - typeId will be added to payload

    bool prependLength

    If true - length in bytes will be added to payload

    bool deferredRelease

    If true - PayloadHandle will be registered for deferred release (after 2 updates)

    Returns
    Type Description
    PayloadHandle

    PayloadHandle that holds the data

    Remarks

    Create a copy of string message in UTF8 in PayloadBuffer, prepended with optional typeId and length. When CopyStringToPayloadBuffer is called in the Burst code, CopyStringToPayloadBuffer__Unmanaged is called instead

    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)