blob: 6d3909cc4a021a85e14129fa772e358314b52932 [file] [log] [blame]
// Copyright 2019 The Fuchsia Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "src/developer/feedback/crashpad_agent/info/agent_info.h"
#include "src/lib/fxl/logging.h"
using cobalt_registry::kCrashMetricId;
using CrashState = cobalt_registry::CrashMetricDimensionState;
namespace feedback {
AgentInfo::AgentInfo(std::shared_ptr<InfoContext> context) : context_(context) {
FXL_CHECK(context);
}
void AgentInfo::ExposeConfig(const feedback::Config& config) {
context_->InspectManager().ExposeConfig(config);
}
void AgentInfo::ExposeSettings(feedback::Settings* settings) {
context_->InspectManager().ExposeSettings(settings);
}
void AgentInfo::LogCrashState(CrashState state) { context_->Cobalt().LogOccurrence(state); }
} // namespace feedback