kblib 0.2.3
General utilities library for modern C++
Catch::Option< T > Class Template Reference

#include <catch/catch.hpp>

Public Member Functions

 Option ()
 
 Option (T const &_value)
 
 Option (Option const &_other)
 
 ~Option ()
 
Optionoperator= (Option const &_other)
 
Optionoperator= (T const &_value)
 
void reset ()
 
T & operator* ()
 
T const & operator* () const
 
T * operator-> ()
 
const T * operator-> () const
 
valueOr (T const &defaultValue) const
 
bool some () const
 
bool none () const
 
bool operator! () const
 
 operator bool () const
 
 Option ()
 
 Option (T const &_value)
 
 Option (Option const &_other)
 
 ~Option ()
 
Optionoperator= (Option const &_other)
 
Optionoperator= (T const &_value)
 
void reset ()
 
T & operator* ()
 
T const & operator* () const
 
T * operator-> ()
 
const T * operator-> () const
 
valueOr (T const &defaultValue) const
 
bool some () const
 
bool none () const
 
bool operator! () const
 
 operator bool () const
 

Detailed Description

template<typename T>
class Catch::Option< T >

Definition at line 4409 of file catch.hpp.

Constructor & Destructor Documentation

◆ Option() [1/6]

template<typename T >
Catch::Option< T >::Option ( )
inline

Definition at line 4411 of file catch.hpp.

◆ Option() [2/6]

template<typename T >
Catch::Option< T >::Option ( T const &  _value)
inline

Definition at line 4412 of file catch.hpp.

◆ Option() [3/6]

template<typename T >
Catch::Option< T >::Option ( Option< T > const &  _other)
inline

Definition at line 4415 of file catch.hpp.

◆ ~Option() [1/2]

template<typename T >
Catch::Option< T >::~Option ( )
inline

Definition at line 4419 of file catch.hpp.

◆ Option() [4/6]

template<typename T >
Catch::Option< T >::Option ( )
inline

Definition at line 4411 of file catch.hpp.

◆ Option() [5/6]

template<typename T >
Catch::Option< T >::Option ( T const &  _value)
inline

Definition at line 4412 of file catch.hpp.

◆ Option() [6/6]

template<typename T >
Catch::Option< T >::Option ( Option< T > const &  _other)
inline

Definition at line 4415 of file catch.hpp.

◆ ~Option() [2/2]

template<typename T >
Catch::Option< T >::~Option ( )
inline

Definition at line 4419 of file catch.hpp.

Member Function Documentation

◆ none() [1/2]

template<typename T >
bool Catch::Option< T >::none ( ) const
inline

Definition at line 4453 of file catch.hpp.

◆ none() [2/2]

template<typename T >
bool Catch::Option< T >::none ( ) const
inline

Definition at line 4453 of file catch.hpp.

◆ operator bool() [1/2]

template<typename T >
Catch::Option< T >::operator bool ( ) const
inlineexplicit

Definition at line 4456 of file catch.hpp.

◆ operator bool() [2/2]

template<typename T >
Catch::Option< T >::operator bool ( ) const
inlineexplicit

Definition at line 4456 of file catch.hpp.

◆ operator!() [1/2]

template<typename T >
bool Catch::Option< T >::operator! ( ) const
inline

Definition at line 4455 of file catch.hpp.

◆ operator!() [2/2]

template<typename T >
bool Catch::Option< T >::operator! ( ) const
inline

Definition at line 4455 of file catch.hpp.

◆ operator*() [1/4]

template<typename T >
T & Catch::Option< T >::operator* ( )
inline

Definition at line 4443 of file catch.hpp.

◆ operator*() [2/4]

template<typename T >
T & Catch::Option< T >::operator* ( )
inline

Definition at line 4443 of file catch.hpp.

◆ operator*() [3/4]

template<typename T >
T const & Catch::Option< T >::operator* ( ) const
inline

Definition at line 4444 of file catch.hpp.

◆ operator*() [4/4]

template<typename T >
T const & Catch::Option< T >::operator* ( ) const
inline

Definition at line 4444 of file catch.hpp.

◆ operator->() [1/4]

template<typename T >
T * Catch::Option< T >::operator-> ( )
inline

Definition at line 4445 of file catch.hpp.

◆ operator->() [2/4]

template<typename T >
T * Catch::Option< T >::operator-> ( )
inline

Definition at line 4445 of file catch.hpp.

◆ operator->() [3/4]

template<typename T >
const T * Catch::Option< T >::operator-> ( ) const
inline

Definition at line 4446 of file catch.hpp.

◆ operator->() [4/4]

template<typename T >
const T * Catch::Option< T >::operator-> ( ) const
inline

Definition at line 4446 of file catch.hpp.

◆ operator=() [1/4]

template<typename T >
Option & Catch::Option< T >::operator= ( Option< T > const &  _other)
inline

Definition at line 4423 of file catch.hpp.

◆ operator=() [2/4]

template<typename T >
Option & Catch::Option< T >::operator= ( Option< T > const &  _other)
inline

Definition at line 4423 of file catch.hpp.

◆ operator=() [3/4]

template<typename T >
Option & Catch::Option< T >::operator= ( T const &  _value)
inline

Definition at line 4431 of file catch.hpp.

◆ operator=() [4/4]

template<typename T >
Option & Catch::Option< T >::operator= ( T const &  _value)
inline

Definition at line 4431 of file catch.hpp.

◆ reset() [1/2]

template<typename T >
void Catch::Option< T >::reset ( )
inline

Definition at line 4437 of file catch.hpp.

◆ reset() [2/2]

template<typename T >
void Catch::Option< T >::reset ( )
inline

Definition at line 4437 of file catch.hpp.

◆ some() [1/2]

template<typename T >
bool Catch::Option< T >::some ( ) const
inline

Definition at line 4452 of file catch.hpp.

◆ some() [2/2]

template<typename T >
bool Catch::Option< T >::some ( ) const
inline

Definition at line 4452 of file catch.hpp.

◆ valueOr() [1/2]

template<typename T >
T Catch::Option< T >::valueOr ( T const &  defaultValue) const
inline

Definition at line 4448 of file catch.hpp.

◆ valueOr() [2/2]

template<typename T >
T Catch::Option< T >::valueOr ( T const &  defaultValue) const
inline

Definition at line 4448 of file catch.hpp.


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