| // services/network/public/mojom/cross_origin_opener_policy.mojom.h is auto generated by mojom_bindings_generator.py, do not edit |
| |
| // Copyright 2013 The Chromium Authors. All rights reserved. |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| #ifndef SERVICES_NETWORK_PUBLIC_MOJOM_CROSS_ORIGIN_OPENER_POLICY_MOJOM_H_ |
| #define SERVICES_NETWORK_PUBLIC_MOJOM_CROSS_ORIGIN_OPENER_POLICY_MOJOM_H_ |
| |
| #include <stdint.h> |
| |
| #include <limits> |
| #include <type_traits> |
| #include <utility> |
| |
| #include "third_party/abseil-cpp/absl/types/optional.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 "services/network/public/mojom/cross_origin_opener_policy.mojom-shared.h" |
| #include "services/network/public/mojom/cross_origin_opener_policy.mojom-forward.h" |
| #include "url/mojom/url.mojom-forward.h" |
| #include "mojo/public/mojom/base/unguessable_token.mojom-forward.h" |
| #include "services/network/public/mojom/source_location.mojom-forward.h" |
| #include <string> |
| #include <vector> |
| |
| #include "mojo/public/cpp/bindings/lib/control_message_handler.h" |
| #include "mojo/public/cpp/bindings/raw_ptr_impl_ref_traits.h" |
| |
| |
| #include "services/network/public/cpp/cross_origin_opener_policy_mojom_traits.h" |
| |
| #ifdef KYTHE_IS_RUNNING |
| #pragma kythe_inline_metadata "Metadata comment" |
| #endif |
| |
| |
| namespace network { |
| namespace mojom { |
| |
| class CrossOriginOpenerPolicyReporterProxy; |
| |
| template <typename ImplRefTraits> |
| class CrossOriginOpenerPolicyReporterStub; |
| |
| class CrossOriginOpenerPolicyReporterRequestValidator; |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporter |
| class CrossOriginOpenerPolicyReporter |
| : public CrossOriginOpenerPolicyReporterInterfaceBase { |
| public: |
| static const char Name_[]; |
| static uint32_t MessageToStableIPCHash_(mojo::Message& message); |
| static const char* MessageToMethodName_(mojo::Message& message); |
| static constexpr uint32_t Version_ = 0; |
| static constexpr bool PassesAssociatedKinds_ = false; |
| static constexpr bool HasSyncMethods_ = false; |
| static constexpr bool HasUninterruptableMethods_ = false; |
| |
| using Base_ = CrossOriginOpenerPolicyReporterInterfaceBase; |
| using Proxy_ = CrossOriginOpenerPolicyReporterProxy; |
| |
| template <typename ImplRefTraits> |
| using Stub_ = CrossOriginOpenerPolicyReporterStub<ImplRefTraits>; |
| |
| using RequestValidator_ = CrossOriginOpenerPolicyReporterRequestValidator; |
| using ResponseValidator_ = mojo::PassThroughFilter; |
| enum MethodMinVersions : uint32_t { |
| kQueueAccessReportMinVersion = 0, |
| }; |
| virtual ~CrossOriginOpenerPolicyReporter() = default; |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporter.QueueAccessReport |
| virtual void QueueAccessReport(CoopAccessReportType report_type, const std::string& property, ::network::mojom::SourceLocationPtr source_location, const std::string& reported_window_url) = 0; |
| }; |
| |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporter |
| class CrossOriginOpenerPolicyReporterProxy |
| : public CrossOriginOpenerPolicyReporter { |
| public: |
| using InterfaceType = CrossOriginOpenerPolicyReporter; |
| |
| explicit CrossOriginOpenerPolicyReporterProxy(mojo::MessageReceiverWithResponder* receiver); |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporter.QueueAccessReport |
| void QueueAccessReport(CoopAccessReportType report_type, const std::string& property, ::network::mojom::SourceLocationPtr source_location, const std::string& reported_window_url) final; |
| |
| private: |
| mojo::MessageReceiverWithResponder* receiver_; |
| }; |
| class CrossOriginOpenerPolicyReporterStubDispatch { |
| public: |
| static bool Accept(CrossOriginOpenerPolicyReporter* impl, mojo::Message* message); |
| static bool AcceptWithResponder( |
| CrossOriginOpenerPolicyReporter* impl, |
| mojo::Message* message, |
| std::unique_ptr<mojo::MessageReceiverWithStatus> responder); |
| }; |
| |
| template <typename ImplRefTraits = |
| mojo::RawPtrImplRefTraits<CrossOriginOpenerPolicyReporter>> |
| class CrossOriginOpenerPolicyReporterStub |
| : public mojo::MessageReceiverWithResponderStatus { |
| public: |
| using ImplPointerType = typename ImplRefTraits::PointerType; |
| |
| CrossOriginOpenerPolicyReporterStub() = default; |
| ~CrossOriginOpenerPolicyReporterStub() override = default; |
| |
| void set_sink(ImplPointerType sink) { sink_ = std::move(sink); } |
| ImplPointerType& sink() { return sink_; } |
| |
| bool Accept(mojo::Message* message) override { |
| if (ImplRefTraits::IsNull(sink_)) |
| return false; |
| return CrossOriginOpenerPolicyReporterStubDispatch::Accept( |
| ImplRefTraits::GetRawPointer(&sink_), message); |
| } |
| |
| bool AcceptWithResponder( |
| mojo::Message* message, |
| std::unique_ptr<mojo::MessageReceiverWithStatus> responder) override { |
| if (ImplRefTraits::IsNull(sink_)) |
| return false; |
| return CrossOriginOpenerPolicyReporterStubDispatch::AcceptWithResponder( |
| ImplRefTraits::GetRawPointer(&sink_), message, std::move(responder)); |
| } |
| |
| private: |
| ImplPointerType sink_; |
| }; |
| class CrossOriginOpenerPolicyReporterRequestValidator : public mojo::MessageReceiver { |
| public: |
| bool Accept(mojo::Message* message) override; |
| }; |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporterParams |
| class CrossOriginOpenerPolicyReporterParams { |
| public: |
| template <typename T> |
| using EnableIfSame = std::enable_if_t<std::is_same<CrossOriginOpenerPolicyReporterParams, T>::value>; |
| using DataView = CrossOriginOpenerPolicyReporterParamsDataView; |
| using Data_ = internal::CrossOriginOpenerPolicyReporterParams_Data; |
| |
| template <typename... Args> |
| static CrossOriginOpenerPolicyReporterParamsPtr New(Args&&... args) { |
| return CrossOriginOpenerPolicyReporterParamsPtr( |
| absl::in_place, std::forward<Args>(args)...); |
| } |
| |
| template <typename U> |
| static CrossOriginOpenerPolicyReporterParamsPtr From(const U& u) { |
| return mojo::TypeConverter<CrossOriginOpenerPolicyReporterParamsPtr, U>::Convert(u); |
| } |
| |
| template <typename U> |
| U To() const { |
| return mojo::TypeConverter<U, CrossOriginOpenerPolicyReporterParams>::Convert(*this); |
| } |
| |
| |
| CrossOriginOpenerPolicyReporterParams(); |
| |
| CrossOriginOpenerPolicyReporterParams( |
| CoopAccessReportType report_type, |
| ::mojo::PendingRemote<CrossOriginOpenerPolicyReporter> reporter, |
| bool endpoint_defined, |
| const std::string& reported_window_url); |
| |
| CrossOriginOpenerPolicyReporterParams(const CrossOriginOpenerPolicyReporterParams&) = delete; |
| CrossOriginOpenerPolicyReporterParams& operator=(const CrossOriginOpenerPolicyReporterParams&) = delete; |
| |
| ~CrossOriginOpenerPolicyReporterParams(); |
| |
| // Clone() is a template so it is only instantiated if it is used. Thus, the |
| // bindings generator does not need to know whether Clone() or copy |
| // constructor/assignment are available for members. |
| template <typename StructPtrType = CrossOriginOpenerPolicyReporterParamsPtr> |
| CrossOriginOpenerPolicyReporterParamsPtr Clone() const; |
| |
| // Equals() is a template so it is only instantiated if it is used. Thus, the |
| // bindings generator does not need to know whether Equals() or == operator |
| // are available for members. |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>* = nullptr> |
| bool Equals(const T& other) const; |
| |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>* = nullptr> |
| bool operator==(const T& rhs) const { return Equals(rhs); } |
| |
| template <typename UserType> |
| static mojo::Message SerializeAsMessage(UserType* input) { |
| return mojo::internal::SerializeAsMessageImpl< |
| CrossOriginOpenerPolicyReporterParams::DataView>(input); |
| } |
| |
| // The returned Message is serialized only if the message is moved |
| // cross-process or cross-language. Otherwise if the message is Deserialized |
| // as the same UserType |input| will just be moved to |output| in |
| // DeserializeFromMessage. |
| template <typename UserType> |
| static mojo::Message WrapAsMessage(UserType input) { |
| return mojo::Message(std::make_unique< |
| internal::CrossOriginOpenerPolicyReporterParams_UnserializedMessageContext< |
| UserType, CrossOriginOpenerPolicyReporterParams::DataView>>(0, 0, std::move(input)), |
| MOJO_CREATE_MESSAGE_FLAG_NONE); |
| } |
| |
| template <typename UserType> |
| static bool Deserialize(const void* data, |
| size_t data_num_bytes, |
| UserType* output) { |
| mojo::Message message; |
| return mojo::internal::DeserializeImpl<CrossOriginOpenerPolicyReporterParams::DataView>( |
| message, data, data_num_bytes, output, Validate); |
| } |
| |
| template <typename UserType> |
| static bool Deserialize(const std::vector<uint8_t>& input, |
| UserType* output) { |
| return CrossOriginOpenerPolicyReporterParams::Deserialize( |
| input.size() == 0 ? nullptr : &input.front(), input.size(), output); |
| } |
| |
| template <typename UserType> |
| static bool DeserializeFromMessage(mojo::Message input, |
| UserType* output) { |
| auto context = input.TakeUnserializedContext< |
| internal::CrossOriginOpenerPolicyReporterParams_UnserializedMessageContext< |
| UserType, CrossOriginOpenerPolicyReporterParams::DataView>>(); |
| if (context) { |
| *output = std::move(context->TakeData()); |
| return true; |
| } |
| input.SerializeIfNecessary(); |
| return mojo::internal::DeserializeImpl<CrossOriginOpenerPolicyReporterParams::DataView>( |
| input, input.payload(), input.payload_num_bytes(), output, Validate); |
| } |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporterParams.report_type |
| CoopAccessReportType report_type; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporterParams.reporter |
| ::mojo::PendingRemote<CrossOriginOpenerPolicyReporter> reporter; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporterParams.endpoint_defined |
| bool endpoint_defined; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicyReporterParams.reported_window_url |
| std::string reported_window_url; |
| |
| // Serialise this struct into a trace. |
| void WriteIntoTrace(perfetto::TracedValue traced_context) const; |
| |
| private: |
| static bool Validate(const void* data, |
| mojo::internal::ValidationContext* validation_context); |
| }; |
| |
| // The comparison operators are templates, so they are only instantiated if they |
| // are used. Thus, the bindings generator does not need to know whether |
| // comparison operators are available for members. |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>* = nullptr> |
| bool operator<(const T& lhs, const T& rhs); |
| |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>* = nullptr> |
| bool operator<=(const T& lhs, const T& rhs) { |
| return !(rhs < lhs); |
| } |
| |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>* = nullptr> |
| bool operator>(const T& lhs, const T& rhs) { |
| return rhs < lhs; |
| } |
| |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>* = nullptr> |
| bool operator>=(const T& lhs, const T& rhs) { |
| return !(lhs < rhs); |
| } |
| |
| |
| |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicy |
| class CrossOriginOpenerPolicy { |
| public: |
| template <typename T> |
| using EnableIfSame = std::enable_if_t<std::is_same<CrossOriginOpenerPolicy, T>::value>; |
| using DataView = CrossOriginOpenerPolicyDataView; |
| using Data_ = internal::CrossOriginOpenerPolicy_Data; |
| |
| template <typename... Args> |
| static CrossOriginOpenerPolicyPtr New(Args&&... args) { |
| return CrossOriginOpenerPolicyPtr( |
| absl::in_place, std::forward<Args>(args)...); |
| } |
| |
| template <typename U> |
| static CrossOriginOpenerPolicyPtr From(const U& u) { |
| return mojo::TypeConverter<CrossOriginOpenerPolicyPtr, U>::Convert(u); |
| } |
| |
| template <typename U> |
| U To() const { |
| return mojo::TypeConverter<U, CrossOriginOpenerPolicy>::Convert(*this); |
| } |
| |
| |
| CrossOriginOpenerPolicy(); |
| |
| CrossOriginOpenerPolicy( |
| CrossOriginOpenerPolicyValue value, |
| const absl::optional<std::string>& reporting_endpoint, |
| CrossOriginOpenerPolicyValue report_only_value, |
| const absl::optional<std::string>& report_only_reporting_endpoint, |
| CrossOriginOpenerPolicyValue soap_by_default_value); |
| |
| |
| ~CrossOriginOpenerPolicy(); |
| |
| // Clone() is a template so it is only instantiated if it is used. Thus, the |
| // bindings generator does not need to know whether Clone() or copy |
| // constructor/assignment are available for members. |
| template <typename StructPtrType = CrossOriginOpenerPolicyPtr> |
| CrossOriginOpenerPolicyPtr Clone() const; |
| |
| // Equals() is a template so it is only instantiated if it is used. Thus, the |
| // bindings generator does not need to know whether Equals() or == operator |
| // are available for members. |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>* = nullptr> |
| bool Equals(const T& other) const; |
| |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>* = nullptr> |
| bool operator==(const T& rhs) const { return Equals(rhs); } |
| template <typename UserType> |
| static std::vector<uint8_t> Serialize(UserType* input) { |
| return mojo::internal::SerializeImpl< |
| CrossOriginOpenerPolicy::DataView, std::vector<uint8_t>>(input); |
| } |
| |
| template <typename UserType> |
| static mojo::Message SerializeAsMessage(UserType* input) { |
| return mojo::internal::SerializeAsMessageImpl< |
| CrossOriginOpenerPolicy::DataView>(input); |
| } |
| |
| // The returned Message is serialized only if the message is moved |
| // cross-process or cross-language. Otherwise if the message is Deserialized |
| // as the same UserType |input| will just be moved to |output| in |
| // DeserializeFromMessage. |
| template <typename UserType> |
| static mojo::Message WrapAsMessage(UserType input) { |
| return mojo::Message(std::make_unique< |
| internal::CrossOriginOpenerPolicy_UnserializedMessageContext< |
| UserType, CrossOriginOpenerPolicy::DataView>>(0, 0, std::move(input)), |
| MOJO_CREATE_MESSAGE_FLAG_NONE); |
| } |
| |
| template <typename UserType> |
| static bool Deserialize(const void* data, |
| size_t data_num_bytes, |
| UserType* output) { |
| mojo::Message message; |
| return mojo::internal::DeserializeImpl<CrossOriginOpenerPolicy::DataView>( |
| message, data, data_num_bytes, output, Validate); |
| } |
| |
| template <typename UserType> |
| static bool Deserialize(const std::vector<uint8_t>& input, |
| UserType* output) { |
| return CrossOriginOpenerPolicy::Deserialize( |
| input.size() == 0 ? nullptr : &input.front(), input.size(), output); |
| } |
| |
| template <typename UserType> |
| static bool DeserializeFromMessage(mojo::Message input, |
| UserType* output) { |
| auto context = input.TakeUnserializedContext< |
| internal::CrossOriginOpenerPolicy_UnserializedMessageContext< |
| UserType, CrossOriginOpenerPolicy::DataView>>(); |
| if (context) { |
| *output = std::move(context->TakeData()); |
| return true; |
| } |
| input.SerializeIfNecessary(); |
| return mojo::internal::DeserializeImpl<CrossOriginOpenerPolicy::DataView>( |
| input, input.payload(), input.payload_num_bytes(), output, Validate); |
| } |
| |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicy.value |
| CrossOriginOpenerPolicyValue value; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicy.reporting_endpoint |
| absl::optional<std::string> reporting_endpoint; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicy.report_only_value |
| CrossOriginOpenerPolicyValue report_only_value; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicy.report_only_reporting_endpoint |
| absl::optional<std::string> report_only_reporting_endpoint; |
| |
| // @generated_from: network.mojom.CrossOriginOpenerPolicy.soap_by_default_value |
| CrossOriginOpenerPolicyValue soap_by_default_value; |
| |
| // Serialise this struct into a trace. |
| void WriteIntoTrace(perfetto::TracedValue traced_context) const; |
| |
| private: |
| static bool Validate(const void* data, |
| mojo::internal::ValidationContext* validation_context); |
| }; |
| |
| // The comparison operators are templates, so they are only instantiated if they |
| // are used. Thus, the bindings generator does not need to know whether |
| // comparison operators are available for members. |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>* = nullptr> |
| bool operator<(const T& lhs, const T& rhs); |
| |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>* = nullptr> |
| bool operator<=(const T& lhs, const T& rhs) { |
| return !(rhs < lhs); |
| } |
| |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>* = nullptr> |
| bool operator>(const T& lhs, const T& rhs) { |
| return rhs < lhs; |
| } |
| |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>* = nullptr> |
| bool operator>=(const T& lhs, const T& rhs) { |
| return !(lhs < rhs); |
| } |
| |
| template <typename StructPtrType> |
| CrossOriginOpenerPolicyReporterParamsPtr CrossOriginOpenerPolicyReporterParams::Clone() const { |
| return New( |
| mojo::Clone(report_type), |
| mojo::Clone(reporter), |
| mojo::Clone(endpoint_defined), |
| mojo::Clone(reported_window_url) |
| ); |
| } |
| |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>*> |
| bool CrossOriginOpenerPolicyReporterParams::Equals(const T& other_struct) const { |
| if (!mojo::Equals(this->report_type, other_struct.report_type)) |
| return false; |
| if (!mojo::Equals(this->reporter, other_struct.reporter)) |
| return false; |
| if (!mojo::Equals(this->endpoint_defined, other_struct.endpoint_defined)) |
| return false; |
| if (!mojo::Equals(this->reported_window_url, other_struct.reported_window_url)) |
| return false; |
| return true; |
| } |
| |
| template <typename T, CrossOriginOpenerPolicyReporterParams::EnableIfSame<T>*> |
| bool operator<(const T& lhs, const T& rhs) { |
| if (lhs.report_type < rhs.report_type) |
| return true; |
| if (rhs.report_type < lhs.report_type) |
| return false; |
| if (lhs.reporter < rhs.reporter) |
| return true; |
| if (rhs.reporter < lhs.reporter) |
| return false; |
| if (lhs.endpoint_defined < rhs.endpoint_defined) |
| return true; |
| if (rhs.endpoint_defined < lhs.endpoint_defined) |
| return false; |
| if (lhs.reported_window_url < rhs.reported_window_url) |
| return true; |
| if (rhs.reported_window_url < lhs.reported_window_url) |
| return false; |
| return false; |
| } |
| template <typename StructPtrType> |
| CrossOriginOpenerPolicyPtr CrossOriginOpenerPolicy::Clone() const { |
| return New( |
| mojo::Clone(value), |
| mojo::Clone(reporting_endpoint), |
| mojo::Clone(report_only_value), |
| mojo::Clone(report_only_reporting_endpoint), |
| mojo::Clone(soap_by_default_value) |
| ); |
| } |
| |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>*> |
| bool CrossOriginOpenerPolicy::Equals(const T& other_struct) const { |
| if (!mojo::Equals(this->value, other_struct.value)) |
| return false; |
| if (!mojo::Equals(this->reporting_endpoint, other_struct.reporting_endpoint)) |
| return false; |
| if (!mojo::Equals(this->report_only_value, other_struct.report_only_value)) |
| return false; |
| if (!mojo::Equals(this->report_only_reporting_endpoint, other_struct.report_only_reporting_endpoint)) |
| return false; |
| if (!mojo::Equals(this->soap_by_default_value, other_struct.soap_by_default_value)) |
| return false; |
| return true; |
| } |
| |
| template <typename T, CrossOriginOpenerPolicy::EnableIfSame<T>*> |
| bool operator<(const T& lhs, const T& rhs) { |
| if (lhs.value < rhs.value) |
| return true; |
| if (rhs.value < lhs.value) |
| return false; |
| if (lhs.reporting_endpoint < rhs.reporting_endpoint) |
| return true; |
| if (rhs.reporting_endpoint < lhs.reporting_endpoint) |
| return false; |
| if (lhs.report_only_value < rhs.report_only_value) |
| return true; |
| if (rhs.report_only_value < lhs.report_only_value) |
| return false; |
| if (lhs.report_only_reporting_endpoint < rhs.report_only_reporting_endpoint) |
| return true; |
| if (rhs.report_only_reporting_endpoint < lhs.report_only_reporting_endpoint) |
| return false; |
| if (lhs.soap_by_default_value < rhs.soap_by_default_value) |
| return true; |
| if (rhs.soap_by_default_value < lhs.soap_by_default_value) |
| return false; |
| return false; |
| } |
| |
| |
| } // namespace mojom |
| } // namespace network |
| |
| namespace mojo { |
| |
| |
| template <> |
| struct StructTraits<::network::mojom::CrossOriginOpenerPolicyReporterParams::DataView, |
| ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr> { |
| static bool IsNull(const ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr& input) { return !input; } |
| static void SetToNull(::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr* output) { output->reset(); } |
| |
| static decltype(::network::mojom::CrossOriginOpenerPolicyReporterParams::report_type) report_type( |
| const ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr& input) { |
| return input->report_type; |
| } |
| |
| static decltype(::network::mojom::CrossOriginOpenerPolicyReporterParams::reporter)& reporter( |
| ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr& input) { |
| return input->reporter; |
| } |
| |
| static decltype(::network::mojom::CrossOriginOpenerPolicyReporterParams::endpoint_defined) endpoint_defined( |
| const ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr& input) { |
| return input->endpoint_defined; |
| } |
| |
| static const decltype(::network::mojom::CrossOriginOpenerPolicyReporterParams::reported_window_url)& reported_window_url( |
| const ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr& input) { |
| return input->reported_window_url; |
| } |
| |
| static bool Read(::network::mojom::CrossOriginOpenerPolicyReporterParams::DataView input, ::network::mojom::CrossOriginOpenerPolicyReporterParamsPtr* output); |
| }; |
| |
| |
| template <> |
| struct StructTraits<::network::mojom::CrossOriginOpenerPolicy::DataView, |
| ::network::mojom::CrossOriginOpenerPolicyPtr> { |
| static bool IsNull(const ::network::mojom::CrossOriginOpenerPolicyPtr& input) { return !input; } |
| static void SetToNull(::network::mojom::CrossOriginOpenerPolicyPtr* output) { output->reset(); } |
| |
| static decltype(::network::mojom::CrossOriginOpenerPolicy::value) value( |
| const ::network::mojom::CrossOriginOpenerPolicyPtr& input) { |
| return input->value; |
| } |
| |
| static const decltype(::network::mojom::CrossOriginOpenerPolicy::reporting_endpoint)& reporting_endpoint( |
| const ::network::mojom::CrossOriginOpenerPolicyPtr& input) { |
| return input->reporting_endpoint; |
| } |
| |
| static decltype(::network::mojom::CrossOriginOpenerPolicy::report_only_value) report_only_value( |
| const ::network::mojom::CrossOriginOpenerPolicyPtr& input) { |
| return input->report_only_value; |
| } |
| |
| static const decltype(::network::mojom::CrossOriginOpenerPolicy::report_only_reporting_endpoint)& report_only_reporting_endpoint( |
| const ::network::mojom::CrossOriginOpenerPolicyPtr& input) { |
| return input->report_only_reporting_endpoint; |
| } |
| |
| static decltype(::network::mojom::CrossOriginOpenerPolicy::soap_by_default_value) soap_by_default_value( |
| const ::network::mojom::CrossOriginOpenerPolicyPtr& input) { |
| return input->soap_by_default_value; |
| } |
| |
| static bool Read(::network::mojom::CrossOriginOpenerPolicy::DataView input, ::network::mojom::CrossOriginOpenerPolicyPtr* output); |
| }; |
| |
| } // namespace mojo |
| |
| #endif // SERVICES_NETWORK_PUBLIC_MOJOM_CROSS_ORIGIN_OPENER_POLICY_MOJOM_H_ |
| |
| /* Metadata comment |
| eyJtZXRhIjogW3siZW5kIjogMTk4MCwgImJlZ2luIjogMTk0OSwgImVkZ2UiOiAiJS9reXRoZS9l |
| ZGdlL2dlbmVyYXRlcyIsICJ0eXBlIjogImFuY2hvcl9kZWZpbmVzIiwgInZuYW1lIjogeyJjb3Jw |
| dXMiOiAiY2hyb21pdW0uZ29vZ2xlc291cmNlLmNvbS9jaHJvbWl1bS9zcmMiLCAibGFuZ3VhZ2Ui |
| OiAibW9qb20iLCAic2lnbmF0dXJlIjogIm5ldHdvcmsubW9qb20uQ3Jvc3NPcmlnaW5PcGVuZXJQ |
| b2xpY3lSZXBvcnRlciJ9fSwgeyJlbmQiOiAzMDMyLCAiYmVnaW4iOiAzMDE1LCAiZWRnZSI6ICIl |
| L2t5dGhlL2VkZ2UvZ2VuZXJhdGVzIiwgInR5cGUiOiAiYW5jaG9yX2RlZmluZXMiLCAidm5hbWUi |
| OiB7ImNvcnB1cyI6ICJjaHJvbWl1bS5nb29nbGVzb3VyY2UuY29tL2Nocm9taXVtL3NyYyIsICJs |
| YW5ndWFnZSI6ICJtb2pvbSIsICJzaWduYXR1cmUiOiAibmV0d29yay5tb2pvbS5Dcm9zc09yaWdp |
| bk9wZW5lclBvbGljeVJlcG9ydGVyLlF1ZXVlQWNjZXNzUmVwb3J0In19LCB7ImVuZCI6IDM2MzAs |
| ICJiZWdpbiI6IDM2MTMsICJlZGdlIjogIiUva3l0aGUvZWRnZS9nZW5lcmF0ZXMiLCAidHlwZSI6 |
| ICJhbmNob3JfZGVmaW5lcyIsICJ2bmFtZSI6IHsiY29ycHVzIjogImNocm9taXVtLmdvb2dsZXNv |
| dXJjZS5jb20vY2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