Rerun C++ SDK
Loading...
Searching...
No Matches
rerun::Result< T > Class Template Reference

A class for representing either a usable value, or an error. More...

#include <rerun/result.hpp>

Public Member Functions

 Result ()=delete
 Don't allow uninitialized results.
 
 Result (T _value)
 Construct a result from a value, setting error to ok.
 
 Result (rerun::Error _error)
 Construct a result from an error, default constructing the value.
 
 Result (const arrow::Status &status)
 Construct a result from an arrow status, default constructing the value.
 
 Result (arrow::Status &&status)
 Construct a result from an arrow status, default constructing the value.
 
bool is_ok () const
 Returns true if error is set to rerun::ErrorCode::Ok, implying that a value is contained, false otherwise.
 
bool is_err () const
 Returns true if error is not set to rerun::ErrorCode::Ok, implying that no value is contained, false otherwise.
 

Public Attributes

value
 
rerun::Error error
 

Detailed Description

template<typename T>
class rerun::Result< T >

A class for representing either a usable value, or an error.

In essence a simplified version of rust's Result or arrow's arrow::Result, always using rerun::Status. For simplicity, the wrapped type must be default constructible.


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