Method ToNativeArray
ToNativeArray<T>(List<T>, AllocatorHandle)
Returns an array that is a copy of this list.
Declaration
public static NativeArray<T> ToNativeArray<T>(this List<T> list, AllocatorManager.AllocatorHandle allocator) where T : unmanaged
Parameters
Type | Name | Description |
---|---|---|
List<T> | list | The list to copy. |
AllocatorManager.AllocatorHandle | allocator | The allocator to use. |
Returns
Type | Description |
---|---|
NativeArray<T> | An array that is a copy of this list. |
Type Parameters
Name | Description |
---|---|
T | The type of elements in the list. |