Struct NativeStream.Writer | Collections | 0.5.2-preview.8
docs.unity.cn
    Show / Hide Table of Contents

    Struct NativeStream.Writer

    Namespace: Unity.Collections
    Syntax
    public struct Writer

    Properties

    ForEachCount

    Declaration
    public int ForEachCount { get; }
    Property Value
    Type Description
    Int32

    Methods

    Allocate(Int32)

    Allocate space for data.

    Declaration
    public byte *Allocate(int size)
    Parameters
    Type Name Description
    Int32 size

    Size in bytes.

    Returns
    Type Description
    Byte*

    Allocate<T>()

    Allocate space for data.

    Declaration
    public T Allocate<T>()
        where T : struct
    Returns
    Type Description
    T
    Type Parameters
    Name Description
    T

    The type of value.

    BeginForEachIndex(Int32)

    Begin reading data at the iteration index.

    Declaration
    public void BeginForEachIndex(int foreachIndex)
    Parameters
    Type Name Description
    Int32 foreachIndex
    Remarks

    BeginForEachIndex must always be called balanced by a EndForEachIndex.

    EndForEachIndex()

    Ensures that all data has been read for the active iteration index.

    Declaration
    public void EndForEachIndex()
    Remarks

    EndForEachIndex must always be called balanced by a BeginForEachIndex.

    PatchMinMaxRange(Int32)

    Declaration
    public void PatchMinMaxRange(int foreEachIndex)
    Parameters
    Type Name Description
    Int32 foreEachIndex

    Write<T>(T)

    Write data.

    Declaration
    public void Write<T>(T value)
        where T : struct
    Parameters
    Type Name Description
    T value
    Type Parameters
    Name Description
    T

    The type of value.

    Extension Methods

    JobNativeMultiHashMapVisitKeyValue.Schedule<TJob, TKey, TValue>(TJob, NativeMultiHashMap<TKey, TValue>, Int32, JobHandle)
    JobNativeMultiHashMapVisitKeyMutableValue.Schedule<TJob, TKey, TValue>(TJob, NativeMultiHashMap<TKey, TValue>, Int32, JobHandle)
    JobUnsafeMultiHashMapVisitKeyValue.Schedule<TJob, TKey, TValue>(TJob, UnsafeMultiHashMap<TKey, TValue>, Int32, JobHandle)
    JobUnsafeMultiHashMapVisitKeyMutableValue.Schedule<TJob, TKey, TValue>(TJob, UnsafeMultiHashMap<TKey, TValue>, Int32, JobHandle)
    Back to top Copyright © 2020 Unity Technologies
    Generated by DocFX