#include "extensions/common/api/socket.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 socket {
const char* ToString(SocketType enum_param) { … }
SocketType ParseSocketType(std::string_view enum_string) { … }
std::u16string GetSocketTypeParseError(std::string_view enum_string) { … }
CreateOptions::CreateOptions()
{ … }
CreateOptions::~CreateOptions() = default;
CreateOptions::CreateOptions(CreateOptions&& rhs) noexcept = default;
CreateOptions& CreateOptions::operator=(CreateOptions&& rhs) noexcept = default;
CreateOptions CreateOptions::Clone() const { … }
bool CreateOptions::Populate(
const base::Value::Dict& dict, CreateOptions& out) { … }
bool CreateOptions::Populate(
const base::Value& value, CreateOptions& out) { … }
std::optional<CreateOptions> CreateOptions::FromValue(const base::Value::Dict& value) { … }
std::optional<CreateOptions> CreateOptions::FromValue(const base::Value& value) { … }
base::Value::Dict CreateOptions::ToValue() const { … }
CreateInfo::CreateInfo()
: … { … }
CreateInfo::~CreateInfo() = default;
CreateInfo::CreateInfo(CreateInfo&& rhs) noexcept = default;
CreateInfo& CreateInfo::operator=(CreateInfo&& rhs) noexcept = default;
CreateInfo CreateInfo::Clone() const { … }
bool CreateInfo::Populate(
const base::Value::Dict& dict, CreateInfo& out) { … }
bool CreateInfo::Populate(
const base::Value& value, CreateInfo& out) { … }
std::optional<CreateInfo> CreateInfo::FromValue(const base::Value::Dict& value) { … }
std::optional<CreateInfo> CreateInfo::FromValue(const base::Value& value) { … }
base::Value::Dict CreateInfo::ToValue() const { … }
AcceptInfo::AcceptInfo()
: … { … }
AcceptInfo::~AcceptInfo() = default;
AcceptInfo::AcceptInfo(AcceptInfo&& rhs) noexcept = default;
AcceptInfo& AcceptInfo::operator=(AcceptInfo&& rhs) noexcept = default;
AcceptInfo AcceptInfo::Clone() const { … }
bool AcceptInfo::Populate(
const base::Value::Dict& dict, AcceptInfo& out) { … }
bool AcceptInfo::Populate(
const base::Value& value, AcceptInfo& out) { … }
std::optional<AcceptInfo> AcceptInfo::FromValue(const base::Value::Dict& value) { … }
std::optional<AcceptInfo> AcceptInfo::FromValue(const base::Value& value) { … }
base::Value::Dict AcceptInfo::ToValue() const { … }
ReadInfo::ReadInfo()
: … { … }
ReadInfo::~ReadInfo() = default;
ReadInfo::ReadInfo(ReadInfo&& rhs) noexcept = default;
ReadInfo& ReadInfo::operator=(ReadInfo&& rhs) noexcept = default;
ReadInfo ReadInfo::Clone() const { … }
bool ReadInfo::Populate(
const base::Value::Dict& dict, ReadInfo& out) { … }
bool ReadInfo::Populate(
const base::Value& value, ReadInfo& out) { … }
std::optional<ReadInfo> ReadInfo::FromValue(const base::Value::Dict& value) { … }
std::optional<ReadInfo> ReadInfo::FromValue(const base::Value& value) { … }
base::Value::Dict ReadInfo::ToValue() const { … }
WriteInfo::WriteInfo()
: … { … }
WriteInfo::~WriteInfo() = default;
WriteInfo::WriteInfo(WriteInfo&& rhs) noexcept = default;
WriteInfo& WriteInfo::operator=(WriteInfo&& rhs) noexcept = default;
WriteInfo WriteInfo::Clone() const { … }
bool WriteInfo::Populate(
const base::Value::Dict& dict, WriteInfo& out) { … }
bool WriteInfo::Populate(
const base::Value& value, WriteInfo& out) { … }
std::optional<WriteInfo> WriteInfo::FromValue(const base::Value::Dict& value) { … }
std::optional<WriteInfo> WriteInfo::FromValue(const base::Value& value) { … }
base::Value::Dict WriteInfo::ToValue() const { … }
RecvFromInfo::RecvFromInfo()
: … { … }
RecvFromInfo::~RecvFromInfo() = default;
RecvFromInfo::RecvFromInfo(RecvFromInfo&& rhs) noexcept = default;
RecvFromInfo& RecvFromInfo::operator=(RecvFromInfo&& rhs) noexcept = default;
RecvFromInfo RecvFromInfo::Clone() const { … }
bool RecvFromInfo::Populate(
const base::Value::Dict& dict, RecvFromInfo& out) { … }
bool RecvFromInfo::Populate(
const base::Value& value, RecvFromInfo& out) { … }
std::optional<RecvFromInfo> RecvFromInfo::FromValue(const base::Value::Dict& value) { … }
std::optional<RecvFromInfo> RecvFromInfo::FromValue(const base::Value& value) { … }
base::Value::Dict RecvFromInfo::ToValue() const { … }
SocketInfo::SocketInfo()
: … { … }
SocketInfo::~SocketInfo() = default;
SocketInfo::SocketInfo(SocketInfo&& rhs) noexcept = default;
SocketInfo& SocketInfo::operator=(SocketInfo&& rhs) noexcept = default;
SocketInfo SocketInfo::Clone() const { … }
bool SocketInfo::Populate(
const base::Value::Dict& dict, SocketInfo& out) { … }
bool SocketInfo::Populate(
const base::Value& value, SocketInfo& out) { … }
std::optional<SocketInfo> SocketInfo::FromValue(const base::Value::Dict& value) { … }
std::optional<SocketInfo> SocketInfo::FromValue(const base::Value& value) { … }
base::Value::Dict SocketInfo::ToValue() const { … }
NetworkInterface::NetworkInterface()
: … { … }
NetworkInterface::~NetworkInterface() = default;
NetworkInterface::NetworkInterface(NetworkInterface&& rhs) noexcept = default;
NetworkInterface& NetworkInterface::operator=(NetworkInterface&& rhs) noexcept = default;
NetworkInterface NetworkInterface::Clone() const { … }
bool NetworkInterface::Populate(
const base::Value::Dict& dict, NetworkInterface& out) { … }
bool NetworkInterface::Populate(
const base::Value& value, NetworkInterface& out) { … }
std::optional<NetworkInterface> NetworkInterface::FromValue(const base::Value::Dict& value) { … }
std::optional<NetworkInterface> NetworkInterface::FromValue(const base::Value& value) { … }
base::Value::Dict NetworkInterface::ToValue() const { … }
TLSVersionConstraints::TLSVersionConstraints()
{ … }
TLSVersionConstraints::~TLSVersionConstraints() = default;
TLSVersionConstraints::TLSVersionConstraints(TLSVersionConstraints&& rhs) noexcept = default;
TLSVersionConstraints& TLSVersionConstraints::operator=(TLSVersionConstraints&& rhs) noexcept = default;
TLSVersionConstraints TLSVersionConstraints::Clone() const { … }
bool TLSVersionConstraints::Populate(
const base::Value::Dict& dict, TLSVersionConstraints& out) { … }
bool TLSVersionConstraints::Populate(
const base::Value& value, TLSVersionConstraints& out) { … }
std::optional<TLSVersionConstraints> TLSVersionConstraints::FromValue(const base::Value::Dict& value) { … }
std::optional<TLSVersionConstraints> TLSVersionConstraints::FromValue(const base::Value& value) { … }
base::Value::Dict TLSVersionConstraints::ToValue() const { … }
SecureOptions::SecureOptions()
{ … }
SecureOptions::~SecureOptions() = default;
SecureOptions::SecureOptions(SecureOptions&& rhs) noexcept = default;
SecureOptions& SecureOptions::operator=(SecureOptions&& rhs) noexcept = default;
SecureOptions SecureOptions::Clone() const { … }
bool SecureOptions::Populate(
const base::Value::Dict& dict, SecureOptions& out) { … }
bool SecureOptions::Populate(
const base::Value& value, SecureOptions& out) { … }
std::optional<SecureOptions> SecureOptions::FromValue(const base::Value::Dict& value) { … }
std::optional<SecureOptions> SecureOptions::FromValue(const base::Value& value) { … }
base::Value::Dict SecureOptions::ToValue() const { … }
namespace Create {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const CreateInfo& create_info) { … }
}
namespace Destroy {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
}
namespace Connect {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace Bind {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace Disconnect {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
}
namespace Read {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const ReadInfo& read_info) { … }
}
namespace Write {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const WriteInfo& write_info) { … }
}
namespace RecvFrom {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const RecvFromInfo& recv_from_info) { … }
}
namespace SendTo {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const WriteInfo& write_info) { … }
}
namespace Listen {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace Accept {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const AcceptInfo& accept_info) { … }
}
namespace SetKeepAlive {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(bool result) { … }
}
namespace SetNoDelay {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(bool result) { … }
}
namespace GetInfo {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const SocketInfo& result) { … }
}
namespace GetNetworkList {
base::Value::List Results::Create(const std::vector<NetworkInterface>& result) { … }
}
namespace JoinGroup {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace LeaveGroup {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace SetMulticastTimeToLive {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace SetMulticastLoopbackMode {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
namespace GetJoinedGroups {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(const std::vector<std::string>& groups) { … }
}
namespace Secure {
Params::Params() = default;
Params::~Params() = default;
Params::Params(Params&& rhs) noexcept = default;
Params& Params::operator=(Params&& rhs) noexcept = default;
std::optional<Params> Params::Create(const base::Value::List& args) { … }
base::Value::List Results::Create(int result) { … }
}
}
}
}