public static void Copy(NativeArray <T> .ReadOnly src, T[] dst) { AtomicSafetyHandle.CheckReadAndThrow(src.m_Safety); NativeArray <T> .CheckCopyLengths(src.Length, dst.Length); NativeArray <T> .Copy(src, 0, dst, 0, src.Length); }
public static void Copy(T[] src, NativeArray <T> dst) { AtomicSafetyHandle.CheckWriteAndThrow(dst.m_Safety); NativeArray <T> .CheckCopyLengths(src.Length, dst.Length); NativeArray <T> .Copy(src, 0, dst, 0, src.Length); }
public T[] ToArray() { T[] array = new T[this.Length]; NativeArray <T> .Copy(this, array, this.Length); return(array); }
public NativeArray(NativeArray <T> array, Allocator allocator) { AtomicSafetyHandle.CheckReadAndThrow(array.m_Safety); NativeArray <T> .Allocate(array.Length, allocator, out this); NativeArray <T> .Copy(array, 0, this, 0, array.Length); }
public NativeArray(T[] array, Allocator allocator) { bool flag = array == null; if (flag) { throw new ArgumentNullException("array"); } NativeArray <T> .Allocate(array.Length, allocator, out this); NativeArray <T> .Copy(array, this); }
public void CopyTo(NativeArray <T> array) { NativeArray <T> .Copy(this, array); }
public static void Copy(NativeArray <T> .ReadOnly src, T[] dst, int length) { NativeArray <T> .Copy(src, 0, dst, 0, length); }
public static void Copy(T[] src, NativeArray <T> dst, int length) { NativeArray <T> .Copy(src, 0, dst, 0, length); }
public void CopyFrom(NativeArray <T> array) { NativeArray <T> .Copy(array, this); }