# AsReadOnlySpan()

> Returns ReadOnlySpan\<T\> view of this container.

## Definition

* **Type:** Method
* **Namespace:** [Unity.Collections](/engine/6000.7/script-reference/unity/collections.md)
* **Assembly:** UnityEngine.ManagedKernelModule

```csharp
public readonly ReadOnlySpan<T> AsReadOnlySpan()
```

### Returns

| Type                                                                             | Description                                  |
| -------------------------------------------------------------------------------- | -------------------------------------------- |
| [ReadOnlySpan\<T>](https://learn.microsoft.com/dotnet/api/system.readonlyspan-1) | ReadOnlySpan\\\<T\\> view of this container. |
