Navigation
API > API/Plugins > API/Plugins/OnlineServicesInterface > API/Plugins/OnlineServicesInterface/Online
Inheritance Hierarchy
References
| Module | OnlineServicesInterface |
| Header | /Engine/Plugins/Online/OnlineServices/Source/OnlineServicesInterface/Public/Online/OnlineResult.h |
| Include | #include "Online/OnlineResult.h" |
Syntax
template<typename SuccessType, typename ErrorType>
class TResult
Remarks
A container that holds either a successful result or an erroneous result.
Constructors
| Type | Name | Description | |
|---|---|---|---|
TResult () |
|||
TResult
(
const SuccessType& OkValue |
Construct a result with an Ok value | ||
TResult
(
SuccessType&& OkValue |
Construct a result with an Ok value | ||
TResult
(
const ErrorType& ErrValue |
Construct a result with an error value | ||
TResult
(
ErrorType&& ErrValue |
Construct a result with an error value | ||
| Copy construct a result of the same type | |||
| Move construct a result |
Destructors
| Type | Name | Description | |
|---|---|---|---|
~TResult () |
Functions
| Type | Name | Description | |
|---|---|---|---|
| const ErrorType & | Get the Error value stored in the result. | ||
| ErrorType & | Get the Error value stored in the result. | ||
| const SuccessType & | GetOkOrDefault
(
const SuccessType& DefaultValue |
Unwraps the result, returning the success value if one is held, otherwise returning the default passed. | |
| const SuccessType & | 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 | |
| bool | IsError () |
Check if the value held in the result is a ErrorType. | |
| bool | IsOk () |
Check if the value held in the result is a SuccessType. | |
| const ErrorType * | Convert from TResult |
||
| ErrorType * | Convert from TResult |
||
| const SuccessType * | Convert from TResult |
||
| SuccessType * | Convert from TResult |