Method GetComponentTypes
GetComponentTypes(Entity, Allocator)
Gets an entity's component types.
Declaration
public NativeArray<ComponentType> GetComponentTypes(Entity entity, Allocator allocator = Allocator.Temp)Parameters
| Type | Name | Description | 
|---|---|---|
| Entity | entity | The entity. | 
| Allocator | allocator | The type of allocation for creating the NativeArray to hold the ComponentType objects. | 
Returns
| Type | Description | 
|---|---|
| NativeArray<ComponentType> | An array of ComponentType containing all the types of components associated with the entity. | 
GetComponentTypes(Entity, AllocatorHandle)
Gets an entity's component types.
Declaration
public NativeArray<ComponentType> GetComponentTypes(Entity entity, AllocatorManager.AllocatorHandle allocator)Parameters
| Type | Name | Description | 
|---|---|---|
| Entity | entity | The entity. | 
| AllocatorManager.AllocatorHandle | allocator | The type of allocation for creating the NativeArray to hold the ComponentType objects. | 
Returns
| Type | Description | 
|---|---|
| NativeArray<ComponentType> | An array of ComponentType containing all the types of components associated with the entity. | 
GetComponentTypes(SystemHandle, Allocator)
Gets a system entity's component types.
Declaration
public NativeArray<ComponentType> GetComponentTypes(SystemHandle system, Allocator allocator = Allocator.Temp)Parameters
| Type | Name | Description | 
|---|---|---|
| SystemHandle | system | The system handle. | 
| Allocator | allocator | The type of allocation for creating the NativeArray to hold the ComponentType objects. | 
Returns
| Type | Description | 
|---|---|
| NativeArray<ComponentType> | An array of ComponentType containing all the types of components associated with the entity. | 
GetComponentTypes(SystemHandle, AllocatorHandle)
Gets a system entity's component types.
Declaration
public NativeArray<ComponentType> GetComponentTypes(SystemHandle system, AllocatorManager.AllocatorHandle allocator)Parameters
| Type | Name | Description | 
|---|---|---|
| SystemHandle | system | The system handle. | 
| AllocatorManager.AllocatorHandle | allocator | The type of allocation for creating the NativeArray to hold the ComponentType objects. | 
Returns
| Type | Description | 
|---|---|
| NativeArray<ComponentType> | An array of ComponentType containing all the types of components associated with the entity. |