renamed MatchSet to Matches

This commit is contained in:
Josh Holtrop 2010-05-19 14:30:15 -04:00
parent b100c035a0
commit 55b1e1494a
2 changed files with 6 additions and 6 deletions

View File

@ -140,12 +140,12 @@ void Token::process()
{
}
MatchSet::MatchSet(pcre * re, const char * data, int * ovector, int ovec_size)
Matches::Matches(pcre * re, const char * data, int * ovector, int ovec_size)
: m_re(re), m_data(data), m_ovector(ovector), m_ovec_size(ovec_size)
{
}
std::string MatchSet::operator[](int index)
std::string Matches::operator[](int index)
{
if (0 <= index && index < (m_ovec_size / 3))
{
@ -159,7 +159,7 @@ std::string MatchSet::operator[](int index)
return "";
}
std::string MatchSet::operator[](const std::string & index)
std::string Matches::operator[](const std::string & index)
{
int idx = pcre_get_stringnumber(m_re, index.c_str());
if (idx > 0 && idx < (m_ovec_size / 3))

View File

@ -123,10 +123,10 @@ class I_CLASSNAME
const char * m_errstr;
};
class MatchSet
class Matches
{
public:
MatchSet(pcre * re, const char * data, int * ovector, int ovec_size);
Matches(pcre * re, const char * data, int * ovector, int ovec_size);
std::string operator[](int index);
std::string operator[](const std::string & index);
@ -136,7 +136,7 @@ class MatchSet
int * m_ovector;
int m_ovec_size;
};
typedef refptr<MatchSet> MatchSetRef;
typedef refptr<Matches> MatchesRef;
class Node
{