proxygen
testing::internal::RefMatcher< T & > Class Template Reference

#include <gmock-matchers.h>

Classes

class  Impl
 

Public Member Functions

 RefMatcher (T &x)
 
template<typename Super >
 operator Matcher< Super & > () const
 
 RefMatcher (T &x)
 
template<typename Super >
 operator Matcher< Super & > () const
 
 RefMatcher (T &x)
 
template<typename Super >
 operator Matcher< Super & > () const
 

Private Member Functions

 GTEST_DISALLOW_ASSIGN_ (RefMatcher)
 
 GTEST_DISALLOW_ASSIGN_ (RefMatcher)
 
 GTEST_DISALLOW_ASSIGN_ (RefMatcher)
 

Private Attributes

Tobject_
 

Detailed Description

template<typename T>
class testing::internal::RefMatcher< T & >

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

Constructor & Destructor Documentation

template<typename T >
testing::internal::RefMatcher< T & >::RefMatcher ( T x)
inlineexplicit

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

template<typename T >
testing::internal::RefMatcher< T & >::RefMatcher ( T x)
inlineexplicit

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

template<typename T >
testing::internal::RefMatcher< T & >::RefMatcher ( T x)
inlineexplicit

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

Member Function Documentation

template<typename T >
testing::internal::RefMatcher< T & >::GTEST_DISALLOW_ASSIGN_ ( RefMatcher< T & >  )
private
template<typename T >
testing::internal::RefMatcher< T & >::GTEST_DISALLOW_ASSIGN_ ( RefMatcher< T & >  )
private
template<typename T >
testing::internal::RefMatcher< T & >::GTEST_DISALLOW_ASSIGN_ ( RefMatcher< T & >  )
private
template<typename T >
template<typename Super >
testing::internal::RefMatcher< T & >::operator Matcher< Super & > ( ) const
inline

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

References testing::MakeMatcher().

1045  {
1046  // By passing object_ (type T&) to Impl(), which expects a Super&,
1047  // we make sure that Super is a super type of T. In particular,
1048  // this catches using Ref(const_value) as a matcher for a
1049  // non-const reference, as you cannot implicitly convert a const
1050  // reference to a non-const reference.
1051  return MakeMatcher(new Impl<Super>(object_));
1052  }
Matcher< T > MakeMatcher(const MatcherInterface< T > *impl)
template<typename T >
template<typename Super >
testing::internal::RefMatcher< T & >::operator Matcher< Super & > ( ) const
inline

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

References testing::MakeMatcher().

1045  {
1046  // By passing object_ (type T&) to Impl(), which expects a Super&,
1047  // we make sure that Super is a super type of T. In particular,
1048  // this catches using Ref(const_value) as a matcher for a
1049  // non-const reference, as you cannot implicitly convert a const
1050  // reference to a non-const reference.
1051  return MakeMatcher(new Impl<Super>(object_));
1052  }
Matcher< T > MakeMatcher(const MatcherInterface< T > *impl)
template<typename T >
template<typename Super >
testing::internal::RefMatcher< T & >::operator Matcher< Super & > ( ) const
inline

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

References testing::MakeMatcher().

1045  {
1046  // By passing object_ (type T&) to Impl(), which expects a Super&,
1047  // we make sure that Super is a super type of T. In particular,
1048  // this catches using Ref(const_value) as a matcher for a
1049  // non-const reference, as you cannot implicitly convert a const
1050  // reference to a non-const reference.
1051  return MakeMatcher(new Impl<Super>(object_));
1052  }
Matcher< T > MakeMatcher(const MatcherInterface< T > *impl)

Member Data Documentation

template<typename T >
T & testing::internal::RefMatcher< T & >::object_
private

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


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