Home | History | Annotate | Download | only in history

Lines Matching refs:Matches

34 // Coalesces match positions in |matches| after index that intersect the match
37 Snippet::MatchPositions* matches) {
38 Snippet::MatchPosition& mp = (*matches)[index];
39 for (Snippet::MatchPositions::iterator i = matches->begin() + index + 1;
40 i != matches->end(); ) {
43 i = matches->erase(i);
50 // Sorts the match positions in |matches| by their first index, then coalesces
52 void CoalseAndSortMatchPositions(Snippet::MatchPositions* matches) {
53 std::sort(matches->begin(), matches->end(), &CompareMatchPosition);
55 // from matches.
56 for (size_t i = 0; i < matches->size(); ++i)
57 CoalesceMatchesFrom(i, matches);
82 virtual bool Matches(const string16& word, bool exact) const;
93 if (Matches(words[i].word, false)) {
104 bool QueryNodeWord::Matches(const string16& word, bool exact) const {
143 // QueryNodeList is never used with Matches or HasMatchIn.
144 virtual bool Matches(const string16& word, bool exact) const {
208 virtual bool Matches(const string16& word, bool exact) const;
213 bool QueryNodePhrase::Matches(const string16& word, bool exact) const {
227 if (!children_[j]->Matches(words[i + j].word, true)) {
305 Snippet::MatchPositions matches;
307 if (!query_nodes[i]->HasMatchIn(query_words, &matches))
311 // The lower case string differs from the original string. The matches are
317 CoalseAndSortMatchPositions(&matches);
318 match_positions->swap(matches);