chromium/components/safe_browsing/content/browser/download/download_stats.cc

// Copyright 2021 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#include "components/safe_browsing/content/browser/download/download_stats.h"

#include "base/files/file_path.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/download/public/common/download_content.h"
#include "components/download/public/common/download_danger_type.h"
#include "components/safe_browsing/content/common/file_type_policies.h"

namespace {

FileTypePolicies;

constexpr char kShownMetricSuffix[] =;
constexpr char kBypassedMetricSuffix[] =;

std::string GetDangerTypeMetricSuffix(
    download::DownloadDangerType danger_type) {}

void RecordDangerousWarningFileType(download::DownloadDangerType danger_type,
                                    const base::FilePath& file_path,
                                    const std::string& metrics_suffix) {}

void RecordDangerousWarningIsHttps(download::DownloadDangerType danger_type,
                                   bool is_https,
                                   const std::string& metrics_suffix) {}

void RecordDangerousWarningHasUserGesture(
    download::DownloadDangerType danger_type,
    bool has_user_gesture,
    const std::string& metrics_suffix) {}

}  // namespace

namespace safe_browsing {

void RecordDangerousDownloadWarningShown(
    download::DownloadDangerType danger_type,
    const base::FilePath& file_path,
    bool is_https,
    bool has_user_gesture) {}

void RecordDangerousDownloadWarningBypassed(
    download::DownloadDangerType danger_type,
    const base::FilePath& file_path,
    bool is_https,
    bool has_user_gesture) {}

void RecordDownloadOpenedLatency(download::DownloadDangerType danger_type,
                                 download::DownloadContent download_content,
                                 base::Time download_opened_time,
                                 base::Time download_end_time,
                                 bool show_download_in_folder) {}

void RecordDownloadFileTypeAttributes(
    DownloadFileType::DangerLevel danger_level,
    bool has_user_gesture,
    bool visited_referrer_before,
    std::optional<base::Time> last_bypass_time) {}

}  // namespace safe_browsing