chromium/out/Default/gen/extensions/common/api/storage.cc

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

// GENERATED FROM THE API DEFINITION IN
//   extensions/common/api/storage.json
// by tools/json_schema_compiler.
// DO NOT EDIT.

#include "extensions/common/api/storage.h"

#include <memory>
#include <optional>
#include <ostream>
#include <string>
#include <string_view>
#include <utility>
#include <vector>

#include "base/check.h"
#include "base/check_op.h"
#include "base/notreached.h"
#include "base/strings/string_number_conversions.h"
#include "base/strings/utf_string_conversions.h"
#include "base/values.h"
#include "tools/json_schema_compiler/util.h"
#include <string_view>


UTF8ToUTF16;

namespace extensions {
namespace api {
namespace storage {
//
// Properties
//

namespace sync {
  const int QUOTA_BYTES =;
  const int QUOTA_BYTES_PER_ITEM =;
  const int MAX_ITEMS =;
  const int MAX_WRITE_OPERATIONS_PER_HOUR =;
  const int MAX_WRITE_OPERATIONS_PER_MINUTE =;
  const int MAX_SUSTAINED_WRITE_OPERATIONS_PER_MINUTE =;
}  // namespace sync

namespace local {
  const int QUOTA_BYTES =;
}  // namespace local

namespace session {
  const int QUOTA_BYTES =;
}  // namespace session

//
// Types
//

const char* ToString(AccessLevel enum_param) {}

AccessLevel ParseAccessLevel(std::string_view enum_string) {}

std::u16string GetAccessLevelParseError(std::string_view enum_string) {}


StorageChange::StorageChange()
 {}

StorageChange::~StorageChange() = default;
StorageChange::StorageChange(StorageChange&& rhs) noexcept = default;
StorageChange& StorageChange::operator=(StorageChange&& rhs) noexcept = default;
StorageChange StorageChange::Clone() const {}

// static
bool StorageChange::Populate(
    const base::Value::Dict& dict, StorageChange& out) {}

// static
bool StorageChange::Populate(
    const base::Value& value, StorageChange& out) {}

// static
std::optional<StorageChange> StorageChange::FromValue(const base::Value::Dict& value) {}

// static
std::optional<StorageChange> StorageChange::FromValue(const base::Value& value) {}

base::Value::Dict StorageChange::ToValue() const {}


namespace StorageArea {

namespace Get {

Params::Keys::Object::Object()
 {}

Params::Keys::Object::~Object() = default;
Params::Keys::Object::Object(Object&& rhs) noexcept = default;
Params::Keys::Object& Params::Keys::Object::operator=(Object&& rhs) noexcept = default;
Params::Keys::Object Params::Keys::Object::Clone() const {}

// static
bool Params::Keys::Object::Populate(
    const base::Value::Dict& dict, Object& out) {}

// static
bool Params::Keys::Object::Populate(
    const base::Value& value, Object& out) {}

// static
std::optional<Params::Keys::Object> Params::Keys::Object::FromValue(const base::Value::Dict& value) {}

// static
std::optional<Params::Keys::Object> Params::Keys::Object::FromValue(const base::Value& value) {}



Params::Keys::Keys()
 {}

Params::Keys::~Keys() = default;
Params::Keys::Keys(Keys&& rhs) noexcept = default;
Params::Keys& Params::Keys::operator=(Keys&& rhs) noexcept = default;
Params::Keys Params::Keys::Clone() const {}

// static
bool Params::Keys::Populate(
    const base::Value& value, Keys& out) {}

// static
std::optional<Params::Keys> Params::Keys::FromValue(const base::Value& value) {}


Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;

// static
std::optional<Params> Params::Create(const base::Value::List& args) {}


Results::Items::Items()
 {}

Results::Items::~Items() = default;
Results::Items::Items(Items&& rhs) noexcept = default;
Results::Items& Results::Items::operator=(Items&& rhs) noexcept = default;
base::Value::Dict Results::Items::ToValue() const {}


base::Value::List Results::Create(const Items& items) {}
}  // namespace Get

namespace GetKeys {

base::Value::List Results::Create(const std::vector<std::string>& keys) {}
}  // namespace GetKeys

namespace GetBytesInUse {

Params::Keys::Keys()
 {}

Params::Keys::~Keys() = default;
Params::Keys::Keys(Keys&& rhs) noexcept = default;
Params::Keys& Params::Keys::operator=(Keys&& rhs) noexcept = default;
Params::Keys Params::Keys::Clone() const {}

// static
bool Params::Keys::Populate(
    const base::Value& value, Keys& out) {}

// static
std::optional<Params::Keys> Params::Keys::FromValue(const base::Value& value) {}


Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;

// static
std::optional<Params> Params::Create(const base::Value::List& args) {}


base::Value::List Results::Create(double bytes_in_use) {}
}  // namespace GetBytesInUse

namespace Set {

Params::Items::Items()
 {}

Params::Items::~Items() = default;
Params::Items::Items(Items&& rhs) noexcept = default;
Params::Items& Params::Items::operator=(Items&& rhs) noexcept = default;
Params::Items Params::Items::Clone() const {}

// static
bool Params::Items::Populate(
    const base::Value::Dict& dict, Items& out) {}

// static
bool Params::Items::Populate(
    const base::Value& value, Items& out) {}

// static
std::optional<Params::Items> Params::Items::FromValue(const base::Value::Dict& value) {}

// static
std::optional<Params::Items> Params::Items::FromValue(const base::Value& value) {}


Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;

// static
std::optional<Params> Params::Create(const base::Value::List& args) {}


base::Value::List Results::Create() {}
}  // namespace Set

namespace Remove {

Params::Keys::Keys()
 {}

Params::Keys::~Keys() = default;
Params::Keys::Keys(Keys&& rhs) noexcept = default;
Params::Keys& Params::Keys::operator=(Keys&& rhs) noexcept = default;
Params::Keys Params::Keys::Clone() const {}

// static
bool Params::Keys::Populate(
    const base::Value& value, Keys& out) {}

// static
std::optional<Params::Keys> Params::Keys::FromValue(const base::Value& value) {}


Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;

// static
std::optional<Params> Params::Create(const base::Value::List& args) {}


base::Value::List Results::Create() {}
}  // namespace Remove

namespace Clear {

base::Value::List Results::Create() {}
}  // namespace Clear

namespace SetAccessLevel {

Params::AccessOptions::AccessOptions()
:{}

Params::AccessOptions::~AccessOptions() = default;
Params::AccessOptions::AccessOptions(AccessOptions&& rhs) noexcept = default;
Params::AccessOptions& Params::AccessOptions::operator=(AccessOptions&& rhs) noexcept = default;
Params::AccessOptions Params::AccessOptions::Clone() const {}

// static
bool Params::AccessOptions::Populate(
    const base::Value::Dict& dict, AccessOptions& out) {}

// static
bool Params::AccessOptions::Populate(
    const base::Value& value, AccessOptions& out) {}

// static
std::optional<Params::AccessOptions> Params::AccessOptions::FromValue(const base::Value::Dict& value) {}

// static
std::optional<Params::AccessOptions> Params::AccessOptions::FromValue(const base::Value& value) {}


Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;

// static
std::optional<Params> Params::Create(const base::Value::List& args) {}


base::Value::List Results::Create() {}
}  // namespace SetAccessLevel

}  // namespace StorageArea


//
// Events
//

namespace OnChanged {

const char kEventName[] =;

Changes::Changes()
 {}

Changes::~Changes() = default;
Changes::Changes(Changes&& rhs) noexcept = default;
Changes& Changes::operator=(Changes&& rhs) noexcept = default;
base::Value::Dict Changes::ToValue() const {}


base::Value::List Create(const Changes& changes, const std::string& area_name) {}

}  // namespace OnChanged

}  // namespace storage
}  // namespace api
}  // namespace extensions