Method GetItems
GetItems()
Returns an array of all the TItemAsset
instances of this catalog.
Declaration
public TItemAsset[] GetItems()
Returns
Type | Description |
---|---|
TItemAsset[] | An array of all item definitions. |
Remarks
Keep in mind that this method allocates an array.
If you want to avoid allocations, please consider using
Get
GetItems(ICollection<TItemAsset>)
Fills in the given target
collection with all
TItemAsset
instances of this catalog and
returns their count.
The target
collection is cleared before being
populated.
Declaration
public int GetItems(ICollection<TItemAsset> target = null)
Parameters
Type | Name | Description |
---|---|---|
ICollection<TItemAsset> | target | The target container of all the
|
Returns
Type | Description |
---|---|
int | The number of |
GetItems<TInheritedItemAsset>()
Returns an array of all the
TInheritedItemAsset
instances of this catalog.
Declaration
public TInheritedItemAsset[] GetItems<TInheritedItemAsset>() where TInheritedItemAsset : TItemAsset
Returns
Type | Description |
---|---|
TInheritedItemAsset[] | An array of all item definitions. |
Type Parameters
Name | Description |
---|---|
TInheritedItemAsset | The type of items to find. |
Remarks
Keep in mind that this method allocates an array.
If you want to avoid allocations, please consider using
Get
GetItems<TInheritedItemAsset>(ICollection<TInheritedItemAsset>)
Fills in the given target
collection with all
TItemAssetAsset
instances of this catalog and
returns their count.
The target
collection is cleared before being
populated.
Declaration
public int GetItems<TInheritedItemAsset>(ICollection<TInheritedItemAsset> target = null)
Parameters
Type | Name | Description |
---|---|---|
ICollection<TInheritedItemAsset> | target | The target container of all the
|
Returns
Type | Description |
---|---|
int | The number of |
Type Parameters
Name | Description |
---|---|
TInheritedItemAsset |