![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include "CoreTypes.h"#include "Memory/MemoryFwd.h"#include "Memory/MemoryView.h"#include "Misc/EnumClassFlags.h"#include "Serialization/CompactBinary.h"Go to the source code of this file.
Enumerations | |
| enum class | ECbValidateMode : uint32 { None = 0 , Default = 1 << 0 , Names = 1 << 1 , Format = 1 << 2 , Padding = 1 << 3 , Package = 1 << 4 , PackageHash = 1 << 5 , All = Default | Names | Format | Padding | Package | PackageHash } |
| enum class | ECbValidateError : uint32 { None = 0 , OutOfBounds = 1 << 0 , InvalidType = 1 << 1 , DuplicateName = 1 << 2 , MissingName = 1 << 3 , ArrayName = 1 << 4 , InvalidString = 1 << 5 , InvalidInteger = 1 << 6 , InvalidFloat = 1 << 7 , NonUniformObject = 1 << 8 , NonUniformArray = 1 << 9 , Padding = 1 << 10 , InvalidPackageFormat = 1 << 11 , InvalidPackageHash = 1 << 12 , DuplicateAttachments = 1 << 13 , MultiplePackageObjects = 1 << 14 , NullPackageObject = 1 << 15 , NullPackageAttachment = 1 << 16 } |
Functions | |
| ENUM_CLASS_FLAGS (ECbValidateMode) | |
| ENUM_CLASS_FLAGS (ECbValidateError) | |
| CORE_API ECbValidateError | ValidateCompactBinary (FMemoryView View, ECbValidateMode Mode, ECbFieldType Type=ECbFieldType::HasFieldType) |
| CORE_API ECbValidateError | ValidateCompactBinaryRange (FMemoryView View, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinaryAttachment (FMemoryView View, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinaryPackage (FMemoryView View, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinary (const FCbField &Value, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinary (const FCbArray &Value, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinary (const FCbObject &Value, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinary (const FCbPackage &Value, ECbValidateMode Mode) |
| CORE_API ECbValidateError | ValidateCompactBinary (const FCbAttachment &Value, ECbValidateMode Mode) |
|
strong |
Flags for compact binary validation errors. Multiple flags may be combined.
|
strong |
Flags for validating compact binary data.
| ENUM_CLASS_FLAGS | ( | ECbValidateError | ) |
| ENUM_CLASS_FLAGS | ( | ECbValidateMode | ) |
| CORE_API ECbValidateError ValidateCompactBinary | ( | const FCbArray & | Value, |
| ECbValidateMode | Mode | ||
| ) |
| CORE_API ECbValidateError ValidateCompactBinary | ( | const FCbAttachment & | Value, |
| ECbValidateMode | Mode | ||
| ) |
| CORE_API ECbValidateError ValidateCompactBinary | ( | const FCbField & | Value, |
| ECbValidateMode | Mode | ||
| ) |
Validate the compact binary data for one value as specified by the mode flags.
Validation recurses into attachments, objects, arrays, and fields within the top-level value.
| CORE_API ECbValidateError ValidateCompactBinary | ( | const FCbObject & | Value, |
| ECbValidateMode | Mode | ||
| ) |
| CORE_API ECbValidateError ValidateCompactBinary | ( | const FCbPackage & | Value, |
| ECbValidateMode | Mode | ||
| ) |
| CORE_API ECbValidateError ValidateCompactBinary | ( | FMemoryView | View, |
| ECbValidateMode | Mode, | ||
| ECbFieldType | Type = ECbFieldType::HasFieldType |
||
| ) |
Validate the compact binary data for one field in the view as specified by the mode flags.
Only one top-level field is processed from the view, and validation recurses into any array or object within that field. To validate multiple consecutive top-level fields, call the function once for each top-level field. If the given view might contain multiple top-level fields, then either exclude the Padding flag from the Mode or use MeasureCompactBinary to break up the view into its constituent fields before validating.
| View | A memory view containing at least one top-level field. |
| Mode | A combination of the flags for the types of validation to perform. |
| Type | HasFieldType means that View contains the type. Otherwise, use the given type. |
| CORE_API ECbValidateError ValidateCompactBinaryAttachment | ( | FMemoryView | View, |
| ECbValidateMode | Mode | ||
| ) |
Validate the compact binary attachment pointed to by the view as specified by the mode flags.
The attachment is validated with ValidateCompactBinary by using the validation mode specified. Include ECbValidateMode::Package to validate the attachment format and hash.
| View | A memory view containing a package. |
| Mode | A combination of the flags for the types of validation to perform. |
| CORE_API ECbValidateError ValidateCompactBinaryPackage | ( | FMemoryView | View, |
| ECbValidateMode | Mode | ||
| ) |
Validate the compact binary package pointed to by the view as specified by the mode flags.
The package, and attachments, are validated with ValidateCompactBinary by using the validation mode specified. Include ECbValidateMode::Package to validate the package format and hashes.
| View | A memory view containing a package. |
| Mode | A combination of the flags for the types of validation to perform. |
| CORE_API ECbValidateError ValidateCompactBinaryRange | ( | FMemoryView | View, |
| ECbValidateMode | Mode | ||
| ) |
Validate the compact binary data for every field in the view as specified by the mode flags.
This function expects the entire view to contain fields. Any trailing region of the view which does not contain a valid field will produce an OutOfBounds or InvalidType error instead of the Padding error that would be produced by the single field validation function.