Namespace Unity.Collections | Collections | 0.14.0-preview.16
docs.unity3d.com
    Show / Hide Table of Contents

    Namespace Unity.Collections

    Classes

    AllocatorManager

    BurstCompatibleAttribute

    Documents and enforces (via generated tests) that the tagged method or property has to stay burst compatible.

    CollectionHelper

    FixedList128Extensions

    FixedList32Extensions

    FixedList4096Extensions

    FixedList512Extensions

    FixedList64Extensions

    FixedListExtensions

    FixedString

    FixedStringMethods

    ListExtensions

    List extensions.

    NativeArrayExtensions

    NativeArray extension methods.

    NativeHashMapExtensions

    NativeHashMap extensions.

    NativeSortExtension

    Extension methods for sorting various containers.

    NotBurstCompatibleAttribute

    Internal attribute to state that a method is not burst compatible even though the containing type is.

    UTF8ArrayUnsafeUtility

    WordStorage

    xxHash3

    A feature complete hashing API based on xxHash3 (https://github.com/Cyan4973/xxHash)

    Structs

    AllocatorManager.AllocatorHandle

    Which allocator a Block's Range allocates from.

    AllocatorManager.AllocatorInstallation<T>

    Mapping between a Block, AllocatorHandle, and an IAllocator.

    AllocatorManager.Block

    A block of memory with a Range and metadata for size in bytes of each item in the block, number of allocated items, and alignment.

    AllocatorManager.BlockHandle

    AllocatorManager.Range

    Pointer for the beginning of a block of memory, number of items in it, which allocator it belongs to, and which block this is.

    AllocatorManager.SmallAllocatorHandle

    BitField32

    Fixed size 32-bit array of bits.

    BitField64

    Fixed size 64-bit array of bits.

    Bytes1

    Bytes126

    Bytes16

    Bytes30

    Bytes4094

    Bytes510

    Bytes62

    FixedList128<T>

    An unmanaged, resizable list that does not allocate memory. It is 128 bytes in size, and contains all the memory it needs.

    FixedList128<T>.Enumerator

    FixedList32<T>

    An unmanaged, resizable list that does not allocate memory. It is 32 bytes in size, and contains all the memory it needs.

    FixedList32<T>.Enumerator

    FixedList4096<T>

    An unmanaged, resizable list that does not allocate memory. It is 4096 bytes in size, and contains all the memory it needs.

    FixedList4096<T>.Enumerator

    FixedList512<T>

    An unmanaged, resizable list that does not allocate memory. It is 512 bytes in size, and contains all the memory it needs.

    FixedList512<T>.Enumerator

    FixedList64<T>

    An unmanaged, resizable list that does not allocate memory. It is 64 bytes in size, and contains all the memory it needs.

    FixedList64<T>.Enumerator

    FixedListByte128

    An unmanaged, resizable list of byte that does not allocate memory. It is 128 bytes in size, and contains all the memory it needs.

    FixedListByte128.Enumerator

    FixedListByte32

    An unmanaged, resizable list of byte that does not allocate memory. It is 32 bytes in size, and contains all the memory it needs.

    FixedListByte32.Enumerator

    FixedListByte4096

    An unmanaged, resizable list of byte that does not allocate memory. It is 4096 bytes in size, and contains all the memory it needs.

    FixedListByte4096.Enumerator

    FixedListByte512

    An unmanaged, resizable list of byte that does not allocate memory. It is 512 bytes in size, and contains all the memory it needs.

    FixedListByte512.Enumerator

    FixedListByte64

    An unmanaged, resizable list of byte that does not allocate memory. It is 64 bytes in size, and contains all the memory it needs.

    FixedListByte64.Enumerator

    FixedListFloat128

    An unmanaged, resizable list of float that does not allocate memory. It is 128 bytes in size, and contains all the memory it needs.

    FixedListFloat128.Enumerator

    FixedListFloat32

    An unmanaged, resizable list of float that does not allocate memory. It is 32 bytes in size, and contains all the memory it needs.

    FixedListFloat32.Enumerator

    FixedListFloat4096

    An unmanaged, resizable list of float that does not allocate memory. It is 4096 bytes in size, and contains all the memory it needs.

    FixedListFloat4096.Enumerator

    FixedListFloat512

    An unmanaged, resizable list of float that does not allocate memory. It is 512 bytes in size, and contains all the memory it needs.

    FixedListFloat512.Enumerator

    FixedListFloat64

    An unmanaged, resizable list of float that does not allocate memory. It is 64 bytes in size, and contains all the memory it needs.

    FixedListFloat64.Enumerator

    FixedListInt128

    An unmanaged, resizable list of int that does not allocate memory. It is 128 bytes in size, and contains all the memory it needs.

    FixedListInt128.Enumerator

    FixedListInt32

    An unmanaged, resizable list of int that does not allocate memory. It is 32 bytes in size, and contains all the memory it needs.

    FixedListInt32.Enumerator

    FixedListInt4096

    An unmanaged, resizable list of int that does not allocate memory. It is 4096 bytes in size, and contains all the memory it needs.

    FixedListInt4096.Enumerator

    FixedListInt512

    An unmanaged, resizable list of int that does not allocate memory. It is 512 bytes in size, and contains all the memory it needs.

    FixedListInt512.Enumerator

    FixedListInt64

    An unmanaged, resizable list of int that does not allocate memory. It is 64 bytes in size, and contains all the memory it needs.

    FixedListInt64.Enumerator

    FixedString128

    An unmanaged string in UTF-8 format that contains its own fixed-size buffer of the given size in bytes. The string is guaranteed to be null-terminated, at the byte at the current Length offset. No memory is ever allocated, and no attempt is made to share memory when strings are copied. Since this structure is not generic and needs no disposing, it can exist inside ECS components, can be put in a FixedArray, FixedList or FixedHashMap, and can be a data member of unmanaged structs that are allocated from the unmanaged heap. This string is entirely compatible with Burst compilation.

    The binary layout of this string is guaranteed, for now and all time, to be two bytes of little-endian length, followed by a contiguous array of bytes with that length, with no padding in between. This is intentionally identical to FixedList of byte, which is guaranteed to always have the same memory layout.

    Those who need more than 65,535 contiguous items should allocate from the heap, as storing that many things contiguously in a C# struct is likely to result in much wasted time, as the compiler copies the struct often.

    FixedString128.Enumerator

    FixedString32

    An unmanaged string in UTF-8 format that contains its own fixed-size buffer of the given size in bytes. The string is guaranteed to be null-terminated, at the byte at the current Length offset. No memory is ever allocated, and no attempt is made to share memory when strings are copied. Since this structure is not generic and needs no disposing, it can exist inside ECS components, can be put in a FixedArray, FixedList or FixedHashMap, and can be a data member of unmanaged structs that are allocated from the unmanaged heap. This string is entirely compatible with Burst compilation.

    The binary layout of this string is guaranteed, for now and all time, to be two bytes of little-endian length, followed by a contiguous array of bytes with that length, with no padding in between. This is intentionally identical to FixedList of byte, which is guaranteed to always have the same memory layout.

    Those who need more than 65,535 contiguous items should allocate from the heap, as storing that many things contiguously in a C# struct is likely to result in much wasted time, as the compiler copies the struct often.

    FixedString32.Enumerator

    FixedString4096

    An unmanaged string in UTF-8 format that contains its own fixed-size buffer of the given size in bytes. The string is guaranteed to be null-terminated, at the byte at the current Length offset. No memory is ever allocated, and no attempt is made to share memory when strings are copied. Since this structure is not generic and needs no disposing, it can exist inside ECS components, can be put in a FixedArray, FixedList or FixedHashMap, and can be a data member of unmanaged structs that are allocated from the unmanaged heap. This string is entirely compatible with Burst compilation.

    The binary layout of this string is guaranteed, for now and all time, to be two bytes of little-endian length, followed by a contiguous array of bytes with that length, with no padding in between. This is intentionally identical to FixedList of byte, which is guaranteed to always have the same memory layout.

    Those who need more than 65,535 contiguous items should allocate from the heap, as storing that many things contiguously in a C# struct is likely to result in much wasted time, as the compiler copies the struct often.

    FixedString4096.Enumerator

    FixedString512

    An unmanaged string in UTF-8 format that contains its own fixed-size buffer of the given size in bytes. The string is guaranteed to be null-terminated, at the byte at the current Length offset. No memory is ever allocated, and no attempt is made to share memory when strings are copied. Since this structure is not generic and needs no disposing, it can exist inside ECS components, can be put in a FixedArray, FixedList or FixedHashMap, and can be a data member of unmanaged structs that are allocated from the unmanaged heap. This string is entirely compatible with Burst compilation.

    The binary layout of this string is guaranteed, for now and all time, to be two bytes of little-endian length, followed by a contiguous array of bytes with that length, with no padding in between. This is intentionally identical to FixedList of byte, which is guaranteed to always have the same memory layout.

    Those who need more than 65,535 contiguous items should allocate from the heap, as storing that many things contiguously in a C# struct is likely to result in much wasted time, as the compiler copies the struct often.

    FixedString512.Enumerator

    FixedString64

    An unmanaged string in UTF-8 format that contains its own fixed-size buffer of the given size in bytes. The string is guaranteed to be null-terminated, at the byte at the current Length offset. No memory is ever allocated, and no attempt is made to share memory when strings are copied. Since this structure is not generic and needs no disposing, it can exist inside ECS components, can be put in a FixedArray, FixedList or FixedHashMap, and can be a data member of unmanaged structs that are allocated from the unmanaged heap. This string is entirely compatible with Burst compilation.

    The binary layout of this string is guaranteed, for now and all time, to be two bytes of little-endian length, followed by a contiguous array of bytes with that length, with no padding in between. This is intentionally identical to FixedList of byte, which is guaranteed to always have the same memory layout.

    Those who need more than 65,535 contiguous items should allocate from the heap, as storing that many things contiguously in a C# struct is likely to result in much wasted time, as the compiler copies the struct often.

    FixedString64.Enumerator

    HeapString

    An unmanaged string in UTF-8 format that maintains a variable-length allocated inner buffer. The string is guaranteed to be null-terminated, at the byte at the current Length offset. This structure is a native collection, and as such requires creating with an allocator and requires being disposed.

    HeapString.Enumerator

    NativeBitArray

    Arbitrary sized array of bits.

    NativeHashMap<TKey, TValue>

    Unordered associative array, a collection of keys and values.

    NativeHashMap<TKey, TValue>.Enumerator

    Implements iterator over the container.

    NativeHashMap<TKey, TValue>.ParallelWriter

    Implements parallel writer. Use AsParallelWriter to obtain it from container.

    NativeHashSet<T>

    Set of values.

    NativeHashSet<T>.Enumerator

    Implements iterator over the container.

    NativeHashSet<T>.ParallelWriter

    Implements parallel writer. Use AsParallelWriter to obtain it from container.

    NativeKeyValueArrays<TKey, TValue>

    Key value arrays.

    NativeList<T>

    An unmanaged, resizable list.

    NativeList<T>.ParallelWriter

    Implements parallel writer. Use AsParallelWriter to obtain it from container.

    NativeMultiHashMap<TKey, TValue>

    Unordered associative array, a collection of keys and values. This container can store multiple values for every key.

    NativeMultiHashMap<TKey, TValue>.Enumerator

    Implements iterator over the container.

    NativeMultiHashMap<TKey, TValue>.KeyValueEnumerator

    Implements iterator over the container.

    NativeMultiHashMap<TKey, TValue>.ParallelWriter

    Implements parallel writer. Use AsParallelWriter to obtain it from container.

    NativeMultiHashMapIterator<TKey>

    Iterator.

    NativeQueue<T>

    An unmanaged queue.

    NativeQueue<T>.ParallelWriter

    Implements parallel writer. Use AsParallelWriter to obtain it from container.

    NativeReference<T>

    An unmanaged, reference container.

    NativeReference<T>.ReadOnly

    An unmanaged, read-only reference container.

    NativeStream

    A deterministic data streaming supporting parallel reading and parallel writing. Allows you to write different types or arrays into a single stream.

    NativeStream.Reader

    NativeStream.Writer

    NativeStringView

    NumberedWords

    Unicode

    Unicode.Rune

    Words

    xxHash3.StreamingState

    Type used to compute hash based on multiple data feed

    Interfaces

    AllocatorManager.IAllocator

    An allocator with a tryable allocate/free/realloc function pointer.

    INativeDisposable

    INativeDisposable provides a mechanism for scheduling release of unmanaged resources.

    INativeList<T>

    IUTF8Bytes

    Interface marking this type as a run of UTF-8 encoded text.

    Enums

    ConversionError

    CopyError

    FormatError

    ParseError

    Delegates

    AllocatorManager.TryFunction

    Delegate used for calling an allocator's allocation function.

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023