proxygen
testing::internal::MatchesRegexMatcher Class Reference

#include <gmock-matchers.h>

Public Member Functions

 MatchesRegexMatcher (const RE *regex, bool full_match)
 
template<typename CharType >
bool MatchAndExplain (CharType *s, MatchResultListener *listener) const
 
template<class MatcheeStringType >
bool MatchAndExplain (const MatcheeStringType &s, MatchResultListener *) const
 
void DescribeTo (::std::ostream *os) const
 
void DescribeNegationTo (::std::ostream *os) const
 
 MatchesRegexMatcher (const RE *regex, bool full_match)
 
template<typename CharType >
bool MatchAndExplain (CharType *s, MatchResultListener *listener) const
 
template<class MatcheeStringType >
bool MatchAndExplain (const MatcheeStringType &s, MatchResultListener *) const
 
void DescribeTo (::std::ostream *os) const
 
void DescribeNegationTo (::std::ostream *os) const
 
 MatchesRegexMatcher (const RE *regex, bool full_match)
 
template<typename CharType >
bool MatchAndExplain (CharType *s, MatchResultListener *listener) const
 
template<class MatcheeStringType >
bool MatchAndExplain (const MatcheeStringType &s, MatchResultListener *) const
 
void DescribeTo (::std::ostream *os) const
 
void DescribeNegationTo (::std::ostream *os) const
 

Private Member Functions

 GTEST_DISALLOW_ASSIGN_ (MatchesRegexMatcher)
 
 GTEST_DISALLOW_ASSIGN_ (MatchesRegexMatcher)
 
 GTEST_DISALLOW_ASSIGN_ (MatchesRegexMatcher)
 

Private Attributes

const internal::linked_ptr< const REregex_
 
const bool full_match_
 

Detailed Description

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

Constructor & Destructor Documentation

testing::internal::MatchesRegexMatcher::MatchesRegexMatcher ( const RE regex,
bool  full_match 
)
inline

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

1329  : regex_(regex), full_match_(full_match) {}
regex
Definition: CMakeCache.txt:563
const internal::linked_ptr< const RE > regex_
testing::internal::MatchesRegexMatcher::MatchesRegexMatcher ( const RE regex,
bool  full_match 
)
inline

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

1329  : regex_(regex), full_match_(full_match) {}
regex
Definition: CMakeCache.txt:563
const internal::linked_ptr< const RE > regex_
testing::internal::MatchesRegexMatcher::MatchesRegexMatcher ( const RE regex,
bool  full_match 
)
inline

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

1329  : regex_(regex), full_match_(full_match) {}
regex
Definition: CMakeCache.txt:563
const internal::linked_ptr< const RE > regex_

Member Function Documentation

void testing::internal::MatchesRegexMatcher::DescribeNegationTo ( ::std::ostream *  os) const
inline

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

References testing::gtest_printers_test::Print(), and regex_.

1359  {
1360  *os << "doesn't " << (full_match_ ? "match" : "contain")
1361  << " regular expression ";
1363  }
const internal::linked_ptr< const RE > regex_
static void Print(const T &value,::std::ostream *os)
void testing::internal::MatchesRegexMatcher::DescribeNegationTo ( ::std::ostream *  os) const
inline

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

References GTEST_DISALLOW_ASSIGN_, testing::gtest_printers_test::Print(), and regex_.

1359  {
1360  *os << "doesn't " << (full_match_ ? "match" : "contain")
1361  << " regular expression ";
1363  }
const internal::linked_ptr< const RE > regex_
static void Print(const T &value,::std::ostream *os)
void testing::internal::MatchesRegexMatcher::DescribeNegationTo ( ::std::ostream *  os) const
inline

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

References GTEST_DISALLOW_ASSIGN_, testing::gtest_printers_test::Print(), and regex_.

1359  {
1360  *os << "doesn't " << (full_match_ ? "match" : "contain")
1361  << " regular expression ";
1363  }
const internal::linked_ptr< const RE > regex_
static void Print(const T &value,::std::ostream *os)
void testing::internal::MatchesRegexMatcher::DescribeTo ( ::std::ostream *  os) const
inline

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

References testing::gtest_printers_test::Print(), and regex_.

1353  {
1354  *os << (full_match_ ? "matches" : "contains")
1355  << " regular expression ";
1357  }
const internal::linked_ptr< const RE > regex_
static void Print(const T &value,::std::ostream *os)
void testing::internal::MatchesRegexMatcher::DescribeTo ( ::std::ostream *  os) const
inline

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

