Interface IIndexable<T>
An indexable collection.
Namespace: Unity.Collections
Syntax
public interface IIndexable<T>
where T : struct
Type Parameters
Name | Description |
---|---|
T | The type of the elements in the collection. |
Properties
Length
The current number of elements in the collection.
Declaration
int Length { get; set; }
Property Value
Type | Description |
---|---|
Int32 | The current number of elements in the collection. |
Methods
ElementAt(Int32)
Returns a reference to the element at a given index.
Declaration
ref T ElementAt(int index)
Parameters
Type | Name | Description |
---|---|---|
Int32 | index | The index to access. Must be in the range of [0..Length). |
Returns
Type | Description |
---|---|
T | A reference to the element at the index. |