#ifndef MEDIA_MOJO_MOJOM_CONTENT_DECRYPTION_MODULE_MOJOM_H_
#define MEDIA_MOJO_MOJOM_CONTENT_DECRYPTION_MODULE_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/mojo/mojom/content_decryption_module.mojom-features.h"
#include "media/mojo/mojom/content_decryption_module.mojom-shared.h"
#include "media/mojo/mojom/content_decryption_module.mojom-forward.h"
#include "media/mojo/mojom/decryptor.mojom-forward.h"
#include "media/mojo/mojom/media_types.mojom.h"
#include "mojo/public/mojom/base/unguessable_token.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 "mojo/public/cpp/bindings/lib/native_enum_serialization.h"
#include "mojo/public/cpp/bindings/lib/native_struct_serialization.h"
#include "media/base/ipc/media_param_traits_macros.h"
#include "media/mojo/mojom/cdm_key_information_mojom_traits.h"
namespace media::mojom {
class ContentDecryptionModuleProxy;
template <typename ImplRefTraits>
class ContentDecryptionModuleStub;
class ContentDecryptionModuleRequestValidator;
class ContentDecryptionModuleResponseValidator;
class ContentDecryptionModule
: public ContentDecryptionModuleInterfaceBase { … };
class ContentDecryptionModuleClientProxy;
template <typename ImplRefTraits>
class ContentDecryptionModuleClientStub;
class ContentDecryptionModuleClientRequestValidator;
class ContentDecryptionModuleClient
: public ContentDecryptionModuleClientInterfaceBase { … };
class CdmFactoryProxy;
template <typename ImplRefTraits>
class CdmFactoryStub;
class CdmFactoryRequestValidator;
class CdmFactoryResponseValidator;
class CdmFactory
: public CdmFactoryInterfaceBase { … };
class ContentDecryptionModuleProxy
: public ContentDecryptionModule { … };
class ContentDecryptionModuleClientProxy
: public ContentDecryptionModuleClient { … };
class CdmFactoryProxy
: public CdmFactory { … };
class ContentDecryptionModuleStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<ContentDecryptionModule>>
class ContentDecryptionModuleStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
ContentDecryptionModuleStub() = default;
~ContentDecryptionModuleStub() 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 ContentDecryptionModuleClientStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<ContentDecryptionModuleClient>>
class ContentDecryptionModuleClientStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
ContentDecryptionModuleClientStub() = default;
~ContentDecryptionModuleClientStub() 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 CdmFactoryStubDispatch { … };
template <typename ImplRefTraits =
mojo::RawPtrImplRefTraits<CdmFactory>>
class CdmFactoryStub
: public mojo::MessageReceiverWithResponderStatus {
public:
using ImplPointerType = typename ImplRefTraits::PointerType;
CdmFactoryStub() = default;
~CdmFactoryStub() 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 ContentDecryptionModuleRequestValidator : public mojo::MessageReceiver { … };
class ContentDecryptionModuleClientRequestValidator : public mojo::MessageReceiver { … };
class CdmFactoryRequestValidator : public mojo::MessageReceiver { … };
class ContentDecryptionModuleResponseValidator : public mojo::MessageReceiver { … };
class CdmFactoryResponseValidator : public mojo::MessageReceiver { … };
class CdmPromiseResult { … };
template <typename T, CdmPromiseResult::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, CdmPromiseResult::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, CdmPromiseResult::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, CdmPromiseResult::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class CdmKeyInformation { … };
template <typename T, CdmKeyInformation::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, CdmKeyInformation::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, CdmKeyInformation::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, CdmKeyInformation::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
class CdmContext { … };
template <typename T, CdmContext::EnableIfSame<T>* = nullptr>
bool operator<(const T& lhs, const T& rhs);
template <typename T, CdmContext::EnableIfSame<T>* = nullptr>
bool operator<=(const T& lhs, const T& rhs) { … }
template <typename T, CdmContext::EnableIfSame<T>* = nullptr>
bool operator>(const T& lhs, const T& rhs) { … }
template <typename T, CdmContext::EnableIfSame<T>* = nullptr>
bool operator>=(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
CdmPromiseResultPtr CdmPromiseResult::Clone() const { … }
template <typename T, CdmPromiseResult::EnableIfSame<T>*>
bool CdmPromiseResult::Equals(const T& other_struct) const { … }
template <typename T, CdmPromiseResult::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
CdmKeyInformationPtr CdmKeyInformation::Clone() const { … }
template <typename T, CdmKeyInformation::EnableIfSame<T>*>
bool CdmKeyInformation::Equals(const T& other_struct) const { … }
template <typename T, CdmKeyInformation::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
template <typename StructPtrType>
CdmContextPtr CdmContext::Clone() const { … }
template <typename T, CdmContext::EnableIfSame<T>*>
bool CdmContext::Equals(const T& other_struct) const { … }
template <typename T, CdmContext::EnableIfSame<T>*>
bool operator<(const T& lhs, const T& rhs) { … }
}
namespace mojo {
template <>
struct StructTraits<::media::mojom::CdmPromiseResult::DataView,
::media::mojom::CdmPromiseResultPtr> { … };
template <>
struct StructTraits<::media::mojom::CdmKeyInformation::DataView,
::media::mojom::CdmKeyInformationPtr> { … };
template <>
struct StructTraits<::media::mojom::CdmContext::DataView,
::media::mojom::CdmContextPtr> { … };
}
#endif