![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <JsonStructSerializerBackend.h>
Inheritance diagram for FJsonStructSerializerBackend:Public Member Functions | |
| FJsonStructSerializerBackend (FArchive &InArchive) | |
| FJsonStructSerializerBackend (FArchive &InArchive, const EStructSerializerBackendFlags InFlags) | |
| virtual SERIALIZATION_API void | BeginArray (const FStructSerializerState &State) override |
| virtual SERIALIZATION_API void | BeginStructure (const FStructSerializerState &State) override |
| virtual SERIALIZATION_API void | EndArray (const FStructSerializerState &State) override |
| virtual SERIALIZATION_API void | EndStructure (const FStructSerializerState &State) override |
| virtual SERIALIZATION_API void | WriteComment (const FString &Comment) override |
| virtual SERIALIZATION_API void | WriteProperty (const FStructSerializerState &State, int32 ArrayIndex=0) override |
| virtual SERIALIZATION_API bool | WritePODArray (const FStructSerializerState &State) override |
Public Member Functions inherited from IStructSerializerBackend | |
| virtual | ~IStructSerializerBackend () |
Protected Member Functions | |
| TSharedRef< TJsonWriter< UCS2CHAR > > & | GetWriter () |
| template<typename ValueType > | |
| void | WritePropertyValue (const FStructSerializerState &State, const ValueType &Value) |
| void | WriteNull (const FStructSerializerState &State) |
Implements a writer for UStruct serialization using Json.
Note: The underlying Json serializer is currently hard-coded to use UCS2CHAR and pretty-print. This is because the current JsonWriter API does not allow writers to be substituted since it's all based on templates. At some point we will refactor the low-level Json API to provide more flexibility for serialization.
|
inline |
Creates and initializes a new legacy instance.
| InArchive | The archive to serialize into. |
|
inline |
Creates and initializes a new instance with the given flags.
| InArchive | The archive to serialize into. |
| InFlags | The flags that control the serialization behavior (typically EStructSerializerBackendFlags::Default). |
|
overridevirtual |
Signals the beginning of an array.
State.ValueProperty points to the property that holds the array.
| State | The serializer's current state. |
Implements IStructSerializerBackend.
|
overridevirtual |
Signals the beginning of a child structure.
State.ValueProperty points to the property that holds the struct.
| State | The serializer's current state. |
Implements IStructSerializerBackend.
|
overridevirtual |
Signals the end of an array.
State.ValueProperty points to the property that holds the array.
| State | The serializer's current state. |
Implements IStructSerializerBackend.
|
overridevirtual |
Signals the end of an object.
State.ValueProperty points to the property that holds the struct.
| State | The serializer's current state. |
Implements IStructSerializerBackend.
|
inlineprotected |
|
overridevirtual |
Writes a comment to the output stream.
| Comment | The comment text. |
Implements IStructSerializerBackend.
|
inlineprotected |
|
overridevirtual |
Writes a POD Array property to the output stream.
State.ValueProperty points to the property that holds the value to write. needs to be an ArrayProperty with a properly supported InnerProperty. State.ValueData points to the actual data to write. The array itself in this case State.TypeInfo contains the data's type information
| State | The serializer's current state. |
Reimplemented from IStructSerializerBackend.
|
overridevirtual |
Writes a property to the output stream.
Depending on the context, properties to be written can be either object properties or array elements.
State.KeyProperty points to the key property that holds the data to write. State.KeyData points to the key property's data. State.ValueProperty points to the property that holds the value to write. State.ValueData points to the actual data to write. State.TypeInfo contains the data's type information State.ArrayIndex is the optional index if the data is a value in an array.
| State | The serializer's current state. |
Implements IStructSerializerBackend.
Reimplemented in FNativeJSStructSerializerBackend.
|
inlineprotected |