FCbValue

A type that provides unchecked access to compact binary values.

Choose your operating system:

Windows

macOS

Linux

References

Module

Core

Header

/Engine/Source/Runtime/Core/Public/Serialization/CompactBinaryValue.h

Include

#include "Serialization/CompactBinaryValue.h"

Syntax

class FCbValue

Remarks

A type that provides unchecked access to compact binary values.

The main purpose of the type is to efficiently switch on field type. For every other use case, prefer to use the field, array, and object types directly. The accessors here do not check the type before reading the value, which means they can read out of bounds even on a valid compact binary value if the wrong accessor is used.

Constructors

Name Description

Public function

FCbValue

(
    ECbFieldType Type,
    const void* Value
)

Functions

Name Description

Public function Const

FCbArrayView

 

AsArrayView()

Public function Const

FIoHash

 

AsAttachment()

Public function Const

FMemoryView

 

AsBinary()

Public function Const

FIoHash

 

AsBinaryAttachment()

Public function Const

bool

 

AsBool()

Public function Const

FCbCustomByI...

 

AsCustomById()

Public function Const

FCbCustomByN...

 

AsCustomByName()

Public function Const

int64

 

AsDateTimeTicks()

Public function Const

float

 

AsFloat32()

Public function Const

double

 

AsFloat64()

Public function Const

FIoHash

 

AsHash()

Public function Const

uint64

 

AsInteger

(
    UE::CompactBinary::Private::FIntege...,
    ECbFieldError* OutError,
    uint64 Default
)

Access as an integer, with both positive and negative values returned as unsigned.

Public function Const

int64

 

AsIntegerNegative()

Public function Const

uint64

 

AsIntegerPositive()

Public function Const

FIoHash

 

AsObjectAttachment()

Public function Const

FCbObjectId

 

AsObjectId()

Public function Const

FCbObjectVie...

 

AsObjectView()

Public function Const

FUtf8StringV...

 

AsString

(
    ECbFieldError* OutError,
    FUtf8StringView Default
)

Access as a string. Checks for range errors and uses the default if OutError is not null.

Public function Const

int64

 

AsTimeSpanTicks()

Public function Const

FGuid

 

AsUuid()

Public function Const

const void &...

 

GetData()

Public function Const

ECbFieldType

 

GetType()