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_VISIT_DATABASE_H_ | 5 #ifndef CHROME_BROWSER_HISTORY_VISIT_DATABASE_H_ |
6 #define CHROME_BROWSER_HISTORY_VISIT_DATABASE_H_ | 6 #define CHROME_BROWSER_HISTORY_VISIT_DATABASE_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "chrome/browser/history/history_types.h" | 10 #include "chrome/browser/history/history_types.h" |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 // in that direction are unbounded. | 93 // in that direction are unbounded. |
94 // | 94 // |
95 // If |max_results| is non-zero, up to that many results will be returned. If | 95 // If |max_results| is non-zero, up to that many results will be returned. If |
96 // there are more results than that, the oldest ones will be returned. (This | 96 // there are more results than that, the oldest ones will be returned. (This |
97 // is used for history expiration.) | 97 // is used for history expiration.) |
98 // | 98 // |
99 // The results will be in increasing order of date. | 99 // The results will be in increasing order of date. |
100 bool GetVisitsInRangeForTransition(base::Time begin_time, | 100 bool GetVisitsInRangeForTransition(base::Time begin_time, |
101 base::Time end_time, | 101 base::Time end_time, |
102 int max_results, | 102 int max_results, |
103 content::PageTransition transition, | 103 ui::PageTransition transition, |
104 VisitVector* visits); | 104 VisitVector* visits); |
105 | 105 |
106 // Fills all visits in the given time range into the given vector that should | 106 // Fills all visits in the given time range into the given vector that should |
107 // be user-visible, which excludes things like redirects and subframes. The | 107 // be user-visible, which excludes things like redirects and subframes. The |
108 // begin time is inclusive, the end time is exclusive. Either time can be | 108 // begin time is inclusive, the end time is exclusive. Either time can be |
109 // is_null(), in which case the times in that direction are unbounded. | 109 // is_null(), in which case the times in that direction are unbounded. |
110 // | 110 // |
111 // Up to |max_count| visits will be returned. If there are more visits than | 111 // Up to |max_count| visits will be returned. If there are more visits than |
112 // that, the most recent |max_count| will be returned. If 0, all visits in the | 112 // that, the most recent |max_count| will be returned. If 0, all visits in the |
113 // range will be computed. | 113 // range will be computed. |
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
224 DISALLOW_COPY_AND_ASSIGN(VisitDatabase); | 224 DISALLOW_COPY_AND_ASSIGN(VisitDatabase); |
225 }; | 225 }; |
226 | 226 |
227 // Rows, in order, of the visit table. | 227 // Rows, in order, of the visit table. |
228 #define HISTORY_VISIT_ROW_FIELDS \ | 228 #define HISTORY_VISIT_ROW_FIELDS \ |
229 " id,url,visit_time,from_visit,transition,segment_id,visit_duration " | 229 " id,url,visit_time,from_visit,transition,segment_id,visit_duration " |
230 | 230 |
231 } // namespace history | 231 } // namespace history |
232 | 232 |
233 #endif // CHROME_BROWSER_HISTORY_VISIT_DATABASE_H_ | 233 #endif // CHROME_BROWSER_HISTORY_VISIT_DATABASE_H_ |
OLD | NEW |