proxygen
testing::internal::KeyMatcherImpl< PairType > Class Template Reference

#include <gmock-matchers.h>

Inheritance diagram for testing::internal::KeyMatcherImpl< PairType >:
testing::MatcherInterface< PairType > testing::MatcherInterface< PairType > testing::MatcherInterface< PairType > testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface testing::MatcherDescriberInterface

Public Types

typedef RawPairType::first_type KeyType
 
typedef RawPairType::first_type KeyType
 
typedef RawPairType::first_type KeyType
 

Public Member Functions

typedef GTEST_REMOVE_REFERENCE_AND_CONST_ (PairType) RawPairType
 
template<typename InnerMatcher >
 KeyMatcherImpl (InnerMatcher inner_matcher)
 
virtual bool MatchAndExplain (PairType key_value, MatchResultListener *listener) const
 
virtual void DescribeTo (::std::ostream *os) const
 
virtual void DescribeNegationTo (::std::ostream *os) const
 
typedef GTEST_REMOVE_REFERENCE_AND_CONST_ (PairType) RawPairType
 
template<typename InnerMatcher >
 KeyMatcherImpl (InnerMatcher inner_matcher)
 
virtual bool MatchAndExplain (PairType key_value, MatchResultListener *listener) const
 
virtual void DescribeTo (::std::ostream *os) const
 
virtual void DescribeNegationTo (::std::ostream *os) const
 
typedef GTEST_REMOVE_REFERENCE_AND_CONST_ (PairType) RawPairType
 
template<typename InnerMatcher >
 KeyMatcherImpl (InnerMatcher inner_matcher)
 
virtual bool MatchAndExplain (PairType key_value, MatchResultListener *listener) const
 
virtual void DescribeTo (::std::ostream *os) const
 
virtual void DescribeNegationTo (::std::ostream *os) const
 
- Public Member Functions inherited from testing::MatcherDescriberInterface
virtual ~MatcherDescriberInterface ()
 
virtual ~MatcherDescriberInterface ()
 
virtual ~MatcherDescriberInterface ()
 

Private Member Functions

 GTEST_DISALLOW_ASSIGN_ (KeyMatcherImpl)
 
 GTEST_DISALLOW_ASSIGN_ (KeyMatcherImpl)
 
 GTEST_DISALLOW_ASSIGN_ (KeyMatcherImpl)
 

Private Attributes

const Matcher< const KeyType & > inner_matcher_
 

Detailed Description

template<typename PairType>
class testing::internal::KeyMatcherImpl< PairType >

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

Member Typedef Documentation

template<typename PairType >
typedef RawPairType::first_type testing::internal::KeyMatcherImpl< PairType >::KeyType

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

template<typename PairType >
typedef RawPairType::first_type testing::internal::KeyMatcherImpl< PairType >::KeyType

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

template<typename PairType >
typedef RawPairType::first_type testing::internal::KeyMatcherImpl< PairType >::KeyType

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

Constructor & Destructor Documentation

template<typename PairType >
template<typename InnerMatcher >
testing::internal::KeyMatcherImpl< PairType >::KeyMatcherImpl ( InnerMatcher  inner_matcher)
inlineexplicit

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

2946  : inner_matcher_(
2947  testing::SafeMatcherCast<const KeyType&>(inner_matcher)) {
2948  }
const Matcher< const KeyType & > inner_matcher_
template<typename PairType >
template<typename InnerMatcher >
testing::internal::KeyMatcherImpl< PairType >::KeyMatcherImpl ( InnerMatcher  inner_matcher)
inlineexplicit

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

2946  : inner_matcher_(
2947  testing::SafeMatcherCast<const KeyType&>(inner_matcher)) {
2948  }
const Matcher< const KeyType & > inner_matcher_
template<typename PairType >
template<typename InnerMatcher >
testing::internal::KeyMatcherImpl< PairType >::KeyMatcherImpl ( InnerMatcher  inner_matcher)
inlineexplicit

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

2946  : inner_matcher_(
2947  testing::SafeMatcherCast<const KeyType&>(inner_matcher)) {
2948  }
const Matcher< const KeyType & > inner_matcher_

Member Function Documentation

template<typename PairType >
virtual void testing::internal::KeyMatcherImpl< PairType >::DescribeNegationTo ( ::std::ostream *  os) const
inlinevirtual

Reimplemented from testing::MatcherDescriberInterface.

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

2970  {
2971  *os << "doesn't have a key that ";
2973  }
const Matcher< const KeyType & > inner_matcher_
void DescribeTo(::std::ostream *os) const
template<typename PairType >
virtual void testing::internal::KeyMatcherImpl< PairType >::DescribeNegationTo ( ::std::ostream *  os) const
inlinevirtual

Reimplemented from testing::MatcherDescriberInterface.

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

References GTEST_DISALLOW_ASSIGN_.

2970  {
2971  *os << "doesn't have a key that ";
2973  }
const Matcher< const KeyType & > inner_matcher_
void DescribeTo(::std::ostream *os) const
template<typename PairType >
virtual void testing::internal::KeyMatcherImpl< PairType >::DescribeNegationTo ( ::std::ostream *  os) const
inlinevirtual

