UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
TAttributeArrayContainer< AttributeType > Class Template Reference

#include <AttributeArrayContainer.h>

Public Member Functions

 TAttributeArrayContainer ()=default
 
 TAttributeArrayContainer (const AttributeType &InDefaultValue)
 
int32 Num () const
 
void Initialize (const int32 ElementCount, const AttributeType &Default)
 
void SetNum (const int32 ElementCount, const AttributeType &Default)
 
uint32 GetHash (uint32 Crc=0) const
 
void Insert (const int32 Index, const AttributeType &Default)
 
void SetToDefault (const int32 Index, const AttributeType &Default)
 
void Remap (const TSparseArray< int32 > &IndexRemap, const AttributeType &Default)
 
TArrayView< AttributeType > Get (int32 Index)
 
TArrayView< const AttributeType > Get (int32 Index) const
 
int32 GetElementCount (int32 Index) const
 
int32 GetReservedElementCount (int32 Index) const
 
void Set (int32 Index, TArrayView< const AttributeType > Value)
 
TArrayView< AttributeType > SetElementSize (int32 Index, int32 Size, bool bSetCount, bool bSetDefault=true)
 
TArrayView< AttributeType > InsertIntoElement (int32 Index, int32 SubArrayIndex, int32 InsertCount=1)
 
TArrayView< AttributeType > RemoveFromElement (int32 Index, int32 SubArrayIndex, int32 Count=1)
 
AttributeType GetDefault () const
 

Friends

FArchiveoperator<< (FArchive &Ar, TAttributeArrayContainer< AttributeType > &Array)
 

Constructor & Destructor Documentation

◆ TAttributeArrayContainer() [1/2]

template<typename AttributeType >
TAttributeArrayContainer< AttributeType >::TAttributeArrayContainer ( )
default

◆ TAttributeArrayContainer() [2/2]

template<typename AttributeType >
TAttributeArrayContainer< AttributeType >::TAttributeArrayContainer ( const AttributeType &  InDefaultValue)
inlineexplicit

Member Function Documentation

◆ Get() [1/2]

template<typename AttributeType >
TArrayView< AttributeType > TAttributeArrayContainer< AttributeType >::Get ( int32  Index)
inline

Gets the array attribute at the given index as a TArrayView

◆ Get() [2/2]

template<typename AttributeType >
TArrayView< const AttributeType > TAttributeArrayContainer< AttributeType >::Get ( int32  Index) const
inline

Gets the array attribute at the given index as a TArrayView

◆ GetDefault()

template<typename AttributeType >
AttributeType TAttributeArrayContainer< AttributeType >::GetDefault ( ) const
inline

◆ GetElementCount()

template<typename AttributeType >
int32 TAttributeArrayContainer< AttributeType >::GetElementCount ( int32  Index) const
inline

Gets the element count of the array attribute at the given index

◆ GetHash()

template<typename AttributeType >
uint32 TAttributeArrayContainer< AttributeType >::GetHash ( uint32  Crc = 0) const
inline

◆ GetReservedElementCount()

template<typename AttributeType >
int32 TAttributeArrayContainer< AttributeType >::GetReservedElementCount ( int32  Index) const
inline

Gets the reserved element count of the array attribute at the given index

◆ Initialize()

template<typename AttributeType >
void TAttributeArrayContainer< AttributeType >::Initialize ( const int32  ElementCount,
const AttributeType &  Default 
)
inline

Initializes the array to the given size with the default value

◆ Insert()

template<typename AttributeType >
void TAttributeArrayContainer< AttributeType >::Insert ( const int32  Index,
const AttributeType &  Default 
)
inline

Expands the array if necessary so that the passed element index is valid. Newly created elements will be assigned the default value.

◆ InsertIntoElement()

template<typename AttributeType >
TArrayView< AttributeType > TAttributeArrayContainer< AttributeType >::InsertIntoElement ( int32  Index,
int32  SubArrayIndex,
int32  InsertCount = 1 
)
inline

◆ Num()

template<typename AttributeType >
int32 TAttributeArrayContainer< AttributeType >::Num ( ) const
inline

Return size of container

◆ Remap()

template<typename AttributeType >
void TAttributeArrayContainer< AttributeType >::Remap ( const TSparseArray< int32 > &  IndexRemap,
const AttributeType &  Default 
)

Remaps elements according to the passed remapping table

◆ RemoveFromElement()

template<typename AttributeType >
TArrayView< AttributeType > TAttributeArrayContainer< AttributeType >::RemoveFromElement ( int32  Index,
int32  SubArrayIndex,
int32  Count = 1 
)
inline

◆ Set()

template<typename AttributeType >
void TAttributeArrayContainer< AttributeType >::Set ( int32  Index,
TArrayView< const AttributeType >  Value 
)
inline

Sets the attribute array at the given index to the given TArrayView

◆ SetElementSize()

template<typename AttributeType >
TArrayView< AttributeType > TAttributeArrayContainer< AttributeType >::SetElementSize ( int32  Index,
int32  Size,
bool  bSetCount,
bool  bSetDefault = true 
)
inline

Sets the given attribute array element to have the given number of subarray elements.

◆ SetNum()

template<typename AttributeType >
void TAttributeArrayContainer< AttributeType >::SetNum ( const int32  ElementCount,
const AttributeType &  Default 
)
inline

Sets the number of elements, each element itself being a subarray of items of type AttributeType.

◆ SetToDefault()

template<typename AttributeType >
void TAttributeArrayContainer< AttributeType >::SetToDefault ( const int32  Index,
const AttributeType &  Default 
)
inline

Fills the index with the default value

Friends And Related Symbol Documentation

◆ operator<<

template<typename AttributeType >
FArchive & operator<< ( FArchive Ar,
TAttributeArrayContainer< AttributeType > &  Array 
)
friend

The documentation for this class was generated from the following file: