Class SparseMap<T>
Assembly: LiteEntitySystem.dll
Syntax
public class SparseMap<T>
Type Parameters
Constructors
SparseMap()
Declaration
SparseMap(int)
Declaration
public SparseMap(int capacity)
Parameters
Type |
Name |
Description |
int |
capacity |
|
Properties
Count
Declaration
public int Count { get; }
Property Value
Methods
Clear()
Declaration
Contains(int)
Declaration
public bool Contains(int id)
Parameters
Type |
Name |
Description |
int |
id |
|
Returns
CopyTo(SparseMap<T>)
Declaration
public void CopyTo(SparseMap<T> target)
Parameters
FindIndex(int)
Declaration
public int FindIndex(int id)
Parameters
Type |
Name |
Description |
int |
id |
|
Returns
GetById(int)
Declaration
public ref T GetById(int id)
Parameters
Type |
Name |
Description |
int |
id |
|
Returns
GetByIndex(int)
Declaration
public ref T GetByIndex(int index)
Parameters
Type |
Name |
Description |
int |
index |
|
Returns
GetSparseEntryByIndex(int)
Declaration
public ref readonly SparseMap<T>.SparseEntry GetSparseEntryByIndex(int index)
Parameters
Type |
Name |
Description |
int |
index |
|
Returns
Remove(int)
Declaration
public bool Remove(int id)
Parameters
Type |
Name |
Description |
int |
id |
|
Returns
Remove(int, out T)
Declaration
public bool Remove(int id, out T removedElement)
Parameters
Type |
Name |
Description |
int |
id |
|
T |
removedElement |
|
Returns
Set(int, T)
Declaration
public void Set(int id, T value)
Parameters
Type |
Name |
Description |
int |
id |
|
T |
value |
|
TryGetSparseEntry(int, out SparseEntry)
Declaration
public bool TryGetSparseEntry(int id, out SparseMap<T>.SparseEntry result)
Parameters
Returns
TryGetValue(int, out T)
Declaration
public bool TryGetValue(int id, out T result)
Parameters
Type |
Name |
Description |
int |
id |
|
T |
result |
|
Returns