chromium/extensions/common/extension_builder.cc

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

#include "extensions/common/extension_builder.h"

#include <optional>
#include <string_view>
#include <utility>

#include "base/json/json_reader.h"
#include "base/strings/stringprintf.h"
#include "components/crx_file/id_util.h"
#include "extensions/common/api/content_scripts.h"
#include "extensions/common/api/extension_action/action_info.h"
#include "extensions/common/extension.h"
#include "extensions/common/manifest_constants.h"

namespace extensions {

constexpr char ExtensionBuilder::kServiceWorkerScriptFile[];

struct ExtensionBuilder::ManifestData {};

ExtensionBuilder::ExtensionBuilder()
    :{}

ExtensionBuilder::ExtensionBuilder(const std::string& name, Type type)
    :{}

ExtensionBuilder::~ExtensionBuilder() = default;

ExtensionBuilder::ExtensionBuilder(ExtensionBuilder&& other) = default;
ExtensionBuilder& ExtensionBuilder::operator=(ExtensionBuilder&& other) =
    default;

scoped_refptr<const Extension> ExtensionBuilder::Build() {}

base::Value ExtensionBuilder::BuildManifest() {}

ExtensionBuilder& ExtensionBuilder::AddAPIPermission(
    const std::string& permission) {}

ExtensionBuilder& ExtensionBuilder::AddAPIPermissions(
    const std::vector<std::string>& permissions) {}

ExtensionBuilder& ExtensionBuilder::AddOptionalAPIPermission(
    const std::string& permission) {}

ExtensionBuilder& ExtensionBuilder::AddOptionalAPIPermissions(
    const std::vector<std::string>& permissions) {}

ExtensionBuilder& ExtensionBuilder::AddHostPermission(
    const std::string& permission) {}

ExtensionBuilder& ExtensionBuilder::AddHostPermissions(
    const std::vector<std::string>& permissions) {}

ExtensionBuilder& ExtensionBuilder::AddOptionalHostPermission(
    const std::string& permission) {}

ExtensionBuilder& ExtensionBuilder::AddOptionalHostPermissions(
    const std::vector<std::string>& permissions) {}

ExtensionBuilder& ExtensionBuilder::SetAction(ActionInfo::Type type) {}

ExtensionBuilder& ExtensionBuilder::SetBackgroundContext(
    BackgroundContext background_context) {}

ExtensionBuilder& ExtensionBuilder::AddContentScript(
    const std::string& script_name,
    const std::vector<std::string>& match_patterns) {}

ExtensionBuilder& ExtensionBuilder::SetVersion(const std::string& version) {}

ExtensionBuilder& ExtensionBuilder::SetManifestVersion(int manifest_version) {}

ExtensionBuilder& ExtensionBuilder::AddJSON(std::string_view json) {}

ExtensionBuilder& ExtensionBuilder::SetPath(const base::FilePath& path) {}

ExtensionBuilder& ExtensionBuilder::SetLocation(
    mojom::ManifestLocation location) {}

ExtensionBuilder& ExtensionBuilder::SetManifest(base::Value::Dict manifest) {}

ExtensionBuilder& ExtensionBuilder::MergeManifest(base::Value::Dict to_merge) {}

ExtensionBuilder& ExtensionBuilder::AddFlags(int init_from_value_flags) {}

ExtensionBuilder& ExtensionBuilder::SetID(const std::string& id) {}

void ExtensionBuilder::SetManifestKeyImpl(std::string_view key,
                                          base::Value value) {}

void ExtensionBuilder::SetManifestPathImpl(std::string_view path,
                                           base::Value value) {}

}  // namespace extensions