Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


Dispose(ref AtomicSafetyHandle, ref DisposeSentinel)

Releases the AtomicSafetyHandle and clears the DisposeSentinel.
Read time 1 minuteLast updated 18 days ago

Definition

Dispose(AtomicSafetyHandle, DisposeSentinel)

public static void Dispose(ref AtomicSafetyHandle safety, ref DisposeSentinel sentinel)

Parameters

The
AtomicSafetyHandle
returned when invoking the Create method.

The
DisposeSentinel
to clear.

Remarks

If the
AtomicSafetyHandle
can't be released, which usually happens either because a job is accessing the data or because the handle has already been released, an exception is thrown.