Reimplemented from testing::MatcherDescriberInterface.

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

References GTEST_DISALLOW_ASSIGN_.

2970  {
2971  *os << "doesn't have a key that ";
2973  }
const Matcher< const KeyType & > inner_matcher_
void DescribeTo(::std::ostream *os) const
template<typename PairType >
virtual void testing::internal::KeyMatcherImpl< PairType >::DescribeTo ( ::std::ostream *  os) const
inlinevirtual

Implements testing::MatcherDescriberInterface.

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

2964  {
2965  *os << "has a key that ";
2967  }
const Matcher< const KeyType & > inner_matcher_
void DescribeTo(::std::ostream *os) const
template<typename PairType >
virtual void testing::internal::KeyMatcherImpl< PairType >::DescribeTo ( ::std::ostream *  os) const
inlinevirtual

Implements testing::MatcherDescriberInterface.

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

2964  {
2965  *os << "has a key that ";
2967  }
const Matcher< const KeyType & > inner_matcher_
void DescribeTo(::std::ostream *os) const
template<typename PairType >
virtual void testing::internal::KeyMatcherImpl< PairType >::DescribeTo ( ::std::ostream *  os) const
inlinevirtual

Implements testing::MatcherDescriberInterface.

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

2964  {
2965  *os << "has a key that ";
2967  }
const Matcher< const KeyType & > inner_matcher_
void DescribeTo(::std::ostream *os) const
template<typename PairType >
testing::internal::KeyMatcherImpl< PairType >::GTEST_DISALLOW_ASSIGN_ ( KeyMatcherImpl< PairType >  )
private
template<typename PairType >
testing::internal::KeyMatcherImpl< PairType >::GTEST_DISALLOW_ASSIGN_ ( KeyMatcherImpl< PairType >  )
private
template<typename PairType >
testing::internal::KeyMatcherImpl< PairType >::GTEST_DISALLOW_ASSIGN_ ( KeyMatcherImpl< PairType >  )
private
template<typename PairType >
typedef testing::internal::KeyMatcherImpl< PairType >::GTEST_REMOVE_REFERENCE_AND_CONST_ ( PairType  )
template<typename PairType >
typedef testing::internal::KeyMatcherImpl< PairType >::GTEST_REMOVE_REFERENCE_AND_CONST_ ( PairType  )
template<typename PairType >
typedef testing::internal::KeyMatcherImpl< PairType >::GTEST_REMOVE_REFERENCE_AND_CONST_ ( PairType  )
template<typename PairType >
virtual bool testing::internal::KeyMatcherImpl< PairType >::MatchAndExplain ( PairType  key_value,
MatchResultListener listener 
) const
inlinevirtual

Implements testing::MatcherInterface< PairType >.

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

References testing::StringMatchResultListener::str().

2952  {
2953  StringMatchResultListener inner_listener;
2954  const bool match = inner_matcher_.MatchAndExplain(key_value.first,
2955  &inner_listener);
2956  const internal::string explanation = inner_listener.str();
2957  if (explanation != "") {
2958  *listener << "whose first field is a value " << explanation;
2959  }
2960  return match;
2961  }
::std::string string
Definition: gtest-port.h:1097
const Matcher< const KeyType & > inner_matcher_
bool MatchAndExplain(T x, MatchResultListener *listener) const
template<typename PairType >
virtual bool testing::internal::KeyMatcherImpl< PairType >::MatchAndExplain ( PairType  key_value,
MatchResultListener listener 
) const
inlinevirtual

Implements testing::MatcherInterface< PairType >.

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

References testing::StringMatchResultListener::str().

2952  {
2953  StringMatchResultListener inner_listener;
2954  const bool match = inner_matcher_.MatchAndExplain(key_value.first,
2955  &inner_listener);
2956  const internal::string explanation = inner_listener.str();
2957  if (explanation != "") {
2958  *listener << "whose first field is a value " << explanation;
2959  }
2960  return match;
2961  }
::std::string string
Definition: gtest-port.h:1097
const Matcher< const KeyType & > inner_matcher_
bool MatchAndExplain(T x, MatchResultListener *listener) const
template<typename PairType >
virtual bool testing::internal::KeyMatcherImpl< PairType >::MatchAndExplain ( PairType  key_value,
MatchResultListener listener 
) const
inlinevirtual

Implements testing::MatcherInterface< PairType >.

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

References testing::StringMatchResultListener::str().

2952  {
2953  StringMatchResultListener inner_listener;
2954  const bool match = inner_matcher_.MatchAndExplain(key_value.first,
2955  &inner_listener);
2956  const internal::string explanation = inner_listener.str();
2957  if (explanation != "") {
2958  *listener << "whose first field is a value " << explanation;
2959  }
2960  return match;
2961  }
::std::string string
Definition: gtest-port.h:1097
const Matcher< const KeyType & > inner_matcher_
bool MatchAndExplain(T x, MatchResultListener *listener) const

Member Data Documentation

template<typename PairType >
const Matcher< const KeyType & > testing::internal::KeyMatcherImpl< PairType >::inner_matcher_
private

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


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