1 /*---------------------------------------------------------------------\
3 | |__ / \ / / . \ . \ |
8 \---------------------------------------------------------------------*/
9 /** \file zypp/base/Regex.h
12 #ifndef ZYPP_BASE_REGEX_H
13 #define ZYPP_BASE_REGEX_H
20 ///////////////////////////////////////////////////////////////////
22 { /////////////////////////////////////////////////////////////////
23 ///////////////////////////////////////////////////////////////////
24 /** String related utilities and \ref ZYPP_STR_REGEX.
25 \see \ref ZYPP_STR_REGEX
28 { /////////////////////////////////////////////////////////////////
38 match_extended = REG_EXTENDED
41 regex(const std::string& s,int flags = match_extended);
55 std::string operator[](unsigned i) const;
57 unsigned size() const;
59 std::string match_str;
60 regmatch_t pmatch[12];
63 bool regex_match(const std::string& s, str::smatch& matches, const regex& regex);
64 bool regex_match(const std::string& s, const regex& regex);
65 bool regex_search(const std::string& s, str::smatch& matches, const regex& regex);
67 /////////////////////////////////////////////////////////////////
69 ///////////////////////////////////////////////////////////////////
70 /////////////////////////////////////////////////////////////////
72 ///////////////////////////////////////////////////////////////////
73 #endif // ZYPP_BASE_STRING_H