# Allocator

> Sets which allocation type to use for a NativeArray.

## Definition

* **Type:** Enum
* **Namespace:** [Unity.Collections](/engine/6000.0/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.CoreModule

```csharp
public enum Allocator
```

## Fields

| Value                                                                                           | Description                                                 |
| ----------------------------------------------------------------------------------------------- | ----------------------------------------------------------- |
| [AudioKernel](/engine/6000.0/script-reference/unity/collections/allocator/audiokernel.md)       | Use an allocation associated with a DSPGraph audio kernel.  |
| [Domain](/engine/6000.0/script-reference/unity/collections/allocator/domain.md)                 | Use an allocation associated with the lifetime of a domain. |
| [FirstUserIndex](/engine/6000.0/script-reference/unity/collections/allocator/firstuserindex.md) | The first index that a custom allocator can get.            |
| [Invalid](/engine/6000.0/script-reference/unity/collections/allocator/invalid.md)               | Use an invalid allocation.                                  |
| [None](/engine/6000.0/script-reference/unity/collections/allocator/none.md)                     | Use no allocation.                                          |
| [Persistent](/engine/6000.0/script-reference/unity/collections/allocator/persistent.md)         | Use a persistent allocation.                                |
| [Temp](/engine/6000.0/script-reference/unity/collections/allocator/temp.md)                     | Use a temporary allocation.                                 |
| [TempJob](/engine/6000.0/script-reference/unity/collections/allocator/tempjob.md)               | Use a temporary job allocation.                             |
