engine
 
载入中...
搜索中...
未找到
Public 成员函数 | 所有成员列表
FJsonStructSerializerBackend类 参考

Implements a writer for UStruct serialization using Json. 更多...

#include <JsonStructSerializerBackend.h>

+ 类 FJsonStructSerializerBackend 继承关系图:

Public 成员函数

virtual void BeginArray (const FStructSerializerState &State) override
 Signals the beginning of an array. 更多...
 
virtual void BeginStructure (const FStructSerializerState &State) override
 Signals the beginning of a child structure. 更多...
 
virtual void EndArray (const FStructSerializerState &State) override
 Signals the end of an array. 更多...
 
virtual void EndStructure (const FStructSerializerState &State) override
 Signals the end of an object. 更多...
 
 FJsonStructSerializerBackend (FArchive &InArchive)
 Creates and initializes a new legacy instance. 更多...
 
 FJsonStructSerializerBackend (FArchive &InArchive, const EStructSerializerBackendFlags InFlags)
 Creates and initializes a new instance with the given flags. 更多...
 
virtual void WriteComment (const FString &Comment) override
 Writes a comment to the output stream. 更多...
 
virtual void WriteProperty (const FStructSerializerState &State, int32 ArrayIndex=0) override
 Writes a property to the output stream. 更多...
 
- Public 成员函数 继承自 IStructSerializerBackend
virtual void BeginArray (const FStructSerializerState &State)=0
 Signals the beginning of an array. 更多...
 
virtual void BeginStructure (const FStructSerializerState &State)=0
 Signals the beginning of a child structure. 更多...
 
virtual void EndArray (const FStructSerializerState &State)=0
 Signals the end of an array. 更多...
 
virtual void EndStructure (const FStructSerializerState &State)=0
 Signals the end of an object. 更多...
 
virtual void WriteComment (const FString &Comment)=0
 Writes a comment to the output stream. 更多...
 
virtual void WriteProperty (const FStructSerializerState &State, int32 ArrayIndex=0)=0
 Writes a property to the output stream. 更多...
 
virtual ~IStructSerializerBackend ()
 Virtual destructor.
 

详细描述

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.

构造及析构函数说明

◆ FJsonStructSerializerBackend() [1/2]

FJsonStructSerializerBackend::FJsonStructSerializerBackend ( FArchive &  InArchive)
inline

Creates and initializes a new legacy instance.

注解
Deprecated, use the two-parameter constructor with EStructSerializerBackendFlags::Legacy if you need backwards compatibility with code compiled prior to 4.22.
参数
InArchiveThe archive to serialize into.

◆ FJsonStructSerializerBackend() [2/2]

FJsonStructSerializerBackend::FJsonStructSerializerBackend ( FArchive &  InArchive,
const EStructSerializerBackendFlags  InFlags 
)
inline

Creates and initializes a new instance with the given flags.

参数
InArchiveThe archive to serialize into.
InFlagsThe flags that control the serialization behavior (typically EStructSerializerBackendFlags::Default).

成员函数说明

◆ BeginArray()

virtual void FJsonStructSerializerBackend::BeginArray ( const FStructSerializerState &  State)
overridevirtual

Signals the beginning of an array.

State.ValueProperty points to the property that holds the array.

参数
StateThe serializer's current state.
参见
BeginStructure, EndArray

实现了 IStructSerializerBackend.

◆ BeginStructure()

virtual void FJsonStructSerializerBackend::BeginStructure ( const FStructSerializerState &  State)
overridevirtual

Signals the beginning of a child structure.

State.ValueProperty points to the property that holds the struct.

参数
StateThe serializer's current state.
参见
BeginArray, EndStructure

实现了 IStructSerializerBackend.

◆ EndArray()

virtual void FJsonStructSerializerBackend::EndArray ( const FStructSerializerState &  State)
overridevirtual

Signals the end of an array.

State.ValueProperty points to the property that holds the array.

参数
StateThe serializer's current state.
参见
BeginArray, EndStructure

实现了 IStructSerializerBackend.

◆ EndStructure()

virtual void FJsonStructSerializerBackend::EndStructure ( const FStructSerializerState &  State)
overridevirtual

Signals the end of an object.

State.ValueProperty points to the property that holds the struct.

参数
StateThe serializer's current state.
参见
BeginStructure, EndArray

实现了 IStructSerializerBackend.

◆ WriteComment()

virtual void FJsonStructSerializerBackend::WriteComment ( const FString &  Comment)
overridevirtual

Writes a comment to the output stream.

参数
CommentThe comment text.
参见
BeginArray, BeginStructure, EndArray, EndStructure, WriteProperty

实现了 IStructSerializerBackend.

◆ WriteProperty()

virtual void FJsonStructSerializerBackend::WriteProperty ( const FStructSerializerState &  State,
int32  ArrayIndex = 0 
)
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.

参数
StateThe serializer's current state.
参见
BeginArray, BeginStructure, EndArray, EndStructure, WriteComment

实现了 IStructSerializerBackend.


该类的文档由以下文件生成: