Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


Equals

Compares two NativeArray<T> instances.
Read time 1 minuteLast updated 6 days ago

Definition

Equals(NativeArray<T>)

Compares two NativeArray<T> instances.
public bool Equals(NativeArray<T> other)

Parameters

The NativeArray to compare against.

Returns

Type

Description

boolTrue if the two NativeArray instances are the same, false otherwise.

Remarks

Two NativeArray<T> instances are considered the same if they point to the same underlying memory buffer, and have the same length.

Equals(Object)

Compares a NativeArray<T> instance and an object.
public override bool Equals(object obj)

Parameters

The object to compare against.

Returns

Type

Description

boolTrue if the NativeArray and the object are the same, false otherwise.

Remarks

A NativeArray and an object are considered the same if they point to the same underlying memory buffer, and have the same length.