References testing::gtest_printers_test::Print(), and regex_.

1353  {
1354  *os << (full_match_ ? "matches" : "contains")
1355  << " regular expression ";
1357  }
const internal::linked_ptr< const RE > regex_
static void Print(const T &value,::std::ostream *os)
void testing::internal::MatchesRegexMatcher::DescribeTo ( ::std::ostream *  os) const
inline

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

References testing::gtest_printers_test::Print(), and regex_.

1353  {
1354  *os << (full_match_ ? "matches" : "contains")
1355  << " regular expression ";
1357  }
const internal::linked_ptr< const RE > regex_
static void Print(const T &value,::std::ostream *os)
testing::internal::MatchesRegexMatcher::GTEST_DISALLOW_ASSIGN_ ( MatchesRegexMatcher  )
private
testing::internal::MatchesRegexMatcher::GTEST_DISALLOW_ASSIGN_ ( MatchesRegexMatcher  )
private
testing::internal::MatchesRegexMatcher::GTEST_DISALLOW_ASSIGN_ ( MatchesRegexMatcher  )
private
template<typename CharType >
bool testing::internal::MatchesRegexMatcher::MatchAndExplain ( CharType *  s,
MatchResultListener listener 
) const
inline

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

1337  {
1338  return s != NULL && MatchAndExplain(internal::string(s), listener);
1339  }
::std::string string
Definition: gtest-port.h:1097
bool MatchAndExplain(CharType *s, MatchResultListener *listener) const
static set< string > s
template<typename CharType >
bool testing::internal::MatchesRegexMatcher::MatchAndExplain ( CharType *  s,
MatchResultListener listener 
) const
inline

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

1337  {
1338  return s != NULL && MatchAndExplain(internal::string(s), listener);
1339  }
::std::string string
Definition: gtest-port.h:1097
bool MatchAndExplain(CharType *s, MatchResultListener *listener) const
static set< string > s
template<typename CharType >
bool testing::internal::MatchesRegexMatcher::MatchAndExplain ( CharType *  s,
MatchResultListener listener 
) const
inline

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

1337  {
1338  return s != NULL && MatchAndExplain(internal::string(s), listener);
1339  }
::std::string string
Definition: gtest-port.h:1097
bool MatchAndExplain(CharType *s, MatchResultListener *listener) const
static set< string > s
template<class MatcheeStringType >
bool testing::internal::MatchesRegexMatcher::MatchAndExplain ( const MatcheeStringType &  s,
MatchResultListener  
) const
inline

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

References regex_.

1347  {
1348  const internal::string& s2(s);
1349  return full_match_ ? RE::FullMatch(s2, *regex_) :
1350  RE::PartialMatch(s2, *regex_);
1351  }
static bool FullMatch(const ::std::string &str, const RE &re)
Definition: gtest-port.h:1184
::std::string string
Definition: gtest-port.h:1097
const internal::linked_ptr< const RE > regex_
static set< string > s
template<class MatcheeStringType >
bool testing::internal::MatchesRegexMatcher::MatchAndExplain ( const MatcheeStringType &  s,
MatchResultListener  
) const
inline

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

References regex_.

1347  {
1348  const internal::string& s2(s);
1349  return full_match_ ? RE::FullMatch(s2, *regex_) :
1350  RE::PartialMatch(s2, *regex_);
1351  }
static bool FullMatch(const ::std::string &str, const RE &re)
Definition: gtest-port.h:1184
::std::string string
Definition: gtest-port.h:1097
const internal::linked_ptr< const RE > regex_
static set< string > s
template<class MatcheeStringType >
bool testing::internal::MatchesRegexMatcher::MatchAndExplain ( const MatcheeStringType &  s,
MatchResultListener  
) const
inline

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

References regex_.

1347  {
1348  const internal::string& s2(s);
1349  return full_match_ ? RE::FullMatch(s2, *regex_) :
1350  RE::PartialMatch(s2, *regex_);
1351  }
static bool FullMatch(const ::std::string &str, const RE &re)
Definition: gtest-port.h:1184
::std::string string
Definition: gtest-port.h:1097
const internal::linked_ptr< const RE > regex_
static set< string > s

Member Data Documentation

const bool testing::internal::MatchesRegexMatcher::full_match_
private

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

const internal::linked_ptr< const RE > testing::internal::MatchesRegexMatcher::regex_
private

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


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