OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CHROME_BROWSER_HISTORY_SCORED_HISTORY_MATCH_H_ | 5 #ifndef CHROME_BROWSER_HISTORY_SCORED_HISTORY_MATCH_H_ |
6 #define CHROME_BROWSER_HISTORY_SCORED_HISTORY_MATCH_H_ | 6 #define CHROME_BROWSER_HISTORY_SCORED_HISTORY_MATCH_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <set> | 9 #include <set> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/strings/string16.h" | 12 #include "base/strings/string16.h" |
13 #include "chrome/browser/history/history_types.h" | |
14 #include "chrome/browser/history/in_memory_url_index_types.h" | 13 #include "chrome/browser/history/in_memory_url_index_types.h" |
15 #include "components/history/core/browser/history_match.h" | 14 #include "components/history/core/browser/history_match.h" |
| 15 #include "components/history/core/browser/history_types.h" |
16 #include "testing/gtest/include/gtest/gtest_prod.h" | 16 #include "testing/gtest/include/gtest/gtest_prod.h" |
17 | 17 |
18 namespace history { | 18 namespace history { |
19 | 19 |
20 class HistoryClient; | 20 class HistoryClient; |
21 class ScoredHistoryMatchTest; | 21 class ScoredHistoryMatchTest; |
22 | 22 |
23 // An HistoryMatch that has a score as well as metrics defining where in the | 23 // An HistoryMatch that has a score as well as metrics defining where in the |
24 // history item's URL and/or page title matches have occurred. | 24 // history item's URL and/or page title matches have occurred. |
25 class ScoredHistoryMatch : public history::HistoryMatch { | 25 class ScoredHistoryMatch : public history::HistoryMatch { |
(...skipping 173 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
199 // matches) because if a non-inlineable match comes first than all matches | 199 // matches) because if a non-inlineable match comes first than all matches |
200 // will get demoted later in HistoryQuickProvider to non-inlineable scores. | 200 // will get demoted later in HistoryQuickProvider to non-inlineable scores. |
201 // Set to -1 to indicate no maximum score. | 201 // Set to -1 to indicate no maximum score. |
202 static int max_assigned_score_for_non_inlineable_matches_; | 202 static int max_assigned_score_for_non_inlineable_matches_; |
203 }; | 203 }; |
204 typedef std::vector<ScoredHistoryMatch> ScoredHistoryMatches; | 204 typedef std::vector<ScoredHistoryMatch> ScoredHistoryMatches; |
205 | 205 |
206 } // namespace history | 206 } // namespace history |
207 | 207 |
208 #endif // CHROME_BROWSER_HISTORY_SCORED_HISTORY_MATCH_H_ | 208 #endif // CHROME_BROWSER_HISTORY_SCORED_HISTORY_MATCH_H_ |
OLD | NEW |