Electroneum
Loading...
Searching...
No Matches
testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container > Class Template Reference

#include <gmock-matchers.h>

Inheritance diagram for testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >:
Collaboration diagram for testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >:

Public Types

typedef internal::StlContainerView< GTEST_REMOVE_REFERENCE_AND_CONST_(Container)> ContainerView
typedef std::iterator_traits< typenameContainerView::type::const_iterator >::difference_type DistanceType

Public Member Functions

 Impl (const DistanceMatcher &distance_matcher)
virtual void DescribeTo (::std::ostream *os) const
virtual void DescribeNegationTo (::std::ostream *os) const
virtual bool MatchAndExplain (Container container, MatchResultListener *listener) const
Public Member Functions inherited from testing::MatcherDescriberInterface
virtual ~MatcherDescriberInterface ()

Detailed Description

template<typename DistanceMatcher>
template<typename Container>
class testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >

Definition at line 2463 of file gmock-matchers.h.

Member Typedef Documentation

◆ ContainerView

template<typename DistanceMatcher>
template<typename Container>
typedef internal::StlContainerView< GTEST_REMOVE_REFERENCE_AND_CONST_(Container)> testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >::ContainerView

Definition at line 2466 of file gmock-matchers.h.

◆ DistanceType

template<typename DistanceMatcher>
template<typename Container>
typedef std::iterator_traits<typenameContainerView::type::const_iterator>::difference_type testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >::DistanceType

Definition at line 2469 of file gmock-matchers.h.

Constructor & Destructor Documentation

◆ Impl()

template<typename DistanceMatcher>
template<typename Container>
testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >::Impl ( const DistanceMatcher & distance_matcher)
inlineexplicit

Definition at line 2470 of file gmock-matchers.h.

Here is the call graph for this function:

Member Function Documentation

◆ DescribeNegationTo()

template<typename DistanceMatcher>
template<typename Container>
virtual void testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >::DescribeNegationTo ( ::std::ostream * os) const
inlinevirtual

Reimplemented from testing::MatcherDescriberInterface.

Definition at line 2477 of file gmock-matchers.h.

2477 {
2478 *os << "distance between begin() and end() ";
2479 distance_matcher_.DescribeNegationTo(os);
2480 }

◆ DescribeTo()

template<typename DistanceMatcher>
template<typename Container>
virtual void testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >::DescribeTo ( ::std::ostream * os) const
inlinevirtual

Implements testing::MatcherDescriberInterface.

Definition at line 2473 of file gmock-matchers.h.

2473 {
2474 *os << "distance between begin() and end() ";
2475 distance_matcher_.DescribeTo(os);
2476 }

◆ MatchAndExplain()

template<typename DistanceMatcher>
template<typename Container>
virtual bool testing::internal::BeginEndDistanceIsMatcher< DistanceMatcher >::Impl< Container >::MatchAndExplain ( Container container,
MatchResultListener * listener ) const
inlinevirtual

Implements testing::MatcherInterface< Container >.

Definition at line 2482 of file gmock-matchers.h.

2483 {
2484#if GTEST_HAS_STD_BEGIN_AND_END_
2485 using std::begin;
2486 using std::end;
2488#else
2490#endif
2492 const bool result =
2493 distance_matcher_.MatchAndExplain(distance, &distance_listener);
2494 *listener << "whose distance between begin() and end() " << distance
2495 << (result ? " matches" : " doesn't match");
2496 PrintIfNotEmpty(distance_listener.str(), listener->stream());
2497 return result;
2498 }
std::iterator_traits< typenameContainerView::type::const_iterator >::difference_type DistanceType
void PrintIfNotEmpty(const internal::string &explanation, ::std::ostream *os)
Here is the call graph for this function:

The documentation for this class was generated from the following file:
  • /home/abuild/rpmbuild/BUILD/electroneum-5.1.3.1-build/electroneum-5.1.3.1/external/rapidjson/thirdparty/gtest/googlemock/include/gmock/gmock-matchers.h