Copy as Markdown
Other Tools
//
// Automatically generated by ipdlc.
// Edit at your own risk
//
#include "mozilla/ipc/PBackgroundParent.h"
#include "mozilla/ipc/PBackgroundChild.h"
#include "mozilla/dom/PCookieStore.h"
#include "mozilla/dom/PCookieStoreParent.h"
#include "mozilla/dom/PCookieStoreChild.h"
#include "ipc/IPCMessageUtils.h"
#include "ipc/IPCMessageUtilsSpecializations.h"
#include "nsIFile.h"
#include "mozilla/ipc/Endpoint.h"
#include "mozilla/ipc/ProtocolMessageUtils.h"
#include "mozilla/ipc/ProtocolUtils.h"
#include "mozilla/ipc/ShmemMessageUtils.h"
#include "mozilla/ipc/TaintingIPCUtils.h"
namespace mozilla {
namespace dom {
namespace PCookieStore {
nsresult
CreateEndpoints(
mozilla::ipc::EndpointProcInfo aParentDestInfo,
mozilla::ipc::EndpointProcInfo aChildDestInfo,
mozilla::ipc::Endpoint<::mozilla::dom::PCookieStoreParent>* aParent,
mozilla::ipc::Endpoint<::mozilla::dom::PCookieStoreChild>* aChild)
{
return mozilla::ipc::CreateEndpoints(
mozilla::ipc::PrivateIPDLInterface(),
aParentDestInfo, aChildDestInfo, aParent, aChild);
}
mozilla::UniquePtr<IPC::Message>
Msg_GetRequest(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_GetRequest__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::NOT_REPLY));
}
mozilla::UniquePtr<IPC::Message>
Reply_GetRequest(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Reply_GetRequest__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::REPLY));
}
mozilla::UniquePtr<IPC::Message>
Msg_SetRequest(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_SetRequest__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::NOT_REPLY));
}
mozilla::UniquePtr<IPC::Message>
Reply_SetRequest(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Reply_SetRequest__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::REPLY));
}
mozilla::UniquePtr<IPC::Message>
Msg_DeleteRequest(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_DeleteRequest__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::NOT_REPLY));
}
mozilla::UniquePtr<IPC::Message>
Reply_DeleteRequest(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Reply_DeleteRequest__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::REPLY));
}
mozilla::UniquePtr<IPC::Message>
Msg_Close(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_Close__ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::NOT_REPLY));
}
mozilla::UniquePtr<IPC::Message>
Msg___delete__(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg___delete____ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::NOT_REPLY));
}
mozilla::UniquePtr<IPC::Message>
Reply___delete__(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Reply___delete____ID, 0, IPC::Message::HeaderFlags(IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, IPC::Message::EAGER_SEND, IPC::Message::NOT_CONSTRUCTOR, IPC::Message::ASYNC, IPC::Message::REPLY));
}
} // namespace PCookieStore
} // namespace dom
} // namespace mozilla
//-----------------------------------------------------------------------------
// Method definitions for the IPDL type |struct CookieData|
//
namespace mozilla {
namespace dom {
} // namespace dom
} // namespace mozilla
namespace IPC {
auto ParamTraits<::mozilla::dom::CookieData>::Write(
IPC::MessageWriter* aWriter,
const paramType& aVar) -> void
{
IPC::WriteParam(aWriter, (aVar).name());
// Sentinel = 'name'
(aWriter)->WriteSentinel(69075362);
IPC::WriteParam(aWriter, (aVar).value());
// Sentinel = 'value'
(aWriter)->WriteSentinel(107610654);
}
auto ParamTraits<::mozilla::dom::CookieData>::Read(IPC::MessageReader* aReader) -> IPC::ReadResult<paramType>
{
auto maybe___name = IPC::ReadParam<::nsString>(aReader);
if (!maybe___name) {
aReader->FatalError("Error deserializing 'name' (nsString) member of 'CookieData'");
return {};
}
auto& _name = *maybe___name;
// Sentinel = 'name'
if ((!((aReader)->ReadSentinel(69075362)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'name' (nsString) member of 'CookieData'");
return {};
}
auto maybe___value = IPC::ReadParam<::nsString>(aReader);
if (!maybe___value) {
aReader->FatalError("Error deserializing 'value' (nsString) member of 'CookieData'");
return {};
}
auto& _value = *maybe___value;
// Sentinel = 'value'
if ((!((aReader)->ReadSentinel(107610654)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'value' (nsString) member of 'CookieData'");
return {};
}
IPC::ReadResult<paramType> result__{
std::in_place,
std::move(_name),
std::move(_value)};
return result__;
}
} // namespace IPC
//-----------------------------------------------------------------------------
// Method definitions for the IPDL type |union MaybeCookieData|
//
namespace mozilla {
namespace dom {
auto MaybeCookieData::MaybeDestroy() -> void
{
if ((mType) == (T__None)) {
return;
}
switch (mType) {
case TCookieData:
{
(ptr_CookieData())->~CookieData__tdef();
break;
}
case Tvoid_t:
{
(ptr_void_t())->~void_t__tdef();
break;
}
default:
{
mozilla::ipc::LogicError("not reached");
break;
}
}
}
MOZ_IMPLICIT MaybeCookieData::MaybeCookieData(const CookieData& aOther)
{
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData(aOther);
mType = TCookieData;
}
MOZ_IMPLICIT MaybeCookieData::MaybeCookieData(CookieData&& aOther)
{
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData(std::move(aOther));
mType = TCookieData;
}
MOZ_IMPLICIT MaybeCookieData::MaybeCookieData(const void_t& aOther)
{
new (mozilla::KnownNotNull, ptr_void_t()) void_t(aOther);
mType = Tvoid_t;
}
MOZ_IMPLICIT MaybeCookieData::MaybeCookieData(void_t&& aOther)
{
new (mozilla::KnownNotNull, ptr_void_t()) void_t(std::move(aOther));
mType = Tvoid_t;
}
MOZ_IMPLICIT MaybeCookieData::MaybeCookieData(const MaybeCookieData& aOther)
{
(aOther).AssertSanity();
switch ((aOther).type()) {
case TCookieData:
{
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData((aOther).get_CookieData());
break;
}
case Tvoid_t:
{
new (mozilla::KnownNotNull, ptr_void_t()) void_t((aOther).get_void_t());
break;
}
case T__None:
{
break;
}
default:
{
mozilla::ipc::LogicError("unreached");
return;
}
}
mType = (aOther).type();
}
MOZ_IMPLICIT MaybeCookieData::MaybeCookieData(MaybeCookieData&& aOther)
{
(aOther).AssertSanity();
Type t = (aOther).type();
switch (t) {
case TCookieData:
{
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData(std::move((aOther).get_CookieData()));
(aOther).MaybeDestroy();
break;
}
case Tvoid_t:
{
new (mozilla::KnownNotNull, ptr_void_t()) void_t(std::move((aOther).get_void_t()));
(aOther).MaybeDestroy();
break;
}
case T__None:
{
break;
}
default:
{
mozilla::ipc::LogicError("unreached");
return;
}
}
(aOther).mType = T__None;
mType = t;
}
MaybeCookieData::~MaybeCookieData()
{
MaybeDestroy();
}
auto MaybeCookieData::operator=(const CookieData& aRhs) -> MaybeCookieData&
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData(aRhs);
mType = TCookieData;
return (*(this));
}
auto MaybeCookieData::operator=(CookieData&& aRhs) -> MaybeCookieData&
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData(std::move(aRhs));
mType = TCookieData;
return (*(this));
}
auto MaybeCookieData::operator=(const void_t& aRhs) -> MaybeCookieData&
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_void_t()) void_t(aRhs);
mType = Tvoid_t;
return (*(this));
}
auto MaybeCookieData::operator=(void_t&& aRhs) -> MaybeCookieData&
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_void_t()) void_t(std::move(aRhs));
mType = Tvoid_t;
return (*(this));
}
auto MaybeCookieData::operator=(const MaybeCookieData& aRhs) -> MaybeCookieData&
{
(aRhs).AssertSanity();
Type t = (aRhs).type();
switch (t) {
case TCookieData:
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData((aRhs).get_CookieData());
break;
}
case Tvoid_t:
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_void_t()) void_t((aRhs).get_void_t());
break;
}
case T__None:
{
MaybeDestroy();
break;
}
default:
{
mozilla::ipc::LogicError("unreached");
break;
}
}
mType = t;
return (*(this));
}
auto MaybeCookieData::operator=(MaybeCookieData&& aRhs) -> MaybeCookieData&
{
(aRhs).AssertSanity();
Type t = (aRhs).type();
switch (t) {
case TCookieData:
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_CookieData()) CookieData(std::move((aRhs).get_CookieData()));
(aRhs).MaybeDestroy();
break;
}
case Tvoid_t:
{
MaybeDestroy();
new (mozilla::KnownNotNull, ptr_void_t()) void_t(std::move((aRhs).get_void_t()));
(aRhs).MaybeDestroy();
break;
}
case T__None:
{
MaybeDestroy();
break;
}
default:
{
mozilla::ipc::LogicError("unreached");
break;
}
}
(aRhs).mType = T__None;
mType = t;
return (*(this));
}
} // namespace dom
} // namespace mozilla
namespace IPC {
auto ParamTraits<::mozilla::dom::MaybeCookieData>::Write(
IPC::MessageWriter* aWriter,
const paramType& aVar) -> void
{
typedef ::mozilla::dom::MaybeCookieData union__;
int type = (aVar).type();
IPC::WriteParam(aWriter, type);
// Sentinel = 'MaybeCookieData'
(aWriter)->WriteSentinel(768148931);
switch (type) {
case union__::TCookieData:
{
IPC::WriteParam(aWriter, (aVar).get_CookieData());
// Sentinel = 'TCookieData'
(aWriter)->WriteSentinel(410780713);
return;
}
case union__::Tvoid_t:
{
IPC::WriteParam(aWriter, (aVar).get_void_t());
// Sentinel = 'Tvoid_t'
(aWriter)->WriteSentinel(189006554);
return;
}
default:
{
aWriter->FatalError("unknown variant of union MaybeCookieData");
return;
}
}
}
auto ParamTraits<::mozilla::dom::MaybeCookieData>::Read(IPC::MessageReader* aReader) -> IPC::ReadResult<paramType>
{
typedef ::mozilla::dom::MaybeCookieData union__;
auto maybe__type = IPC::ReadParam<int>(aReader);
if (!maybe__type) {
aReader->FatalError("Error deserializing type of union MaybeCookieData");
return {};
}
auto& type = *maybe__type;
// Sentinel = 'MaybeCookieData'
if ((!((aReader)->ReadSentinel(768148931)))) {
mozilla::ipc::SentinelReadError("Error deserializing type of union MaybeCookieData");
return {};
}
switch (type) {
case union__::TCookieData:
{
auto maybe__tmp = IPC::ReadParam<::mozilla::dom::CookieData>(aReader);
if (!maybe__tmp) {
aReader->FatalError("Error deserializing variant TCookieData of union MaybeCookieData");
return {};
}
auto& tmp = *maybe__tmp;
// Sentinel = 'TCookieData'
if ((!((aReader)->ReadSentinel(410780713)))) {
mozilla::ipc::SentinelReadError("Error deserializing variant TCookieData of union MaybeCookieData");
return {};
}
return std::move(tmp);
}
case union__::Tvoid_t:
{
auto maybe__tmp = IPC::ReadParam<::mozilla::void_t>(aReader);
if (!maybe__tmp) {
aReader->FatalError("Error deserializing variant Tvoid_t of union MaybeCookieData");
return {};
}
auto& tmp = *maybe__tmp;
// Sentinel = 'Tvoid_t'
if ((!((aReader)->ReadSentinel(189006554)))) {
mozilla::ipc::SentinelReadError("Error deserializing variant Tvoid_t of union MaybeCookieData");
return {};
}
return std::move(tmp);
}
default:
{
aReader->FatalError("unknown variant of union MaybeCookieData");
return {};
}
}
}
} // namespace IPC