Choose your operating system:
Windows
macOS
Linux
Module |
|
Header |
/Engine/Plugins/Online/Experimental/OnlineServices/Source/OnlineServicesInterface/Public/Online/OnlineResult.h |
Include |
#include "Online/OnlineResult.h" |
template<typename SuccessType, typename ErrorType>
class TResult
A container that holds either a successful result or an erroneous result.
Name | Description | |
---|---|---|
|
TResult() |
|
|
TResult ( |
Construct a result with an Ok value |
|
TResult ( |
Construct a result with an Ok value |
|
TResult ( |
Construct a result with an error value |
|
TResult ( |
Construct a result with an error value |
|
TResult ( |
Copy construct a result of the same type |
|
TResult ( |
Move construct a result |
Name | Description | |
---|---|---|
|
~TResult() |
Name | Description | ||
---|---|---|---|
|
const ErrorT... |
GetErrorValue() |
Get the Error value stored in the result. |
|
ErrorType & |
GetErrorValue() |
Get the Error value stored in the result. |
|
const Succes... |
GetOkOrDefault ( |
Unwraps the result, returning the success value if one is held, otherwise returning the default passed. |
|
const Succes... |
GetOkValue() |
Get the Ok value stored in the result. This must not be called on a result holding the error type |
|
SuccessType ... |
GetOkValue() |
Get the Ok value stored in the result. This must not be called on a result holding the error type |
|
IsError() |
Check if the value held in the result is a ErrorType. |
|
|
IsOk() |
Check if the value held in the result is a SuccessType. |
|
|
const ErrorT... |
TryGetErrorValue() |
Convert from TResult |
|
ErrorType &#... |
TryGetErrorValue() |
Convert from TResult |
|
const Succes... |
TryGetOkValue() |
Convert from TResult |
|
SuccessType ... |
TryGetOkValue() |
Convert from TResult |