QtRocket
 
Loading...
Searching...
No Matches
Catch::Clara::Detail::BasicResult< T > Class Template Reference

#include <catch_amalgamated.hpp>

Inheritance diagram for Catch::Clara::Detail::BasicResult< T >:
Collaboration diagram for Catch::Clara::Detail::BasicResult< T >:

Public Member Functions

template<typename U>
 BasicResult (BasicResult< U > const &other)
 
 operator bool () const
 
auto type () const -> ResultType
 
auto errorMessage () const -> std::string const &
 
- Public Member Functions inherited from Catch::Clara::Detail::ResultValueBase< void >
void const & value () const &
 
void && value () &&
 

Static Public Member Functions

template<typename U>
static auto ok (U &&value) -> BasicResult
 
static auto ok () -> BasicResult
 
static auto logicError (std::string &&message) -> BasicResult
 
static auto runtimeError (std::string &&message) -> BasicResult
 

Protected Member Functions

void enforceOk () const override
 
 BasicResult (ResultType type, std::string &&message)
 
- Protected Member Functions inherited from Catch::Clara::Detail::ResultValueBase< void >
 ResultBase (ResultType type)
 
 ResultBase (ResultBase const &)=default
 
 ResultBase (ResultBase &&)=default
 
 ResultValueBase (ResultType type)
 
 ResultValueBase (ResultValueBase const &other)
 
 ResultValueBase (ResultValueBase &&other)
 
 ResultValueBase (ResultType, void const &value)
 
 ResultValueBase (ResultType, void &&value)
 
ResultValueBaseoperator= (ResultValueBase const &other)
 
ResultValueBaseoperator= (ResultValueBase &&other)
 
 ~ResultValueBase () override
 
- Protected Member Functions inherited from Catch::Clara::Detail::ResultBase
 ResultBase (ResultType type)
 
virtual ~ResultBase ()
 
 ResultBase (ResultBase const &)=default
 
ResultBaseoperator= (ResultBase const &)=default
 
 ResultBase (ResultBase &&)=default
 
ResultBaseoperator= (ResultBase &&)=default
 

Protected Attributes

std::string m_errorMessage
 
ResultType m_type
 
- Protected Attributes inherited from Catch::Clara::Detail::ResultValueBase< void >
union { 
 
   T   m_value 
 
};  
 
- Protected Attributes inherited from Catch::Clara::Detail::ResultBase
ResultType m_type
 

Additional Inherited Members

- Public Attributes inherited from Catch::Clara::Detail::ResultValueBase< void >
void m_value
 

Constructor & Destructor Documentation

◆ BasicResult() [1/2]

template<typename T = void>
template<typename U>
Catch::Clara::Detail::BasicResult< T >::BasicResult ( BasicResult< U > const & other)
inlineexplicit

◆ BasicResult() [2/2]

template<typename T = void>
Catch::Clara::Detail::BasicResult< T >::BasicResult ( ResultType type,
std::string && message )
inlineprotected

Member Function Documentation

◆ enforceOk()

template<typename T = void>
void Catch::Clara::Detail::BasicResult< T >::enforceOk ( ) const
inlineoverrideprotectedvirtual

◆ errorMessage()

template<typename T = void>
auto Catch::Clara::Detail::BasicResult< T >::errorMessage ( ) const -> std::string const&
inline

◆ logicError()

template<typename T = void>
static auto Catch::Clara::Detail::BasicResult< T >::logicError ( std::string && message) -> BasicResult
inlinestatic

◆ ok() [1/2]

template<typename T = void>
static auto Catch::Clara::Detail::BasicResult< T >::ok ( ) -> BasicResult
inlinestatic

◆ ok() [2/2]

template<typename T = void>
template<typename U>
static auto Catch::Clara::Detail::BasicResult< T >::ok ( U && value) -> BasicResult
inlinestatic

◆ operator bool()

template<typename T = void>
Catch::Clara::Detail::BasicResult< T >::operator bool ( ) const
inlineexplicit

◆ runtimeError()

template<typename T = void>
static auto Catch::Clara::Detail::BasicResult< T >::runtimeError ( std::string && message) -> BasicResult
inlinestatic

◆ type()

template<typename T = void>
auto Catch::Clara::Detail::BasicResult< T >::type ( ) const -> ResultType
inline

Member Data Documentation

◆ m_errorMessage

template<typename T = void>
std::string Catch::Clara::Detail::BasicResult< T >::m_errorMessage
protected

◆ m_type

template<typename T = void>
ResultType Catch::Clara::Detail::ResultBase::m_type
protected

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