Lines Matching refs:pattern
37 // supplied pattern exactly.
48 // By default, the pattern and input text are interpreted as UTF-8.
88 // You can use the "PartialMatch" operation when you want the pattern
106 // object from the pattern and use it multiple times. If you do so,
109 // Example: precompile pattern for faster matching:
110 // RE2 pattern("h.*o");
112 // if (RE2::FullMatch(str, pattern)) ...;
159 // bool match = RE2::FullMatchN(input, pattern, args, n);
163 // bool match = RE2::FullMatch(input, pattern,
227 ErrorPatternTooLarge, // pattern too large (compile failed)
243 RE2(const char* pattern);
244 RE2(const string& pattern);
246 RE2(const StringPiece& pattern);
247 RE2(const StringPiece& pattern, const Options& option);
255 // re.pattern(); // "ab*c?d+"
256 const string& pattern() const { return pattern_; }
281 // Matches "text" against "pattern". If pointer arguments are
285 // You can pass in a "const char*" or a "string" or a "RE2" for "pattern".
292 // (void*)NULL (the corresponding matched sub-pattern is not copied)
295 // a. "text" matches "pattern" exactly
298 // string captured as the "i"th sub-pattern. If you pass in
300 // number of sub-patterns, "i"th captured sub-pattern is
303 // CAVEAT: An optional sub-pattern that does not exist in the
314 // Exactly like FullMatch(), except that "pattern" is allowed to match
321 // Like FullMatch() and PartialMatch(), except that pattern has to
324 static bool ConsumeN(StringPiece* input, const RE2& pattern, // 3..16 args
330 // string. That is, "pattern" need not start its match at the beginning of
333 static bool FindAndConsumeN(StringPiece* input, const RE2& pattern,
338 // Replace the first match of "pattern" in "str" with "rewrite".
341 // from the pattern. \0 in "rewrite" refers to the entire matching
349 // Returns true if the pattern matches and a replacement occurs,
352 const RE2& pattern,
356 // of the pattern in the string with the rewrite. E.g.
369 const RE2& pattern,
372 // Like Replace, except that if the pattern matches, "rewrite"
379 const RE2& pattern,
475 // utf8 (true) text and pattern are UTF-8; otherwise Latin-1
671 void Init(const StringPiece& pattern, const Options& options);