#ifndef MEDIA_MIDI_MIDI_SERVICE_MOJOM_H_
#define MEDIA_MIDI_MIDI_SERVICE_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 "media/midi/midi_service.mojom-features.h"
#include "media/midi/midi_service.mojom-shared.h"
#include "media/midi/midi_service.mojom-forward.h"
#include "mojo/public/mojom/base/time.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"
namespace midi::mojom {
class MidiSessionClientProxy;
template <typename ImplRefTraits>
class MidiSessionClientStub;
class MidiSessionClientRequestValidator;
class MidiSessionClient
: public MidiSessionClientInterfaceBase { … };
class MidiSessionProviderProxy;
template <typename ImplRefTraits>
class MidiSessionProviderStub;
class MidiSessionProviderRequestValidator;
class MidiSessionProvider
: public MidiSessionProviderInterfaceBase { … };
class MidiSessionProxy;
template <typename ImplRefTraits>
class MidiSessionStub;
class MidiSessionRequestValidator;
class MidiSession
: public MidiSessionInterfaceBase { … };
class MidiSessionClientProxy
: public MidiSessionClient { … };
class MidiSessionProviderProxy
: public MidiSessionProvider { … };
class MidiSessionProxy
: public MidiSession { … };
class MidiSessionClientStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<MidiSessionClient>>
class MidiSessionClientStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
MidiSessionClientStub() = default;
~MidiSessionClientStub() 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 MidiSessionProviderStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<MidiSessionProvider>>
class MidiSessionProviderStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
MidiSessionProviderStub() = default;
~MidiSessionProviderStub() 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 MidiSessionStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<MidiSession>>
class MidiSessionStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
MidiSessionStub() = default;
~MidiSessionStub() 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 MidiSessionClientRequestValidator : public mojo::MessageReceiver { … };
class MidiSessionProviderRequestValidator : public mojo::MessageReceiver { … };
class MidiSessionRequestValidator : public mojo::MessageReceiver { … };
class PortInfo { … };
template <typename T, PortInfo::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, PortInfo::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, PortInfo::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, PortInfo::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
PortInfoPtr PortInfo::Clone() const { … }
template <typename T, PortInfo::EnableIfSame<T>*>
bool PortInfo::Equals(const T& other_struct) const { … }
template <typename T, PortInfo::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
}
namespace mojo {
template <>
struct StructTraits<::midi::mojom::PortInfo::DataView,
::midi::mojom::PortInfoPtr> { … };
}
#endif