Copy as Markdown

Other Tools

//
// Automatically generated by ipdlc.
// Edit at your own risk
//
#include "mozilla/_ipdltest/PIPDLUnitTest.h"
#include "mozilla/_ipdltest/PIPDLUnitTestParent.h"
#include "mozilla/_ipdltest/PIPDLUnitTestChild.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 _ipdltest {
namespace PIPDLUnitTest {
nsresult
CreateEndpoints(
mozilla::ipc::EndpointProcInfo aParentDestInfo,
mozilla::ipc::EndpointProcInfo aChildDestInfo,
mozilla::ipc::Endpoint<::mozilla::_ipdltest::PIPDLUnitTestParent>* aParent,
mozilla::ipc::Endpoint<::mozilla::_ipdltest::PIPDLUnitTestChild>* aChild)
{
return mozilla::ipc::CreateEndpoints(
mozilla::ipc::PrivateIPDLInterface(),
aParentDestInfo, aChildDestInfo, aParent, aChild);
}
mozilla::UniquePtr<IPC::Message>
Msg_Start(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_Start__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_Report(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_Report__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_Complete(int32_t routingId)
{
return IPC::Message::IPDLMessage(routingId, Msg_Complete__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));
}
} // namespace PIPDLUnitTest
} // namespace _ipdltest
} // namespace mozilla
//-----------------------------------------------------------------------------
// Method definitions for the IPDL type |struct TestPartResult|
//
namespace mozilla {
namespace _ipdltest {
} // namespace _ipdltest
} // namespace mozilla
namespace IPC {
auto ParamTraits<::mozilla::_ipdltest::TestPartResult>::Write(
IPC::MessageWriter* aWriter,
const paramType& aVar) -> void
{
IPC::WriteParam(aWriter, (aVar).failed());
// Sentinel = 'failed'
(aWriter)->WriteSentinel(140837478);
IPC::WriteParam(aWriter, (aVar).fatal());
// Sentinel = 'fatal'
(aWriter)->WriteSentinel(101777929);
IPC::WriteParam(aWriter, (aVar).filename());
// Sentinel = 'filename'
(aWriter)->WriteSentinel(246547266);
IPC::WriteParam(aWriter, (aVar).summary());
// Sentinel = 'summary'
(aWriter)->WriteSentinel(205456143);
IPC::WriteParam(aWriter, (aVar).message());
// Sentinel = 'message'
(aWriter)->WriteSentinel(197198566);
(aWriter)->WriteBytes((&((aVar).lineNumber())), 4);
// Sentinel = 'lineNumber'
(aWriter)->WriteSentinel(374932498);
}
auto ParamTraits<::mozilla::_ipdltest::TestPartResult>::Read(IPC::MessageReader* aReader) -> IPC::ReadResult<paramType>
{
auto maybe___failed = IPC::ReadParam<bool>(aReader);
if (!maybe___failed) {
aReader->FatalError("Error deserializing 'failed' (bool) member of 'TestPartResult'");
return {};
}
auto& _failed = *maybe___failed;
// Sentinel = 'failed'
if ((!((aReader)->ReadSentinel(140837478)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'failed' (bool) member of 'TestPartResult'");
return {};
}
auto maybe___fatal = IPC::ReadParam<bool>(aReader);
if (!maybe___fatal) {
aReader->FatalError("Error deserializing 'fatal' (bool) member of 'TestPartResult'");
return {};
}
auto& _fatal = *maybe___fatal;
// Sentinel = 'fatal'
if ((!((aReader)->ReadSentinel(101777929)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'fatal' (bool) member of 'TestPartResult'");
return {};
}
auto maybe___filename = IPC::ReadParam<::nsCString>(aReader);
if (!maybe___filename) {
aReader->FatalError("Error deserializing 'filename' (nsCString) member of 'TestPartResult'");
return {};
}
auto& _filename = *maybe___filename;
// Sentinel = 'filename'
if ((!((aReader)->ReadSentinel(246547266)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'filename' (nsCString) member of 'TestPartResult'");
return {};
}
auto maybe___summary = IPC::ReadParam<::nsCString>(aReader);
if (!maybe___summary) {
aReader->FatalError("Error deserializing 'summary' (nsCString) member of 'TestPartResult'");
return {};
}
auto& _summary = *maybe___summary;
// Sentinel = 'summary'
if ((!((aReader)->ReadSentinel(205456143)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'summary' (nsCString) member of 'TestPartResult'");
return {};
}
auto maybe___message = IPC::ReadParam<::nsCString>(aReader);
if (!maybe___message) {
aReader->FatalError("Error deserializing 'message' (nsCString) member of 'TestPartResult'");
return {};
}
auto& _message = *maybe___message;
// Sentinel = 'message'
if ((!((aReader)->ReadSentinel(197198566)))) {
mozilla::ipc::SentinelReadError("Error deserializing 'message' (nsCString) member of 'TestPartResult'");
return {};
}
IPC::ReadResult<paramType> result__{
std::in_place,
std::move(_failed),
std::move(_fatal),
std::move(_filename),
::int32_t{0},
std::move(_summary),
std::move(_message)};
if ((!((aReader)->ReadBytesInto((&((result__)->lineNumber())), 4)))) {
aReader->FatalError("Error bulk reading fields from int32_t");
return {};
}
// Sentinel = 'lineNumber'
if ((!((aReader)->ReadSentinel(374932498)))) {
mozilla::ipc::SentinelReadError("Error bulk reading fields from int32_t");
return {};
}
return result__;
}
} // namespace IPC