#include "components/security_interstitials/core/metrics_helper.h"
#include <memory>
#include <utility>
#include "base/functional/bind.h"
#include "base/metrics/histogram.h"
#include "base/metrics/histogram_functions.h"
#include "base/metrics/user_metrics.h"
#include "base/metrics/user_metrics_action.h"
#include "base/time/time.h"
#include "components/history/core/browser/history_service.h"
#include "net/base/registry_controlled_domains/registry_controlled_domain.h"
RecordAction;
UserMetricsAction;
namespace security_interstitials {
namespace {
void RecordSingleDecisionToMetrics(MetricsHelper::Decision decision,
const std::string& histogram_name) { … }
void RecordSingleInteractionToMetrics(MetricsHelper::Interaction interaction,
const std::string& histogram_name) { … }
void MaybeRecordDecisionAsAction(MetricsHelper::Decision decision,
const std::string& metric_name) { … }
void MaybeRecordInteractionAsAction(MetricsHelper::Interaction interaction,
const std::string& metric_name) { … }
}
MetricsHelper::~MetricsHelper() { … }
MetricsHelper::ReportDetails::ReportDetails() { … }
MetricsHelper::ReportDetails::ReportDetails(const ReportDetails& other) =
default;
MetricsHelper::ReportDetails::~ReportDetails() { … }
MetricsHelper::MetricsHelper(const GURL& request_url,
const ReportDetails settings,
history::HistoryService* history_service)
: … { … }
void MetricsHelper::RecordUserDecision(Decision decision) { … }
void MetricsHelper::RecordUserDecisionToMetrics(
Decision decision,
const std::string& histogram_name) { … }
void MetricsHelper::RecordUserInteraction(Interaction interaction) { … }
void MetricsHelper::RecordShutdownMetrics() { … }
void MetricsHelper::RecordInterstitialShowDelay() { … }
int MetricsHelper::NumVisits() { … }
void MetricsHelper::RecordExtraUserDecisionMetrics(Decision decision) { … }
void MetricsHelper::RecordExtraUserInteractionMetrics(Interaction interaction) { … }
void MetricsHelper::RecordExtraShutdownMetrics() { … }
void MetricsHelper::OnGotHistoryCount(
history::VisibleVisitCountToHostResult result) { … }
}