chromium/chrome/browser/ui/performance_controls/performance_controls_metrics.cc

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

#include "chrome/browser/ui/performance_controls/performance_controls_metrics.h"

#include <memory>

#include "base/check_op.h"
#include "base/location.h"
#include "base/metrics/histogram_functions.h"
#include "base/metrics/user_metrics.h"
#include "base/strings/strcat.h"
#include "base/time/time.h"
#include "chrome/browser/performance_manager/public/user_tuning/performance_detection_manager.h"
#include "chrome/common/pref_names.h"
#include "components/metrics/daily_event.h"
#include "components/prefs/pref_service.h"

namespace {

PerformanceDetectionManager;

// The interval at which the DailyEvent::CheckInterval function should be
// called.
constexpr base::TimeDelta kDailyEventIntervalTimeDelta =;

std::string GetDetectionResourceTypeString(
    PerformanceDetectionManager::ResourceType resource_type) {}

class DailyEventObserver : public metrics::DailyEvent::Observer {};

}  // namespace

PerformanceInterventionMetricsReporter::PerformanceInterventionMetricsReporter(
    PrefService* pref_service)
    :{}

PerformanceInterventionMetricsReporter::
    ~PerformanceInterventionMetricsReporter() = default;

void PerformanceInterventionMetricsReporter::RegisterLocalStatePrefs(
    PrefRegistrySimple* registry) {}

void RecordBatterySaverBubbleAction(BatterySaverBubbleActionType type) {}

void RecordBatterySaverIPHOpenSettings(bool success) {}

void RecordMemorySaverBubbleAction(MemorySaverBubbleActionType type) {}

void RecordMemorySaverIPHEnableMode(bool success) {}

void RecordMemorySaverChipState(MemorySaverChipState state) {}

void RecordInterventionMessageCount(
    PerformanceDetectionManager::ResourceType resource_type,
    PrefService* pref_service) {}

void RecordInterventionRateLimitedCount(
    PerformanceDetectionManager::ResourceType resource_type,
    PrefService* pref_service) {}

void RecordInterventionTriggerResult(
    PerformanceDetectionManager::ResourceType resource_type,
    InterventionMessageTriggerResult reason) {}

void RecordInterventionToolbarButtonClicked() {}

void RecordInterventionBubbleClosedReason(
    PerformanceDetectionManager::ResourceType resource_type,
    InterventionBubbleActionType type) {}

void RecordCpuHealthStatusAfterDiscard(
    base::TimeDelta time_after_discard,
    PerformanceDetectionManager::HealthLevel health_level) {}

void RecordCpuUsageBeforeDiscard(int cpu_usage) {}

void RecordSuggestedTabShownCount(int count) {}

void RecordTabRemovedFromTabList(int count_after_removal) {}

void RecordNumberOfDiscardedTabs(int count) {}