chromium/out/Default/gen/extensions/common/api/bluetooth_private.h

// 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/bluetooth_private.idl
// by tools/json_schema_compiler.
// DO NOT EDIT.

#ifndef EXTENSIONS_COMMON_API_BLUETOOTH_PRIVATE_H__
#define EXTENSIONS_COMMON_API_BLUETOOTH_PRIVATE_H__

#include <stdint.h>

#include <map>
#include <memory>
#include <optional>
#include <string>
#include <vector>

#include "base/values.h"
#include <string_view>
#include "extensions/common/api/bluetooth.h"


namespace extensions {
namespace api {
namespace bluetooth_private {

//
// Types
//

// Events that can occur during pairing. The method used for pairing varies
// depending on the capability of the two devices.
enum class PairingEventType {};


const char* ToString(PairingEventType as_enum);
PairingEventType ParsePairingEventType(std::string_view as_string);
std::u16string GetPairingEventTypeParseError(std::string_view as_string);

// Results for connect(). See function declaration for details.
enum class ConnectResultType {};


const char* ToString(ConnectResultType as_enum);
ConnectResultType ParseConnectResultType(std::string_view as_string);
std::u16string GetConnectResultTypeParseError(std::string_view as_string);

// Valid pairing responses.
enum class PairingResponse {};


const char* ToString(PairingResponse as_enum);
PairingResponse ParsePairingResponse(std::string_view as_string);
std::u16string GetPairingResponseParseError(std::string_view as_string);

enum class TransportType {};


const char* ToString(TransportType as_enum);
TransportType ParseTransportType(std::string_view as_string);
std::u16string GetTransportTypeParseError(std::string_view as_string);

struct PairingEvent {};

struct NewAdapterState {};

struct SetPairingResponseOptions {};

struct DiscoveryFilter {};


//
// Functions
//

namespace SetAdapterState {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace SetAdapterState

namespace SetPairingResponse {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace SetPairingResponse

namespace DisconnectAll {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace DisconnectAll

namespace ForgetDevice {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace ForgetDevice

namespace SetDiscoveryFilter {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace SetDiscoveryFilter

namespace Connect {

struct Params {};

namespace Results {

base::Value::List Create(const ConnectResultType& result);
}  // namespace Results

}  // namespace Connect

namespace Pair {

struct Params {};

namespace Results {

base::Value::List Create();
}  // namespace Results

}  // namespace Pair

namespace RecordPairing {

struct Params {};

}  // namespace RecordPairing

namespace RecordReconnection {

struct Params {};

}  // namespace RecordReconnection

namespace RecordDeviceSelection {

struct Params {};

}  // namespace RecordDeviceSelection

//
// Events
//

namespace OnPairing {

extern const char kEventName[];  // "bluetoothPrivate.onPairing"

// A pairing event.
base::Value::List Create(const PairingEvent& pairing_event);
}  // namespace OnPairing

namespace OnDeviceAddressChanged {

extern const char kEventName[];  // "bluetoothPrivate.onDeviceAddressChanged"

base::Value::List Create(const extensions::api::bluetooth::Device& device, const std::string& old_address);
}  // namespace OnDeviceAddressChanged

}  // namespace bluetooth_private
}  // namespace api
}  // namespace extensions

#endif  // EXTENSIONS_COMMON_API_BLUETOOTH_PRIVATE_H__