![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <JsonObjectStructInterface.h>
Inheritance diagram for TImplementsJsonObjectStructConverter< StructType >:Public Member Functions | |
| TImplementsJsonObjectStructConverter () | |
| virtual EJsonObjectConvertResult | ConvertToJson (const void *StructMemory, TSharedPtr< FJsonObject > &OutJsonObject) const override |
| virtual EJsonObjectConvertResult | ConvertFromJson (void *StructMemory, const TSharedPtr< FJsonObject > &InJsonObject) const override |
Additional Inherited Members | |
Protected Member Functions inherited from IJsonObjectStructConverter | |
| virtual | ~IJsonObjectStructConverter ()=default |
This template is to be statically constructed and passed as a parameter to RegisterStructConverter in StartupModule() for the specified StructType. Remember to explicitly call UnregisterStructConverter in ShutdownModule() as well.
Example usage:
void FExampleModule::StartupModule() { static const TImplementsJsonObjectStructConverter<FExampleStruct> ExampleConverter = TImplementsJsonObjectStructConverter<FExampleStruct>(); FJsonObjectStructInterfaceRegistry::RegisterStructConverter(FExampleStruct::StaticStruct(), &ExampleConverter); }
void FExampleModule::ShutdownModule() { FJsonObjectStructInterfaceRegistry::UnregisterStructConverter(FExampleStruct::StaticStruct()); }
|
inline |
|
inlineoverridevirtual |
Result of Converted represents success by the interface call, FailAndAbort will bubble up the failure to its owner converter failing the entire converter tree, IgnoreAndContinue should leave the struct untouched/default and the converter tree can still succeed, and UseDefaultConverter will try to fallback to the non-static-interface behavior instead.
Implements IJsonObjectStructConverter.
|
inlineoverridevirtual |
Result of Converted represents success by the interface call, FailAndAbort will bubble up the failure to its owner converter which may fail the entire converter tree, IgnoreAndContinue will make an empty FJsonObject for this struct and the converter tree can still succeed, and UseDefaultConverter will try to fallback to the non-static-interface behavior instead.
Implements IJsonObjectStructConverter.