FStructBuilder

Lays out up a struct at runtime, in hopefully the same way as a compiler, and returns the offset of each member as it's added.

Windows
MacOS
Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Misc/StructBuilder.h

Include

#include "Misc/StructBuilder.h"

Syntax

class FStructBuilder

Remarks

Lays out up a struct at runtime, in hopefully the same way as a compiler, and returns the offset of each member as it's added.

Constructors

Name Description

Public function

FStructBuilder()

Functions

Name Description

Public function

int32

 

AddMember

(
    int32 MemberSize,
    int32 MemberAlignment
)

Adds a new member to the end of the struct.

Public function Const

int32

 

GetAlignment()

Returns the current alignment of the struct.

Public function Const

int32

 

GetSize()

Returns the current size of the struct.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss