#ifndef DEVICE_GAMEPAD_PUBLIC_MOJOM_GAMEPAD_MOJOM_H_
#define DEVICE_GAMEPAD_PUBLIC_MOJOM_GAMEPAD_MOJOM_H_
#include <stdint.h>
#include <limits>
#include <optional>
#include <type_traits>
#include <utility>
#include "base/types/cxx23_to_underlying.h"
#include "mojo/public/cpp/bindings/clone_traits.h"
#include "mojo/public/cpp/bindings/equals_traits.h"
#include "mojo/public/cpp/bindings/lib/serialization.h"
#include "mojo/public/cpp/bindings/struct_ptr.h"
#include "mojo/public/cpp/bindings/struct_traits.h"
#include "mojo/public/cpp/bindings/union_traits.h"
#include "third_party/perfetto/include/perfetto/tracing/traced_value_forward.h"
#include "device/gamepad/public/mojom/gamepad.mojom-features.h"
#include "device/gamepad/public/mojom/gamepad.mojom-shared.h"
#include "device/gamepad/public/mojom/gamepad.mojom-forward.h"
#include "mojo/public/mojom/base/shared_memory.mojom.h"
#include <string>
#include <vector>
#include "mojo/public/cpp/bindings/lib/control_message_handler.h"
#include "mojo/public/cpp/bindings/lib/message_size_estimator.h"
#include "mojo/public/cpp/bindings/raw_ptr_impl_ref_traits.h"
#include "device/gamepad/public/cpp/gamepad_mojom_traits.h"
#include "base/component_export.h"
namespace device::mojom {
class GamepadObserverProxy;
template <typename ImplRefTraits>
class GamepadObserverStub;
class GamepadObserverRequestValidator;
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadObserver
: public GamepadObserverInterfaceBase { … };
class GamepadMonitorProxy;
template <typename ImplRefTraits>
class GamepadMonitorStub;
class GamepadMonitorRequestValidator;
class GamepadMonitorResponseValidator;
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadMonitor
: public GamepadMonitorInterfaceBase { … };
class GamepadHapticsManagerProxy;
template <typename ImplRefTraits>
class GamepadHapticsManagerStub;
class GamepadHapticsManagerRequestValidator;
class GamepadHapticsManagerResponseValidator;
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadHapticsManager
: public GamepadHapticsManagerInterfaceBase { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadObserverProxy
: public GamepadObserver { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadMonitorProxy
: public GamepadMonitor { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadHapticsManagerProxy
: public GamepadHapticsManager { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadObserverStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<GamepadObserver>>
class GamepadObserverStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
GamepadObserverStub() = default;
~GamepadObserverStub() override = default;
void set_sink(ImplPointerType sink) { … }
ImplPointerType& sink() { … }
bool Accept(mojo::Message* message) override { … }
bool AcceptWithResponder(
mojo::Message* message,
std::unique_ptr<mojo::MessageReceiverWithStatus> responder) override { … }
private:
ImplPointerType sink_;
};
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadMonitorStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<GamepadMonitor>>
class GamepadMonitorStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
GamepadMonitorStub() = default;
~GamepadMonitorStub() override = default;
void set_sink(ImplPointerType sink) { … }
ImplPointerType& sink() { … }
bool Accept(mojo::Message* message) override { … }
bool AcceptWithResponder(
mojo::Message* message,
std::unique_ptr<mojo::MessageReceiverWithStatus> responder) override { … }
private:
ImplPointerType sink_;
};
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadHapticsManagerStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<GamepadHapticsManager>>
class GamepadHapticsManagerStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
GamepadHapticsManagerStub() = default;
~GamepadHapticsManagerStub() override = default;
void set_sink(ImplPointerType sink) { … }
ImplPointerType& sink() { … }
bool Accept(mojo::Message* message) override { … }
bool AcceptWithResponder(
mojo::Message* message,
std::unique_ptr<mojo::MessageReceiverWithStatus> responder) override { … }
private:
ImplPointerType sink_;
};
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadObserverRequestValidator : public mojo::MessageReceiver { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadMonitorRequestValidator : public mojo::MessageReceiver { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadHapticsManagerRequestValidator : public mojo::MessageReceiver { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadMonitorResponseValidator : public mojo::MessageReceiver { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadHapticsManagerResponseValidator : public mojo::MessageReceiver { … };
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadQuaternion { … };
template <typename T, GamepadQuaternion::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadQuaternion::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadQuaternion::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadQuaternion::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadVector { … };
template <typename T, GamepadVector::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadVector::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadVector::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadVector::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadButton { … };
template <typename T, GamepadButton::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadButton::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadButton::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadButton::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) AxisChange { … };
template <typename T, AxisChange::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, AxisChange::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, AxisChange::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, AxisChange::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadHapticActuator { … };
template <typename T, GamepadHapticActuator::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadHapticActuator::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadHapticActuator::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadHapticActuator::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) ButtonChange { … };
template <typename T, ButtonChange::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, ButtonChange::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, ButtonChange::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, ButtonChange::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadChanges { … };
template <typename T, GamepadChanges::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadChanges::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadChanges::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadChanges::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadTouch { … };
template <typename T, GamepadTouch::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadTouch::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadTouch::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadTouch::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadPose { … };
template <typename T, GamepadPose::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadPose::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadPose::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadPose::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) Gamepad { … };
template <typename T, Gamepad::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, Gamepad::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, Gamepad::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, Gamepad::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class COMPONENT_EXPORT(GAMEPAD_MOJOM) GamepadEffectParameters { … };
template <typename T, GamepadEffectParameters::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, GamepadEffectParameters::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, GamepadEffectParameters::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, GamepadEffectParameters::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadQuaternionPtr GamepadQuaternion::Clone() const { … }
template <typename T, GamepadQuaternion::EnableIfSame<T>*>
bool GamepadQuaternion::Equals(const T& other_struct) const { … }
template <typename T, GamepadQuaternion::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadVectorPtr GamepadVector::Clone() const { … }
template <typename T, GamepadVector::EnableIfSame<T>*>
bool GamepadVector::Equals(const T& other_struct) const { … }
template <typename T, GamepadVector::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadButtonPtr GamepadButton::Clone() const { … }
template <typename T, GamepadButton::EnableIfSame<T>*>
bool GamepadButton::Equals(const T& other_struct) const { … }
template <typename T, GamepadButton::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
ButtonChangePtr ButtonChange::Clone() const { … }
template <typename T, ButtonChange::EnableIfSame<T>*>
bool ButtonChange::Equals(const T& other_struct) const { … }
template <typename T, ButtonChange::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
AxisChangePtr AxisChange::Clone() const { … }
template <typename T, AxisChange::EnableIfSame<T>*>
bool AxisChange::Equals(const T& other_struct) const { … }
template <typename T, AxisChange::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadChangesPtr GamepadChanges::Clone() const { … }
template <typename T, GamepadChanges::EnableIfSame<T>*>
bool GamepadChanges::Equals(const T& other_struct) const { … }
template <typename T, GamepadChanges::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadTouchPtr GamepadTouch::Clone() const { … }
template <typename T, GamepadTouch::EnableIfSame<T>*>
bool GamepadTouch::Equals(const T& other_struct) const { … }
template <typename T, GamepadTouch::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadPosePtr GamepadPose::Clone() const { … }
template <typename T, GamepadPose::EnableIfSame<T>*>
bool GamepadPose::Equals(const T& other_struct) const { … }
template <typename T, GamepadPose::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadHapticActuatorPtr GamepadHapticActuator::Clone() const { … }
template <typename T, GamepadHapticActuator::EnableIfSame<T>*>
bool GamepadHapticActuator::Equals(const T& other_struct) const { … }
template <typename T, GamepadHapticActuator::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadPtr Gamepad::Clone() const { … }
template <typename T, Gamepad::EnableIfSame<T>*>
bool Gamepad::Equals(const T& other_struct) const { … }
template <typename T, Gamepad::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
GamepadEffectParametersPtr GamepadEffectParameters::Clone() const { … }
template <typename T, GamepadEffectParameters::EnableIfSame<T>*>
bool GamepadEffectParameters::Equals(const T& other_struct) const { … }
template <typename T, GamepadEffectParameters::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
}
namespace mojo {
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadQuaternion::DataView,
::device::mojom::GamepadQuaternionPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadVector::DataView,
::device::mojom::GamepadVectorPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadButton::DataView,
::device::mojom::GamepadButtonPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::ButtonChange::DataView,
::device::mojom::ButtonChangePtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::AxisChange::DataView,
::device::mojom::AxisChangePtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadChanges::DataView,
::device::mojom::GamepadChangesPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadTouch::DataView,
::device::mojom::GamepadTouchPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadPose::DataView,
::device::mojom::GamepadPosePtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadHapticActuator::DataView,
::device::mojom::GamepadHapticActuatorPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::Gamepad::DataView,
::device::mojom::GamepadPtr> { … };
template <>
struct COMPONENT_EXPORT(GAMEPAD_MOJOM) StructTraits<::device::mojom::GamepadEffectParameters::DataView,
::device::mojom::GamepadEffectParametersPtr> { … };
}
#endif