# BlobArray<T>

> An immutable array of value types stored in a blob asset.

## Definition

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

```csharp
public struct BlobArray<T> where T : struct
```

## Remarks

When creating a blob asset, use the [BlobBuilderArray\<T>](/engine/7000.0/script-reference/unity/entities/blobbuilderarray1.md) provided by a [BlobBuilder](/engine/7000.0/script-reference/unity/entities/blobbuilder.md) instance to set the array elements.

Additional Resources: [BlobBuilder](/engine/7000.0/script-reference/unity/entities/blobbuilder.md)

## Properties

| Property                                                                      | Description                                       |
| ----------------------------------------------------------------------------- | ------------------------------------------------- |
| [this\[\]](/engine/7000.0/script-reference/unity/entities/blobarray1/item.md) | The element of the array at the `index` position. |
| [Length](/engine/7000.0/script-reference/unity/entities/blobarray1/length.md) | The number of elements in the array.              |

## Methods

| Method                                                                                    | Description                                                   |
| ----------------------------------------------------------------------------------------- | ------------------------------------------------------------- |
| [AsSpan](/engine/7000.0/script-reference/unity/entities/blobarray1/asspan.md)             | Returns a ReadOnlySpan\_1 view of the blob array data.        |
| [GetUnsafePtr](/engine/7000.0/script-reference/unity/entities/blobarray1/getunsafeptr.md) | Provides an unsafe pointer to the array data.                 |
| [ToArray](/engine/7000.0/script-reference/unity/entities/blobarray1/toarray.md)           | Copies the elements of this BlobArray to a new managed array. |
