API
Catch::Matchers::Generic::PredicateMatcher< T > Class Template Reference

#include <catch.hpp>

Inheritance diagram for Catch::Matchers::Generic::PredicateMatcher< T >:
Inheritance graph
Collaboration diagram for Catch::Matchers::Generic::PredicateMatcher< T >:
Collaboration graph

Public Member Functions

 PredicateMatcher (std::function< bool(T const &)> const &elem, std::string const &descr)
 
bool match (T const &item) const override
 
std::string describe () const override
 
MatchAllOf< T > operator&& (MatcherBase const &other) const
 
MatchAnyOf< T > operator|| (MatcherBase const &other) const
 
MatchNotOf< T > operator! () const
 
std::string toString () const
 

Protected Attributes

std::string m_cachedToString
 

Private Attributes

std::function< bool(T const &)> m_predicate
 
std::string m_description
 

Detailed Description

template<typename T>
class Catch::Matchers::Generic::PredicateMatcher< T >

Definition at line 3495 of file catch.hpp.

Constructor & Destructor Documentation

◆ PredicateMatcher()

template<typename T >
Catch::Matchers::Generic::PredicateMatcher< T >::PredicateMatcher ( std::function< bool(T const &)> const &  elem,
std::string const &  descr 
)
inline

Definition at line 3500 of file catch.hpp.

Member Function Documentation

◆ describe()

template<typename T >
std::string Catch::Matchers::Generic::PredicateMatcher< T >::describe ( ) const
inlineoverridevirtual

Implements Catch::Matchers::Impl::MatcherUntypedBase.

Definition at line 3509 of file catch.hpp.

◆ match()

template<typename T >
bool Catch::Matchers::Generic::PredicateMatcher< T >::match ( T const &  item) const
inlineoverridevirtual

Implements Catch::Matchers::Impl::MatcherMethod< T >.

Definition at line 3505 of file catch.hpp.

◆ operator!()

template<typename T >
MatchNotOf< T > Catch::Matchers::Impl::MatcherBase< T >::operator!
inherited

Definition at line 3379 of file catch.hpp.

◆ operator&&()

template<typename T >
MatchAllOf< T > Catch::Matchers::Impl::MatcherBase< T >::operator&& ( MatcherBase< T > const &  other) const
inherited

Definition at line 3371 of file catch.hpp.

◆ operator||()

template<typename T >
MatchAnyOf< T > Catch::Matchers::Impl::MatcherBase< T >::operator|| ( MatcherBase< T > const &  other) const
inherited

Definition at line 3375 of file catch.hpp.

◆ toString()

std::string Catch::Matchers::Impl::MatcherUntypedBase::toString ( ) const
inherited

Member Data Documentation

◆ m_cachedToString

std::string Catch::Matchers::Impl::MatcherUntypedBase::m_cachedToString
mutableprotectedinherited

Definition at line 3253 of file catch.hpp.

◆ m_description

template<typename T >
std::string Catch::Matchers::Generic::PredicateMatcher< T >::m_description
private

Definition at line 3497 of file catch.hpp.

◆ m_predicate

template<typename T >
std::function<bool(T const&)> Catch::Matchers::Generic::PredicateMatcher< T >::m_predicate
private

Definition at line 3496 of file catch.hpp.


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