Navigation
API > API/Runtime > API/Runtime/InterchangeCore > API/Runtime/InterchangeCore/FAttributeStorage
Description
Register an attribute in the storage. Return success if the attribute was properly added, or there is an existing attribute of the same type. Return an error otherwise.
@Param ElementAttributeKey - the storage key (the path) of the attribute. @Param DefaultValue - the default value for the registered attribute.
Possible errors:
- Key exists with a different type.
- Storage is corrupted.
| Name | RegisterAttribute |
| Type | function |
| Header File | /Engine/Source/Runtime/Interchange/Core/Public/Types/AttributeStorage.h |
| Include Path | #include "Types/AttributeStorage.h" |
template<typename T>
EAttributeStorageResult RegisterAttribute
(
const FAttributeKey & ElementAttributeKey,
const T & DefaultValue,
EAttributeProperty AttributeProperty
)