UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
TValueOrError< ValueType, void > Class Template Reference

#include <ValueOrError.h>

Public Member Functions

template<typename... ArgTypes>
 TValueOrError (TValueOrError_ValueProxy< ArgTypes... > &&Proxy)
 
 TValueOrError (TValueOrError_ErrorProxy<> &&Proxy)
 
UE_REWRITE bool HasError () const
 
UE_REWRITE bool HasValue () const
 
ValueType & GetValue () &UE_LIFETIMEBOUND
 
UE_REWRITE const ValueType & GetValue () const &UE_LIFETIMEBOUND
 
UE_REWRITE ValueType && GetValue () &&UE_LIFETIMEBOUND
 
ValueType * TryGetValue () UE_LIFETIMEBOUND
 
UE_REWRITE const ValueType * TryGetValue () const UE_LIFETIMEBOUND
 
ValueType StealValue ()
 

Constructor & Destructor Documentation

◆ TValueOrError() [1/2]

template<typename ValueType >
template<typename... ArgTypes>
TValueOrError< ValueType, void >::TValueOrError ( TValueOrError_ValueProxy< ArgTypes... > &&  Proxy)
inline

Construct the value from a proxy from MakeValue.

◆ TValueOrError() [2/2]

template<typename ValueType >
TValueOrError< ValueType, void >::TValueOrError ( TValueOrError_ErrorProxy<> &&  Proxy)
inline

Construct the error from a proxy from MakeError.

Member Function Documentation

◆ GetValue() [1/3]

template<typename ValueType >
UE_REWRITE ValueType && TValueOrError< ValueType, void >::GetValue ( ) &&
inline

◆ GetValue() [2/3]

template<typename ValueType >
ValueType & TValueOrError< ValueType, void >::GetValue ( ) &
inline

Access the value. Asserts if this does not have a value.

◆ GetValue() [3/3]

template<typename ValueType >
UE_REWRITE const ValueType & TValueOrError< ValueType, void >::GetValue ( ) const &
inline

◆ HasError()

template<typename ValueType >
UE_REWRITE bool TValueOrError< ValueType, void >::HasError ( ) const
inline

Whether the error is set. An error does imply no value.

◆ HasValue()

template<typename ValueType >
UE_REWRITE bool TValueOrError< ValueType, void >::HasValue ( ) const
inline

Whether the value is set. A value does imply no error.

◆ StealValue()

template<typename ValueType >
ValueType TValueOrError< ValueType, void >::StealValue ( )
inline

Steal the value. Asserts if this does not have a value. This causes the value to be unset.

◆ TryGetValue() [1/2]

template<typename ValueType >
UE_REWRITE const ValueType * TValueOrError< ValueType, void >::TryGetValue ( ) const
inline

◆ TryGetValue() [2/2]

template<typename ValueType >
ValueType * TValueOrError< ValueType, void >::TryGetValue ( )
inline

Access the value if it is set.


The documentation for this class was generated from the following file: