Index: chrome/browser/history/visit_database.h |
diff --git a/chrome/browser/history/visit_database.h b/chrome/browser/history/visit_database.h |
index 3eca17d7a1fa2720034fa92eb29529ecb89e1f06..ce0f8afef301a53eca30f46a845adeae9e795ef5 100644 |
--- a/chrome/browser/history/visit_database.h |
+++ b/chrome/browser/history/visit_database.h |
@@ -16,6 +16,8 @@ class Statement; |
namespace history { |
+class TimeFilter; |
+ |
// A visit database is one which stores visits for URLs, that is, times and |
// linking information. A visit database must also be a URLDatabase, as this |
// modifies tables used by URLs directly and could be thought of as inheriting |
@@ -73,6 +75,17 @@ class VisitDatabase { |
bool GetAllVisitsInRange(base::Time begin_time, base::Time end_time, |
int max_results, VisitVector* visits); |
+ // Fills all visits in the time ranges embedded in |time_filter| to the given |
+ // vector. |
+ // |
+ // If |max_results| is non-zero, up to that many results will be returned. If |
+ // there are more results than that, the oldest ones will be returned. (This |
+ // is used for history expiration.) |
+ // |
+ // The results will be in increasing order of date. |
+ bool GetAllVisitsDuringTimes(const TimeFilter& time_filter, |
+ int max_results, VisitVector* visits); |
+ |
// Fills all visits with specified transition in the time range [begin, end) |
// to the given vector. Either time can be is_null(), in which case the times |
// in that direction are unbounded. |
@@ -103,6 +116,20 @@ class VisitDatabase { |
int max_count, |
VisitVector* visits); |
+ // Fills all visits in the given time ranges into the given vector that should |
+ // be user-visible, which excludes things like redirects and subframes. The |
+ // begin time is inclusive, the end time is exclusive. |
+ // |
+ // Up to |max_count| visits will be returned. If there are more visits than |
+ // that, the most recent |max_count| will be returned. If 0, all visits in the |
+ // range will be computed. |
+ // |
+ // Only one visit for each URL will be returned, and it will be the most |
+ // recent one in the time range. |
+ void GetVisibleVisitsDuringTimes(const TimeFilter& time_filter, |
+ int max_count, |
+ VisitVector* visits); |
+ |
// Returns the visit ID for the most recent visit of the given URL ID, or 0 |
// if there is no visit for the URL. |
// |