# NativeQueue<T>.ReadOnly

> A read-only alias for the value of a NativeQueue. Does not have its own allocated storage.

## Definition

* **Type:** Struct
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule
* **Implements:** [IEnumerable\<T>](https://learn.microsoft.com/dotnet/api/system.collections.generic.ienumerable-1), [IEnumerable](https://learn.microsoft.com/dotnet/api/system.collections.ienumerable)

```csharp
public struct NativeQueue<T>.ReadOnly : IEnumerable<T>, IEnumerable
```

## Properties

| Property                                                                                          | Description                                                      |
| ------------------------------------------------------------------------------------------------- | ---------------------------------------------------------------- |
| [Count](/engine/6000.7/script-reference/unity/collections/nativequeue1/readonly/count.md)         | Returns the current number of elements in this queue.            |
| [IsCreated](/engine/6000.7/script-reference/unity/collections/nativequeue1/readonly/iscreated.md) | Whether this container been allocated (and not yet deallocated). |
| [this\[\]](/engine/6000.7/script-reference/unity/collections/nativequeue1/readonly/item.md)       | The element at an index.                                         |

## Methods

| Method                                                                                                    | Description                                             |
| --------------------------------------------------------------------------------------------------------- | ------------------------------------------------------- |
| [GetEnumerator](/engine/6000.7/script-reference/unity/collections/nativequeue1/readonly/getenumerator.md) | Returns an enumerator over the items of this container. |
| [IsEmpty](/engine/6000.7/script-reference/unity/collections/nativequeue1/readonly/isempty.md)             | Returns true if this queue is empty.                    |
