libzypp 17.38.5
zyppng::expected< void, E > Class Template Reference

#include <zypp-core/ng/pipelines/expected.h>

Public Types

using value_type
using error_type

Public Member Functions

 expected ()
template<class G>
 expected (unexpected< G > err) noexcept
 ~expected ()
 expected (const expected &other)
 expected (expected &&other) noexcept
expectedoperator= (expected other)
template<class G = E>
expectedoperator= (unexpected< G > other)
void swap (expected &other) noexcept
 operator bool () const
bool is_valid () const
E & error ()
const E & error () const
void unwrap () const
void & get ()
void & operator* ()
void * operator-> ()
void visit (F f)

Static Public Member Functions

static expected success ()
template<typename... ConsParams>
static expected error (ConsParams &&...params)

Protected Attributes

union { 
   T   m_value 
   E   m_error 
}; 

Private Attributes

union zyppng::expected< void, E >:: { ... }  
bool m_isValid

Detailed Description

template<typename E>
class zyppng::expected< void, E >

Definition at line 314 of file expected.h.

Member Typedef Documentation

◆ value_type

using zyppng::expected< void, E >::value_type

Definition at line 71 of file expected.h.

◆ error_type

using zyppng::expected< void, E >::error_type

Definition at line 72 of file expected.h.

Constructor & Destructor Documentation

◆ expected() [1/4]

template<typename E>
zyppng::expected< void, E >::expected ( )
inline

Definition at line 325 of file expected.h.

◆ expected() [2/4]

template<typename E>
template<class G>
zyppng::expected< void, E >::expected ( unexpected< G > err)
inlinenoexcept

Definition at line 328 of file expected.h.

◆ ~expected()

template<typename E>
zyppng::expected< void, E >::~expected ( )
inline

Definition at line 333 of file expected.h.

◆ expected() [3/4]

template<typename E>
zyppng::expected< void, E >::expected ( const expected< void, E > & other)
inline

Definition at line 342 of file expected.h.

◆ expected() [4/4]

template<typename E>
zyppng::expected< void, E >::expected ( expected< void, E > && other)
inlinenoexcept

Definition at line 352 of file expected.h.

Member Function Documentation

◆ operator=() [1/2]

template<typename E>
expected & zyppng::expected< void, E >::operator= ( expected< void, E > other)
inline

Definition at line 362 of file expected.h.

◆ operator=() [2/2]

template<typename E>
template<class G = E>
expected & zyppng::expected< void, E >::operator= ( unexpected< G > other)
inline

Definition at line 369 of file expected.h.

◆ swap()

template<typename E>
void zyppng::expected< void, E >::swap ( expected< void, E > & other)
inlinenoexcept

Definition at line 376 of file expected.h.

◆ success()

template<typename E>
expected zyppng::expected< void, E >::success ( )
inlinestatic

Definition at line 408 of file expected.h.

◆ error() [1/3]

template<typename E>
template<typename... ConsParams>
expected zyppng::expected< void, E >::error ( ConsParams &&... params)
inlinestatic

Definition at line 414 of file expected.h.

◆ operator bool()

template<typename E>
zyppng::expected< void, E >::operator bool ( ) const
inline

Definition at line 424 of file expected.h.

◆ is_valid()

template<typename E>
bool zyppng::expected< void, E >::is_valid ( ) const
inline

Definition at line 429 of file expected.h.

◆ error() [2/3]

template<typename E>
E & zyppng::expected< void, E >::error ( )
inline

Definition at line 440 of file expected.h.

◆ error() [3/3]

template<typename E>
const E & zyppng::expected< void, E >::error ( ) const
inline

Definition at line 446 of file expected.h.

◆ unwrap()

template<typename E>
void zyppng::expected< void, E >::unwrap ( ) const
inline

Definition at line 452 of file expected.h.

◆ get()

void & zyppng::expected< void, E >::get ( )
inline

Definition at line 215 of file expected.h.

◆ operator*()

void & zyppng::expected< void, E >::operator* ( )
inline

Definition at line 268 of file expected.h.

◆ operator->()

void * zyppng::expected< void, E >::operator-> ( )
inline

Definition at line 278 of file expected.h.

◆ visit()

void zyppng::expected< void, E >::visit ( F f)
inline

Definition at line 303 of file expected.h.

Member Data Documentation

◆ m_value

template<typename E>
void* zyppng::expected< void, E >::m_value

Definition at line 317 of file expected.h.

◆ m_error

template<typename E>
E zyppng::expected< void, E >::m_error

Definition at line 318 of file expected.h.

◆ []

union zyppng::expected< void, E > { ... } zyppng::expected< void, E >

◆ m_isValid

template<typename E>
bool zyppng::expected< void, E >::m_isValid
private

Definition at line 321 of file expected.h.

◆ [union]

union { ... } zyppng::expected< void, E >

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