#include "components/visited_url_ranking/internal/history_url_visit_data_fetcher.h"
#include <cmath>
#include <map>
#include <utility>
#include "base/containers/contains.h"
#include "base/metrics/histogram_functions.h"
#include "base/time/time.h"
#include "components/history/core/browser/history_service.h"
#include "components/history/core/browser/history_types.h"
#include "components/history/core/browser/url_row.h"
#include "components/url_deduplication/url_deduplication_helper.h"
#include "components/visited_url_ranking/public/features.h"
#include "components/visited_url_ranking/public/fetch_result.h"
#include "components/visited_url_ranking/public/fetcher_config.h"
#include "components/visited_url_ranking/public/url_visit_util.h"
#include "url/gurl.h"
namespace {
enum DayGroup { … };
DayGroup GetDayGroupForExplodedTime(const base::Time::Exploded& exploded_time) { … }
enum TimeGroup { … };
TimeGroup GetTimeGroupForExplodedTime(
const base::Time::Exploded& exploded_time) { … }
}
namespace visited_url_ranking {
Source;
URLVisitVariant;
HistoryURLVisitDataFetcher::HistoryURLVisitDataFetcher(
history::HistoryService* history_service)
: … { … }
HistoryURLVisitDataFetcher::~HistoryURLVisitDataFetcher() = default;
void HistoryURLVisitDataFetcher::FetchURLVisitData(
const FetchOptions& options,
const FetcherConfig& config,
FetchResultCallback callback) { … }
void HistoryURLVisitDataFetcher::OnGotAnnotatedVisits(
FetchResultCallback callback,
FetchOptions::FetchSources requested_fetch_sources,
const FetcherConfig& config,
std::vector<history::AnnotatedVisit> annotated_visits) { … }
}