libsshpp v0.1.7
Modern C++17 wrapper for libssh
Loading...
Searching...
No Matches
sshpp::Result< void > Class Reference

#include <result.hpp>

Public Types

using value_type = void
 
using error_type = ErrorInfo
 

Public Member Functions

 Result ()
 
 Result (ErrorInfo error)
 
bool has_value () const noexcept
 
 operator bool () const noexcept
 
void value () const
 
const ErrorInfoerror () const &noexcept
 
std::error_code code () const noexcept
 
void throw_if_error () const
 
template<class F >
auto and_then (F &&f) &&
 

Member Typedef Documentation

◆ value_type

using sshpp::Result< void >::value_type = void

◆ error_type

using sshpp::Result< void >::error_type = ErrorInfo

Constructor & Destructor Documentation

◆ Result() [1/2]

sshpp::Result< void >::Result ( )
inline

◆ Result() [2/2]

sshpp::Result< void >::Result ( ErrorInfo  error)
inline

Member Function Documentation

◆ has_value()

bool sshpp::Result< void >::has_value ( ) const
inlinenoexcept

◆ operator bool()

sshpp::Result< void >::operator bool ( ) const
inlineexplicitnoexcept

◆ value()

void sshpp::Result< void >::value ( ) const
inline

◆ error()

const ErrorInfo & sshpp::Result< void >::error ( ) const &
inlinenoexcept

◆ code()

std::error_code sshpp::Result< void >::code ( ) const
inlinenoexcept

◆ throw_if_error()

void sshpp::Result< void >::throw_if_error ( ) const
inline

◆ and_then()

template<class F >
auto sshpp::Result< void >::and_then ( F &&  f) &&
inline

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