# SetAllocator

> Set the allocator that command buffers created with this singleton should be allocated with.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Entities](/engine/7000.0/script-reference/unity/entities.md)
* **Assembly:** UnityEngine.EntitiesModule

## SetAllocator(Allocator)

Set the allocator that command buffers created with this singleton should be allocated with.

```csharp
public void SetAllocator(Allocator allocatorIn)
```

### Parameters

**** (\[Allocator]\(/engine/7000.0/script-reference/unity/collections/allocator)): The allocator to use

## SetAllocator(AllocatorHandle)

Set the allocator that command buffers created with this singleton should be allocated with.

```csharp
public void SetAllocator(AllocatorManager.AllocatorHandle allocatorIn)
```

### Parameters

**** (\[AllocatorHandle]\(/engine/7000.0/script-reference/unity/collections/allocatormanager/allocatorhandle)): The allocator to use
