Navigation
API > API/Runtime > API/Runtime/Core
Array of FCbField[View] that have unique names.
Accessing the fields of an object is always a safe operation, even if the requested field does not exist. Fields may be accessed by name or through iteration. When a field is requested that is not found in the object, the field that it returns has no value (evaluates to false) though attempting to access the empty field is also safe, as described by FCbFieldView.
This type only provides a view into memory and does not perform any memory management itself. Use FCbObject to hold a reference to the underlying memory when necessary.
| Name | FCbObjectView |
| Type | class |
| Header File | /Engine/Source/Runtime/Core/Public/Serialization/CompactBinary.h |
| Include Path | #include "Serialization/CompactBinary.h" |
Syntax
class FCbObjectView : protected FCbFieldView
Inheritance Hierarchy
- FCbFieldView → FCbObjectView
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FCbObjectView
(
const FCbFieldView& Field |
Construct an object from an object field. No type check is performed! Use via FromFieldNoCheck. | Serialization/CompactBinary.h | |
| Construct an object with no fields. | Serialization/CompactBinary.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void AppendHash
(
FIoHashBuilder& Builder |
Append the hash of the object if serialized by itself with no name. | Serialization/CompactBinary.h | |
FCbFieldView AsFieldView() |
Access the object as an object field. | Serialization/CompactBinary.h | |
FCbFieldViewIterator begin() |
DO NOT USE DIRECTLY. These functions enable range-based for loop support. | Serialization/CompactBinary.h | |
| Copy the object into an archive. This will write GetSize() bytes, with no name. | Serialization/CompactBinary.h | ||
void CopyTo
(
FMutableMemoryView Buffer |
Copy the object into a buffer of exactly GetSize() bytes, with no name. | Serialization/CompactBinary.h | |
| Serialization/CompactBinary.h | |||
FCbIteratorSentinel end() |
Serialization/CompactBinary.h | ||
bool Equals
(
const FCbObjectView& Other |
Whether this object is identical to the other object. | Serialization/CompactBinary.h | |
FCbFieldView
(
const void* Data, |
Serialization/CompactBinary.h | ||
FCbFieldView
(
const FCbValue& Value |
Serialization/CompactBinary.h | ||
constexpr FCbFieldView () |
Serialization/CompactBinary.h | ||
FCbFieldView FindView
(
FUtf8StringView Name |
Find a field by case-sensitive name comparison. | Serialization/CompactBinary.h | |
FCbFieldView FindViewIgnoreCase
(
FUtf8StringView Name |
Find a field by case-insensitive name comparison. | Serialization/CompactBinary.h | |
FIoHash GetHash() |
Calculate the hash of the object if serialized by itself with no name. | Serialization/CompactBinary.h | |
uint64 GetSize() |
Returns the size of the object in bytes if serialized by itself with no name. | Serialization/CompactBinary.h | |
void IterateAttachments
(
FCbFieldVisitor Visitor |
Invoke the visitor for every attachment in the object. | Serialization/CompactBinary.h | |
bool TryGetView
(
FMemoryView& OutView |
Try to get a view of the object as it would be serialized, such as by CopyTo. | Serialization/CompactBinary.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static FCbObjectView FromFieldNoCheck
(
const FCbFieldView& Field |
Construct an object from an object field. No type check is performed! | Serialization/CompactBinary.h |
Operators
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
operator bool() |
Whether the object has any fields. | Serialization/CompactBinary.h | |
FCbFieldView operator[]
(
FUtf8StringView Name |
Find a field by case-sensitive name comparison. | Serialization/CompactBinary.h |