chromium/chrome/browser/enterprise/reporting/extension_request/extension_request_report_generator.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 "chrome/browser/enterprise/reporting/extension_request/extension_request_report_generator.h"

#include <string>

#include "base/json/values_util.h"
#include "base/time/time.h"
#include "base/values.h"
#include "build/chromeos_buildflags.h"
#include "chrome/browser/browser_process.h"
#include "chrome/browser/enterprise/reporting/prefs.h"
#include "chrome/browser/extensions/extension_management.h"
#include "chrome/browser/profiles/profile.h"
#include "chrome/common/extensions/extension_constants.h"
#include "chrome/common/pref_names.h"
#include "components/enterprise/common/proto/extensions_workflow_events.pb.h"
#include "components/policy/core/common/cloud/cloud_policy_util.h"
#include "components/prefs/pref_service.h"
#include "components/prefs/scoped_user_pref_update.h"
#include "extensions/common/extension_urls.h"

namespace enterprise_reporting {
namespace {

// Create the ExtensionsWorkflowEvent based on the |extension_id| and
// |request_data|. |request_data| is nullptr for remove-request and used for
// add-request.
std::unique_ptr<ExtensionsWorkflowEvent> GenerateReport(
    const std::string& extension_id,
    const base::Value::Dict* request_data) {}

}  // namespace

// static
bool ExtensionRequestReportGenerator::ShouldUploadExtensionRequest(
    const std::string& extension_id,
    const std::string& webstore_update_url,
    extensions::ExtensionManagement* extension_management) {}

ExtensionRequestReportGenerator::ExtensionRequestReportGenerator() = default;
ExtensionRequestReportGenerator::~ExtensionRequestReportGenerator() = default;

std::vector<std::unique_ptr<ExtensionsWorkflowEvent>>
ExtensionRequestReportGenerator::Generate(
    const RealTimeReportGenerator::Data& data) {}

std::vector<std::unique_ptr<ExtensionsWorkflowEvent>>
ExtensionRequestReportGenerator::GenerateForProfile(Profile* profile) {}

}  // namespace enterprise_reporting