//
// Automatically generated by ipdlc.
// Edit at your own risk
//


#include "mozilla/net/PHttpChannelChild.h"
#include "mozilla/net/TimingStruct.h"
#include "nsHttpHeaderArray.h"

#include "mozilla/net/PNeckoChild.h"
#include "mozilla/dom/PBlobChild.h"

#include "nsIFile.h"
#include "GeckoProfiler.h"

namespace mozilla {
namespace net {


auto PHttpChannelChild::ActorDestroy(ActorDestroyReason aWhy) -> void
{
}

MOZ_IMPLICIT PHttpChannelChild::PHttpChannelChild() :
    mozilla::ipc::IProtocol(mozilla::ipc::ChildSide),
    mState(PHttpChannel::__Dead)
{
    MOZ_COUNT_CTOR(PHttpChannelChild);
}

PHttpChannelChild::~PHttpChannelChild()
{
    MOZ_COUNT_DTOR(PHttpChannelChild);
}

auto PHttpChannelChild::Manager() const -> PNeckoChild*
{
    return static_cast<PNeckoChild*>(IProtocol::Manager());
}

auto PHttpChannelChild::state() -> PHttpChannel::State
{
    return mState;
}

auto PHttpChannelChild::SendSetPriority(const uint16_t& priority) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_SetPriority(Id());

    Write(priority, msg__);
    // Sentinel = 'priority'
    (msg__)->WriteSentinel(558136112);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_SetPriority", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_SetPriority__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendSetClassOfService(const uint32_t& cos) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_SetClassOfService(Id());

    Write(cos, msg__);
    // Sentinel = 'cos'
    (msg__)->WriteSentinel(403875042);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_SetClassOfService", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_SetClassOfService__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendSetCacheTokenCachedCharset(const nsCString& charset) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_SetCacheTokenCachedCharset(Id());

    Write(charset, msg__);
    // Sentinel = 'charset'
    (msg__)->WriteSentinel(1551550891);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_SetCacheTokenCachedCharset", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_SetCacheTokenCachedCharset__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendUpdateAssociatedContentSecurity(
        const int32_t& broken,
        const int32_t& no) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_UpdateAssociatedContentSecurity(Id());

    Write(broken, msg__);
    // Sentinel = 'broken'
    (msg__)->WriteSentinel(2083835601);
    Write(no, msg__);
    // Sentinel = 'no'
    (msg__)->WriteSentinel(677832615);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_UpdateAssociatedContentSecurity", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_UpdateAssociatedContentSecurity__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendSuspend() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_Suspend(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_Suspend", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_Suspend__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendResume() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_Resume(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_Resume", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_Resume__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendCancel(const nsresult& status) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_Cancel(Id());

    Write(status, msg__);
    // Sentinel = 'status'
    (msg__)->WriteSentinel(3714608576);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_Cancel", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_Cancel__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendRedirect2Verify(
        const nsresult& result,
        const RequestHeaderTuples& changedHeaders,
        const uint32_t& loadFlags,
        const OptionalURIParams& apiRedirectTo,
        const OptionalCorsPreflightArgs& corsPreflightArgs,
        const bool& forceHSTSPriming,
        const bool& mixedContentWouldBlock,
        const bool& chooseAppcache) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_Redirect2Verify(Id());

    Write(result, msg__);
    // Sentinel = 'result'
    (msg__)->WriteSentinel(3991766165);
    Write(changedHeaders, msg__);
    // Sentinel = 'changedHeaders'
    (msg__)->WriteSentinel(1574138284);
    Write(loadFlags, msg__);
    // Sentinel = 'loadFlags'
    (msg__)->WriteSentinel(2391120444);
    Write(apiRedirectTo, msg__);
    // Sentinel = 'apiRedirectTo'
    (msg__)->WriteSentinel(3162811030);
    Write(corsPreflightArgs, msg__);
    // Sentinel = 'corsPreflightArgs'
    (msg__)->WriteSentinel(1890063766);
    Write(forceHSTSPriming, msg__);
    // Sentinel = 'forceHSTSPriming'
    (msg__)->WriteSentinel(1123937751);
    Write(mixedContentWouldBlock, msg__);
    // Sentinel = 'mixedContentWouldBlock'
    (msg__)->WriteSentinel(3609505564);
    Write(chooseAppcache, msg__);
    // Sentinel = 'chooseAppcache'
    (msg__)->WriteSentinel(868254728);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_Redirect2Verify", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_Redirect2Verify__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendDocumentChannelCleanup() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_DocumentChannelCleanup(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_DocumentChannelCleanup", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_DocumentChannelCleanup__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendMarkOfflineCacheEntryAsForeign() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_MarkOfflineCacheEntryAsForeign(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_MarkOfflineCacheEntryAsForeign", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_MarkOfflineCacheEntryAsForeign__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendDivertOnDataAvailable(
        const nsCString& data,
        const uint64_t& offset,
        const uint32_t& count) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_DivertOnDataAvailable(Id());

    Write(data, msg__);
    // Sentinel = 'data'
    (msg__)->WriteSentinel(843352540);
    Write(offset, msg__);
    // Sentinel = 'offset'
    (msg__)->WriteSentinel(1369947863);
    Write(count, msg__);
    // Sentinel = 'count'
    (msg__)->WriteSentinel(2126421856);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_DivertOnDataAvailable", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_DivertOnDataAvailable__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendDivertOnStopRequest(const nsresult& statusCode) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_DivertOnStopRequest(Id());

    Write(statusCode, msg__);
    // Sentinel = 'statusCode'
    (msg__)->WriteSentinel(2709278591);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_DivertOnStopRequest", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_DivertOnStopRequest__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendDivertComplete() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_DivertComplete(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_DivertComplete", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_DivertComplete__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendRemoveCorsPreflightCacheEntry(
        const URIParams& uri,
        const PrincipalInfo& requestingPrincipal) -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_RemoveCorsPreflightCacheEntry(Id());

    Write(uri, msg__);
    // Sentinel = 'uri'
    (msg__)->WriteSentinel(1453210605);
    Write(requestingPrincipal, msg__);
    // Sentinel = 'requestingPrincipal'
    (msg__)->WriteSentinel(1124847050);




    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_RemoveCorsPreflightCacheEntry", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_RemoveCorsPreflightCacheEntry__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::SendDeletingChannel() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_DeletingChannel(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_DeletingChannel", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_DeletingChannel__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::Send__delete__(PHttpChannelChild* actor) -> bool
{
    if ((!(actor))) {
        return false;
    }

    IPC::Message* msg__ = PHttpChannel::Msg___delete__((actor)->Id());

    (actor)->Write(actor, msg__, false);
    // Sentinel = 'actor'
    (msg__)->WriteSentinel(875202478);



    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", (actor)->OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg___delete__", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg___delete____ID), (&((actor)->mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = ((actor)->GetIPCChannel())->Send(msg__);

    (actor)->DestroySubtree(Deletion);
    (actor)->DeallocSubtree();
    ((actor)->Manager())->RemoveManagee(PHttpChannelMsgStart, actor);
    return sendok__;
}

auto PHttpChannelChild::SendFinishInterceptedRedirect() -> bool
{
    IPC::Message* msg__ = PHttpChannel::Msg_FinishInterceptedRedirect(Id());





    if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
        mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
    }
    PROFILER_LABEL("PHttpChannel", "Msg_FinishInterceptedRedirect", js::ProfileEntry::Category::OTHER);
    if ((!(PHttpChannel::Transition(Trigger(Trigger::Recv, PHttpChannel::Msg_FinishInterceptedRedirect__ID), (&(mState)))))) {
        NS_WARNING("bad state transition!");
    }

    bool sendok__ = (GetIPCChannel())->Send(msg__);
    return sendok__;
}

auto PHttpChannelChild::RemoveManagee(
        int32_t aProtocolId,
        ProtocolBase* aListener) -> void
{
    FatalError("unreached");
    return;
}

auto PHttpChannelChild::OnMessageReceived(const Message& msg__) -> PHttpChannelChild::Result
{
    switch ((msg__).type()) {
    case PHttpChannel::Reply___delete____ID:
        {
            return MsgProcessed;
        }
    case PHttpChannel::Msg_OnStartRequest__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_OnStartRequest", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsresult channelStatus;
            nsHttpResponseHead responseHead;
            bool useResponseHead;
            nsHttpHeaderArray requestHeaders;
            bool isFromCache;
            bool cacheEntryAvailable;
            uint32_t cacheExpirationTime;
            nsCString cachedCharset;
            nsCString securityInfoSerialization;
            NetAddr selfAddr;
            NetAddr peerAddr;
            int16_t redirectCount;
            uint32_t cacheKey;
            nsCString altDataType;

            if ((!(Read((&(channelStatus)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            // Sentinel = 'channelStatus'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3148019746)))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            if ((!(Read((&(responseHead)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsHttpResponseHead'");
                return MsgValueError;
            }
            // Sentinel = 'responseHead'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3038698187)))) {
                FatalError("Error deserializing 'nsHttpResponseHead'");
                return MsgValueError;
            }
            if ((!(Read((&(useResponseHead)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            // Sentinel = 'useResponseHead'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2994626489)))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            if ((!(Read((&(requestHeaders)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsHttpHeaderArray'");
                return MsgValueError;
            }
            // Sentinel = 'requestHeaders'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2055989545)))) {
                FatalError("Error deserializing 'nsHttpHeaderArray'");
                return MsgValueError;
            }
            if ((!(Read((&(isFromCache)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            // Sentinel = 'isFromCache'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 4089953117)))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            if ((!(Read((&(cacheEntryAvailable)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            // Sentinel = 'cacheEntryAvailable'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2363064)))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            if ((!(Read((&(cacheExpirationTime)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            // Sentinel = 'cacheExpirationTime'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 439162213)))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            if ((!(Read((&(cachedCharset)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'cachedCharset'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1570160399)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            if ((!(Read((&(securityInfoSerialization)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'securityInfoSerialization'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 985832975)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            if ((!(Read((&(selfAddr)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'NetAddr'");
                return MsgValueError;
            }
            // Sentinel = 'selfAddr'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 463888251)))) {
                FatalError("Error deserializing 'NetAddr'");
                return MsgValueError;
            }
            if ((!(Read((&(peerAddr)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'NetAddr'");
                return MsgValueError;
            }
            // Sentinel = 'peerAddr'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1373265573)))) {
                FatalError("Error deserializing 'NetAddr'");
                return MsgValueError;
            }
            if ((!(Read((&(redirectCount)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'int16_t'");
                return MsgValueError;
            }
            // Sentinel = 'redirectCount'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1874411984)))) {
                FatalError("Error deserializing 'int16_t'");
                return MsgValueError;
            }
            if ((!(Read((&(cacheKey)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            // Sentinel = 'cacheKey'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 249191363)))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            if ((!(Read((&(altDataType)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'altDataType'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2339988114)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_OnStartRequest__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvOnStartRequest(mozilla::Move(channelStatus), mozilla::Move(responseHead), mozilla::Move(useResponseHead), mozilla::Move(requestHeaders), mozilla::Move(isFromCache), mozilla::Move(cacheEntryAvailable), mozilla::Move(cacheExpirationTime), mozilla::Move(cachedCharset), mozilla::Move(securityInfoSerialization), mozilla::Move(selfAddr), mozilla::Move(peerAddr), mozilla::Move(redirectCount), mozilla::Move(cacheKey), mozilla::Move(altDataType))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_OnTransportAndData__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_OnTransportAndData", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsresult channelStatus;
            nsresult transportStatus;
            uint64_t progress;
            uint64_t progressMax;
            uint64_t offset;
            uint32_t count;
            nsCString data;

            if ((!(Read((&(channelStatus)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            // Sentinel = 'channelStatus'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3148019746)))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            if ((!(Read((&(transportStatus)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            // Sentinel = 'transportStatus'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1295005818)))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            if ((!(Read((&(progress)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint64_t'");
                return MsgValueError;
            }
            // Sentinel = 'progress'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 858119353)))) {
                FatalError("Error deserializing 'uint64_t'");
                return MsgValueError;
            }
            if ((!(Read((&(progressMax)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint64_t'");
                return MsgValueError;
            }
            // Sentinel = 'progressMax'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2530734978)))) {
                FatalError("Error deserializing 'uint64_t'");
                return MsgValueError;
            }
            if ((!(Read((&(offset)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint64_t'");
                return MsgValueError;
            }
            // Sentinel = 'offset'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1369947863)))) {
                FatalError("Error deserializing 'uint64_t'");
                return MsgValueError;
            }
            if ((!(Read((&(count)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            // Sentinel = 'count'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2126421856)))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            if ((!(Read((&(data)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'data'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 843352540)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_OnTransportAndData__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvOnTransportAndData(mozilla::Move(channelStatus), mozilla::Move(transportStatus), mozilla::Move(progress), mozilla::Move(progressMax), mozilla::Move(offset), mozilla::Move(count), mozilla::Move(data))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_OnStopRequest__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_OnStopRequest", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsresult channelStatus;
            ResourceTimingStruct timing;

            if ((!(Read((&(channelStatus)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            // Sentinel = 'channelStatus'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3148019746)))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            if ((!(Read((&(timing)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'ResourceTimingStruct'");
                return MsgValueError;
            }
            // Sentinel = 'timing'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3852786776)))) {
                FatalError("Error deserializing 'ResourceTimingStruct'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_OnStopRequest__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvOnStopRequest(mozilla::Move(channelStatus), mozilla::Move(timing))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_OnProgress__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_OnProgress", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            int64_t progress;
            int64_t progressMax;

            if ((!(Read((&(progress)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'int64_t'");
                return MsgValueError;
            }
            // Sentinel = 'progress'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 858119353)))) {
                FatalError("Error deserializing 'int64_t'");
                return MsgValueError;
            }
            if ((!(Read((&(progressMax)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'int64_t'");
                return MsgValueError;
            }
            // Sentinel = 'progressMax'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2530734978)))) {
                FatalError("Error deserializing 'int64_t'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_OnProgress__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvOnProgress(mozilla::Move(progress), mozilla::Move(progressMax))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_OnStatus__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_OnStatus", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsresult status;

            if ((!(Read((&(status)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            // Sentinel = 'status'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3714608576)))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_OnStatus__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvOnStatus(mozilla::Move(status))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_FailedAsyncOpen__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_FailedAsyncOpen", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsresult status;

            if ((!(Read((&(status)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            // Sentinel = 'status'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3714608576)))) {
                FatalError("Error deserializing 'nsresult'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_FailedAsyncOpen__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvFailedAsyncOpen(mozilla::Move(status))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_Redirect1Begin__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_Redirect1Begin", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            uint32_t registrarId;
            URIParams newUri;
            uint32_t redirectFlags;
            nsHttpResponseHead responseHead;
            nsCString securityInfoSerialization;
            nsCString channelId;

            if ((!(Read((&(registrarId)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            // Sentinel = 'registrarId'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3202787989)))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            if ((!(Read((&(newUri)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'URIParams'");
                return MsgValueError;
            }
            // Sentinel = 'newUri'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1147970150)))) {
                FatalError("Error deserializing 'URIParams'");
                return MsgValueError;
            }
            if ((!(Read((&(redirectFlags)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            // Sentinel = 'redirectFlags'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 286770900)))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            if ((!(Read((&(responseHead)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsHttpResponseHead'");
                return MsgValueError;
            }
            // Sentinel = 'responseHead'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3038698187)))) {
                FatalError("Error deserializing 'nsHttpResponseHead'");
                return MsgValueError;
            }
            if ((!(Read((&(securityInfoSerialization)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'securityInfoSerialization'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 985832975)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            if ((!(Read((&(channelId)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'channelId'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 6854027)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_Redirect1Begin__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvRedirect1Begin(mozilla::Move(registrarId), mozilla::Move(newUri), mozilla::Move(redirectFlags), mozilla::Move(responseHead), mozilla::Move(securityInfoSerialization), mozilla::Move(channelId))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_Redirect3Complete__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_Redirect3Complete", js::ProfileEntry::Category::OTHER);

            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_Redirect3Complete__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvRedirect3Complete()))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_AssociateApplicationCache__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_AssociateApplicationCache", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsCString groupID;
            nsCString clientID;

            if ((!(Read((&(groupID)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'groupID'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2673822077)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            if ((!(Read((&(clientID)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            // Sentinel = 'clientID'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3831418318)))) {
                FatalError("Error deserializing 'nsCString'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_AssociateApplicationCache__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvAssociateApplicationCache(mozilla::Move(groupID), mozilla::Move(clientID))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_NotifyTrackingProtectionDisabled__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_NotifyTrackingProtectionDisabled", js::ProfileEntry::Category::OTHER);

            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_NotifyTrackingProtectionDisabled__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvNotifyTrackingProtectionDisabled()))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_FlushedForDiversion__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_FlushedForDiversion", js::ProfileEntry::Category::OTHER);

            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_FlushedForDiversion__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvFlushedForDiversion()))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_DivertMessages__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_DivertMessages", js::ProfileEntry::Category::OTHER);

            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_DivertMessages__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvDivertMessages()))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_ReportSecurityMessage__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_ReportSecurityMessage", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            nsString messageTag;
            nsString messageCategory;

            if ((!(Read((&(messageTag)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsString'");
                return MsgValueError;
            }
            // Sentinel = 'messageTag'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 1576364117)))) {
                FatalError("Error deserializing 'nsString'");
                return MsgValueError;
            }
            if ((!(Read((&(messageCategory)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'nsString'");
                return MsgValueError;
            }
            // Sentinel = 'messageCategory'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3375428022)))) {
                FatalError("Error deserializing 'nsString'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_ReportSecurityMessage__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvReportSecurityMessage(mozilla::Move(messageTag), mozilla::Move(messageCategory))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_DeleteSelf__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_DeleteSelf", js::ProfileEntry::Category::OTHER);

            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_DeleteSelf__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvDeleteSelf()))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_IssueDeprecationWarning__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_IssueDeprecationWarning", js::ProfileEntry::Category::OTHER);

            PickleIterator iter__ = PickleIterator(msg__);
            uint32_t warning;
            bool asError;

            if ((!(Read((&(warning)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            // Sentinel = 'warning'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3208968083)))) {
                FatalError("Error deserializing 'uint32_t'");
                return MsgValueError;
            }
            if ((!(Read((&(asError)), (&(msg__)), (&(iter__)))))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            // Sentinel = 'asError'
            if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 4187201829)))) {
                FatalError("Error deserializing 'bool'");
                return MsgValueError;
            }
            (msg__).EndRead(iter__);
            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_IssueDeprecationWarning__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvIssueDeprecationWarning(mozilla::Move(warning), mozilla::Move(asError))))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    case PHttpChannel::Msg_FinishInterceptedRedirect__ID:
        {
            if (mozilla::ipc::LoggingEnabledFor("PHttpChannelChild")) {
                mozilla::ipc::LogMessageForProtocol("PHttpChannelChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
            }
            PROFILER_LABEL("PHttpChannel", "Msg_FinishInterceptedRedirect", js::ProfileEntry::Category::OTHER);

            if ((!(PHttpChannel::Transition(Trigger(Trigger::Send, PHttpChannel::Msg_FinishInterceptedRedirect__ID), (&(mState)))))) {
                NS_WARNING("bad state transition!");
            }
            if ((!(RecvFinishInterceptedRedirect()))) {
                mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
                return MsgProcessingError;
            }

            return MsgProcessed;
        }
    default:
        {
            return MsgNotKnown;
        }
    }
}

auto PHttpChannelChild::OnMessageReceived(
        const Message& msg__,
        Message*& reply__) -> PHttpChannelChild::Result
{
    return MsgNotKnown;
}

auto PHttpChannelChild::OnCallReceived(
        const Message& msg__,
        Message*& reply__) -> PHttpChannelChild::Result
{
    MOZ_ASSERT_UNREACHABLE("message protocol not supported");
    return MsgNotKnown;
}

auto PHttpChannelChild::GetProtocolTypeId() -> int32_t
{
    return PHttpChannelMsgStart;
}

auto PHttpChannelChild::ProtocolName() const -> const char*
{
    return "PHttpChannelChild";
}

auto PHttpChannelChild::DestroySubtree(ActorDestroyReason why) -> void
{
    // Unregister from our manager.
    Unregister(Id());
    SetId(1);

    // Finally, destroy "us".
    ActorDestroy(why);
}

auto PHttpChannelChild::DeallocSubtree() -> void
{
}

auto PHttpChannelChild::Write(
        const SystemPrincipalInfo& v__,
        Message* msg__) -> void
{
}

auto PHttpChannelChild::Read(
        SystemPrincipalInfo* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    return true;
}

auto PHttpChannelChild::Write(
        const nsTArray<PrincipalInfo>& v__,
        Message* msg__) -> void
{
    uint32_t length = (v__).Length();
    Write(length, msg__);
    // Sentinel = ('length', 'PrincipalInfo[]')
    (msg__)->WriteSentinel(1032188126);

    for (auto& elem : v__) {
        Write(elem, msg__);
        // Sentinel = 'PrincipalInfo[]'
        (msg__)->WriteSentinel(413380193);
    }
}

auto PHttpChannelChild::Read(
        nsTArray<PrincipalInfo>* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    nsTArray<PrincipalInfo> fa;
    uint32_t length;
    if ((!(Read((&(length)), msg__, iter__)))) {
        mozilla::ipc::ArrayLengthReadError("PrincipalInfo[]");
        return false;
    }
    // Sentinel = ('length', 'PrincipalInfo[]')
    if ((!((msg__)->ReadSentinel(iter__, 1032188126)))) {
        mozilla::ipc::ArrayLengthReadError("PrincipalInfo[]");
        return false;
    }

    PrincipalInfo* elems = (fa).AppendElements(length);
    for (uint32_t i = 0; (i) < (length); (++(i))) {
        if ((!(Read((&(elems[i])), msg__, iter__)))) {
            FatalError("Error deserializing 'PrincipalInfo[i]'");
            return false;
        }
        // Sentinel = 'PrincipalInfo[]'
        if ((!((msg__)->ReadSentinel(iter__, 413380193)))) {
            FatalError("Error deserializing 'PrincipalInfo[i]'");
            return false;
        }
    }
    (v__)->SwapElements(fa);
    return true;
}

auto PHttpChannelChild::Write(
        const OptionalURIParams& v__,
        Message* msg__) -> void
{
    typedef OptionalURIParams type__;
    Write(int((v__).type()), msg__);
    // Sentinel = 'OptionalURIParams'
    (msg__)->WriteSentinel(1977079525);

    switch ((v__).type()) {
    case type__::Tvoid_t:
        {
            Write((v__).get_void_t(), msg__);
            // Sentinel = 'Tvoid_t'
            (msg__)->WriteSentinel(3041273328);
            return;
        }
    case type__::TURIParams:
        {
            Write((v__).get_URIParams(), msg__);
            // Sentinel = 'TURIParams'
            (msg__)->WriteSentinel(1132652062);
            return;
        }
    default:
        {
            FatalError("unknown union type");
            return;
        }
    }
}

auto PHttpChannelChild::Read(
        OptionalURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    typedef OptionalURIParams type__;
    int type;
    if ((!(Read((&(type)), msg__, iter__)))) {
        mozilla::ipc::UnionTypeReadError("OptionalURIParams");
        return false;
    }
    // Sentinel = 'OptionalURIParams'
    if ((!((msg__)->ReadSentinel(iter__, 1977079525)))) {
        mozilla::ipc::UnionTypeReadError("OptionalURIParams");
        return false;
    }

    switch (type) {
    case type__::Tvoid_t:
        {
            void_t tmp = void_t();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_void_t())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'Tvoid_t'
            if ((!((msg__)->ReadSentinel(iter__, 3041273328)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TURIParams:
        {
            URIParams tmp = URIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_URIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 1132652062)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    default:
        {
            FatalError("unknown union type");
            return false;
        }
    }
}

auto PHttpChannelChild::Write(
        const ContentPrincipalInfoOriginNoSuffix& v__,
        Message* msg__) -> void
{
    typedef ContentPrincipalInfoOriginNoSuffix type__;
    Write(int((v__).type()), msg__);
    // Sentinel = 'ContentPrincipalInfoOriginNoSuffix'
    (msg__)->WriteSentinel(2442066713);

    switch ((v__).type()) {
    case type__::TnsCString:
        {
            Write((v__).get_nsCString(), msg__);
            // Sentinel = 'TnsCString'
            (msg__)->WriteSentinel(2427411293);
            return;
        }
    case type__::Tvoid_t:
        {
            Write((v__).get_void_t(), msg__);
            // Sentinel = 'Tvoid_t'
            (msg__)->WriteSentinel(3041273328);
            return;
        }
    default:
        {
            FatalError("unknown union type");
            return;
        }
    }
}

auto PHttpChannelChild::Read(
        ContentPrincipalInfoOriginNoSuffix* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    typedef ContentPrincipalInfoOriginNoSuffix type__;
    int type;
    if ((!(Read((&(type)), msg__, iter__)))) {
        mozilla::ipc::UnionTypeReadError("ContentPrincipalInfoOriginNoSuffix");
        return false;
    }
    // Sentinel = 'ContentPrincipalInfoOriginNoSuffix'
    if ((!((msg__)->ReadSentinel(iter__, 2442066713)))) {
        mozilla::ipc::UnionTypeReadError("ContentPrincipalInfoOriginNoSuffix");
        return false;
    }

    switch (type) {
    case type__::TnsCString:
        {
            nsCString tmp = nsCString();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_nsCString())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TnsCString'
            if ((!((msg__)->ReadSentinel(iter__, 2427411293)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::Tvoid_t:
        {
            void_t tmp = void_t();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_void_t())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'Tvoid_t'
            if ((!((msg__)->ReadSentinel(iter__, 3041273328)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    default:
        {
            FatalError("unknown union type");
            return false;
        }
    }
}

auto PHttpChannelChild::Write(
        const StandardURLParams& v__,
        Message* msg__) -> void
{
    Write((v__).urlType(), msg__);
    // Sentinel = 'urlType'
    (msg__)->WriteSentinel(4149428228);
    Write((v__).port(), msg__);
    // Sentinel = 'port'
    (msg__)->WriteSentinel(3633211549);
    Write((v__).defaultPort(), msg__);
    // Sentinel = 'defaultPort'
    (msg__)->WriteSentinel(599318897);
    Write((v__).spec(), msg__);
    // Sentinel = 'spec'
    (msg__)->WriteSentinel(1630740541);
    Write((v__).scheme(), msg__);
    // Sentinel = 'scheme'
    (msg__)->WriteSentinel(3619238715);
    Write((v__).authority(), msg__);
    // Sentinel = 'authority'
    (msg__)->WriteSentinel(1669684878);
    Write((v__).username(), msg__);
    // Sentinel = 'username'
    (msg__)->WriteSentinel(689225024);
    Write((v__).password(), msg__);
    // Sentinel = 'password'
    (msg__)->WriteSentinel(2527534683);
    Write((v__).host(), msg__);
    // Sentinel = 'host'
    (msg__)->WriteSentinel(4070301394);
    Write((v__).path(), msg__);
    // Sentinel = 'path'
    (msg__)->WriteSentinel(913629401);
    Write((v__).filePath(), msg__);
    // Sentinel = 'filePath'
    (msg__)->WriteSentinel(4122896455);
    Write((v__).directory(), msg__);
    // Sentinel = 'directory'
    (msg__)->WriteSentinel(1201172472);
    Write((v__).baseName(), msg__);
    // Sentinel = 'baseName'
    (msg__)->WriteSentinel(2448877418);
    Write((v__).extension(), msg__);
    // Sentinel = 'extension'
    (msg__)->WriteSentinel(3211853542);
    Write((v__).query(), msg__);
    // Sentinel = 'query'
    (msg__)->WriteSentinel(4249802777);
    Write((v__).ref(), msg__);
    // Sentinel = 'ref'
    (msg__)->WriteSentinel(2626476732);
    Write((v__).originCharset(), msg__);
    // Sentinel = 'originCharset'
    (msg__)->WriteSentinel(1320725495);
    Write((v__).isMutable(), msg__);
    // Sentinel = 'isMutable'
    (msg__)->WriteSentinel(3552466783);
    Write((v__).supportsFileURL(), msg__);
    // Sentinel = 'supportsFileURL'
    (msg__)->WriteSentinel(1871785710);
    Write((v__).hostEncoding(), msg__);
    // Sentinel = 'hostEncoding'
    (msg__)->WriteSentinel(1044841773);
}

auto PHttpChannelChild::Read(
        StandardURLParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->urlType())), msg__, iter__)))) {
        FatalError("Error deserializing 'urlType' (uint32_t) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'urlType'
    if ((!((msg__)->ReadSentinel(iter__, 4149428228)))) {
        FatalError("Error deserializing 'urlType' (uint32_t) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->port())), msg__, iter__)))) {
        FatalError("Error deserializing 'port' (int32_t) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'port'
    if ((!((msg__)->ReadSentinel(iter__, 3633211549)))) {
        FatalError("Error deserializing 'port' (int32_t) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->defaultPort())), msg__, iter__)))) {
        FatalError("Error deserializing 'defaultPort' (int32_t) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'defaultPort'
    if ((!((msg__)->ReadSentinel(iter__, 599318897)))) {
        FatalError("Error deserializing 'defaultPort' (int32_t) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->spec())), msg__, iter__)))) {
        FatalError("Error deserializing 'spec' (nsCString) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'spec'
    if ((!((msg__)->ReadSentinel(iter__, 1630740541)))) {
        FatalError("Error deserializing 'spec' (nsCString) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->scheme())), msg__, iter__)))) {
        FatalError("Error deserializing 'scheme' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'scheme'
    if ((!((msg__)->ReadSentinel(iter__, 3619238715)))) {
        FatalError("Error deserializing 'scheme' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->authority())), msg__, iter__)))) {
        FatalError("Error deserializing 'authority' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'authority'
    if ((!((msg__)->ReadSentinel(iter__, 1669684878)))) {
        FatalError("Error deserializing 'authority' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->username())), msg__, iter__)))) {
        FatalError("Error deserializing 'username' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'username'
    if ((!((msg__)->ReadSentinel(iter__, 689225024)))) {
        FatalError("Error deserializing 'username' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->password())), msg__, iter__)))) {
        FatalError("Error deserializing 'password' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'password'
    if ((!((msg__)->ReadSentinel(iter__, 2527534683)))) {
        FatalError("Error deserializing 'password' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->host())), msg__, iter__)))) {
        FatalError("Error deserializing 'host' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'host'
    if ((!((msg__)->ReadSentinel(iter__, 4070301394)))) {
        FatalError("Error deserializing 'host' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->path())), msg__, iter__)))) {
        FatalError("Error deserializing 'path' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'path'
    if ((!((msg__)->ReadSentinel(iter__, 913629401)))) {
        FatalError("Error deserializing 'path' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->filePath())), msg__, iter__)))) {
        FatalError("Error deserializing 'filePath' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'filePath'
    if ((!((msg__)->ReadSentinel(iter__, 4122896455)))) {
        FatalError("Error deserializing 'filePath' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->directory())), msg__, iter__)))) {
        FatalError("Error deserializing 'directory' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'directory'
    if ((!((msg__)->ReadSentinel(iter__, 1201172472)))) {
        FatalError("Error deserializing 'directory' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->baseName())), msg__, iter__)))) {
        FatalError("Error deserializing 'baseName' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'baseName'
    if ((!((msg__)->ReadSentinel(iter__, 2448877418)))) {
        FatalError("Error deserializing 'baseName' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->extension())), msg__, iter__)))) {
        FatalError("Error deserializing 'extension' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'extension'
    if ((!((msg__)->ReadSentinel(iter__, 3211853542)))) {
        FatalError("Error deserializing 'extension' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->query())), msg__, iter__)))) {
        FatalError("Error deserializing 'query' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'query'
    if ((!((msg__)->ReadSentinel(iter__, 4249802777)))) {
        FatalError("Error deserializing 'query' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->ref())), msg__, iter__)))) {
        FatalError("Error deserializing 'ref' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'ref'
    if ((!((msg__)->ReadSentinel(iter__, 2626476732)))) {
        FatalError("Error deserializing 'ref' (StandardURLSegment) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->originCharset())), msg__, iter__)))) {
        FatalError("Error deserializing 'originCharset' (nsCString) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'originCharset'
    if ((!((msg__)->ReadSentinel(iter__, 1320725495)))) {
        FatalError("Error deserializing 'originCharset' (nsCString) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->isMutable())), msg__, iter__)))) {
        FatalError("Error deserializing 'isMutable' (bool) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'isMutable'
    if ((!((msg__)->ReadSentinel(iter__, 3552466783)))) {
        FatalError("Error deserializing 'isMutable' (bool) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->supportsFileURL())), msg__, iter__)))) {
        FatalError("Error deserializing 'supportsFileURL' (bool) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'supportsFileURL'
    if ((!((msg__)->ReadSentinel(iter__, 1871785710)))) {
        FatalError("Error deserializing 'supportsFileURL' (bool) member of 'StandardURLParams'");
        return false;
    }
    if ((!(Read((&((v__)->hostEncoding())), msg__, iter__)))) {
        FatalError("Error deserializing 'hostEncoding' (uint32_t) member of 'StandardURLParams'");
        return false;
    }
    // Sentinel = 'hostEncoding'
    if ((!((msg__)->ReadSentinel(iter__, 1044841773)))) {
        FatalError("Error deserializing 'hostEncoding' (uint32_t) member of 'StandardURLParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const URIParams& v__,
        Message* msg__) -> void
{
    typedef URIParams type__;
    Write(int((v__).type()), msg__);
    // Sentinel = 'URIParams'
    (msg__)->WriteSentinel(1039516337);

    switch ((v__).type()) {
    case type__::TSimpleURIParams:
        {
            Write((v__).get_SimpleURIParams(), msg__);
            // Sentinel = 'TSimpleURIParams'
            (msg__)->WriteSentinel(4028607586);
            return;
        }
    case type__::TStandardURLParams:
        {
            Write((v__).get_StandardURLParams(), msg__);
            // Sentinel = 'TStandardURLParams'
            (msg__)->WriteSentinel(248174578);
            return;
        }
    case type__::TJARURIParams:
        {
            Write((v__).get_JARURIParams(), msg__);
            // Sentinel = 'TJARURIParams'
            (msg__)->WriteSentinel(3404434792);
            return;
        }
    case type__::TIconURIParams:
        {
            Write((v__).get_IconURIParams(), msg__);
            // Sentinel = 'TIconURIParams'
            (msg__)->WriteSentinel(1824279023);
            return;
        }
    case type__::TNullPrincipalURIParams:
        {
            Write((v__).get_NullPrincipalURIParams(), msg__);
            // Sentinel = 'TNullPrincipalURIParams'
            (msg__)->WriteSentinel(216801182);
            return;
        }
    case type__::TJSURIParams:
        {
            Write((v__).get_JSURIParams(), msg__);
            // Sentinel = 'TJSURIParams'
            (msg__)->WriteSentinel(32222119);
            return;
        }
    case type__::TSimpleNestedURIParams:
        {
            Write((v__).get_SimpleNestedURIParams(), msg__);
            // Sentinel = 'TSimpleNestedURIParams'
            (msg__)->WriteSentinel(3192238307);
            return;
        }
    case type__::THostObjectURIParams:
        {
            Write((v__).get_HostObjectURIParams(), msg__);
            // Sentinel = 'THostObjectURIParams'
            (msg__)->WriteSentinel(1307971301);
            return;
        }
    default:
        {
            FatalError("unknown union type");
            return;
        }
    }
}

auto PHttpChannelChild::Read(
        URIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    typedef URIParams type__;
    int type;
    if ((!(Read((&(type)), msg__, iter__)))) {
        mozilla::ipc::UnionTypeReadError("URIParams");
        return false;
    }
    // Sentinel = 'URIParams'
    if ((!((msg__)->ReadSentinel(iter__, 1039516337)))) {
        mozilla::ipc::UnionTypeReadError("URIParams");
        return false;
    }

    switch (type) {
    case type__::TSimpleURIParams:
        {
            SimpleURIParams tmp = SimpleURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_SimpleURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TSimpleURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 4028607586)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TStandardURLParams:
        {
            StandardURLParams tmp = StandardURLParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_StandardURLParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TStandardURLParams'
            if ((!((msg__)->ReadSentinel(iter__, 248174578)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TJARURIParams:
        {
            JARURIParams tmp = JARURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_JARURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TJARURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 3404434792)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TIconURIParams:
        {
            IconURIParams tmp = IconURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_IconURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TIconURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 1824279023)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TNullPrincipalURIParams:
        {
            NullPrincipalURIParams tmp = NullPrincipalURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_NullPrincipalURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TNullPrincipalURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 216801182)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TJSURIParams:
        {
            JSURIParams tmp = JSURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_JSURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TJSURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 32222119)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TSimpleNestedURIParams:
        {
            SimpleNestedURIParams tmp = SimpleNestedURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_SimpleNestedURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TSimpleNestedURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 3192238307)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::THostObjectURIParams:
        {
            HostObjectURIParams tmp = HostObjectURIParams();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_HostObjectURIParams())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'THostObjectURIParams'
            if ((!((msg__)->ReadSentinel(iter__, 1307971301)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    default:
        {
            FatalError("unknown union type");
            return false;
        }
    }
}

auto PHttpChannelChild::Write(
        const CorsPreflightArgs& v__,
        Message* msg__) -> void
{
    Write((v__).unsafeHeaders(), msg__);
    // Sentinel = 'unsafeHeaders'
    (msg__)->WriteSentinel(259870561);
}

auto PHttpChannelChild::Read(
        CorsPreflightArgs* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->unsafeHeaders())), msg__, iter__)))) {
        FatalError("Error deserializing 'unsafeHeaders' (nsCString[]) member of 'CorsPreflightArgs'");
        return false;
    }
    // Sentinel = 'unsafeHeaders'
    if ((!((msg__)->ReadSentinel(iter__, 259870561)))) {
        FatalError("Error deserializing 'unsafeHeaders' (nsCString[]) member of 'CorsPreflightArgs'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const SimpleNestedURIParams& v__,
        Message* msg__) -> void
{
    Write((v__).simpleParams(), msg__);
    // Sentinel = 'simpleParams'
    (msg__)->WriteSentinel(3404291700);
    Write((v__).innerURI(), msg__);
    // Sentinel = 'innerURI'
    (msg__)->WriteSentinel(2573245334);
}

auto PHttpChannelChild::Read(
        SimpleNestedURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->simpleParams())), msg__, iter__)))) {
        FatalError("Error deserializing 'simpleParams' (SimpleURIParams) member of 'SimpleNestedURIParams'");
        return false;
    }
    // Sentinel = 'simpleParams'
    if ((!((msg__)->ReadSentinel(iter__, 3404291700)))) {
        FatalError("Error deserializing 'simpleParams' (SimpleURIParams) member of 'SimpleNestedURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->innerURI())), msg__, iter__)))) {
        FatalError("Error deserializing 'innerURI' (URIParams) member of 'SimpleNestedURIParams'");
        return false;
    }
    // Sentinel = 'innerURI'
    if ((!((msg__)->ReadSentinel(iter__, 2573245334)))) {
        FatalError("Error deserializing 'innerURI' (URIParams) member of 'SimpleNestedURIParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const OptionalPrincipalInfo& v__,
        Message* msg__) -> void
{
    typedef OptionalPrincipalInfo type__;
    Write(int((v__).type()), msg__);
    // Sentinel = 'OptionalPrincipalInfo'
    (msg__)->WriteSentinel(3041452007);

    switch ((v__).type()) {
    case type__::Tvoid_t:
        {
            Write((v__).get_void_t(), msg__);
            // Sentinel = 'Tvoid_t'
            (msg__)->WriteSentinel(3041273328);
            return;
        }
    case type__::TPrincipalInfo:
        {
            Write((v__).get_PrincipalInfo(), msg__);
            // Sentinel = 'TPrincipalInfo'
            (msg__)->WriteSentinel(1396743580);
            return;
        }
    default:
        {
            FatalError("unknown union type");
            return;
        }
    }
}

auto PHttpChannelChild::Read(
        OptionalPrincipalInfo* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    typedef OptionalPrincipalInfo type__;
    int type;
    if ((!(Read((&(type)), msg__, iter__)))) {
        mozilla::ipc::UnionTypeReadError("OptionalPrincipalInfo");
        return false;
    }
    // Sentinel = 'OptionalPrincipalInfo'
    if ((!((msg__)->ReadSentinel(iter__, 3041452007)))) {
        mozilla::ipc::UnionTypeReadError("OptionalPrincipalInfo");
        return false;
    }

    switch (type) {
    case type__::Tvoid_t:
        {
            void_t tmp = void_t();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_void_t())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'Tvoid_t'
            if ((!((msg__)->ReadSentinel(iter__, 3041273328)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TPrincipalInfo:
        {
            PrincipalInfo tmp = PrincipalInfo();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_PrincipalInfo())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TPrincipalInfo'
            if ((!((msg__)->ReadSentinel(iter__, 1396743580)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    default:
        {
            FatalError("unknown union type");
            return false;
        }
    }
}

auto PHttpChannelChild::Write(
        const ExpandedPrincipalInfo& v__,
        Message* msg__) -> void
{
    Write((v__).attrs(), msg__);
    // Sentinel = 'attrs'
    (msg__)->WriteSentinel(3014987797);
    Write((v__).whitelist(), msg__);
    // Sentinel = 'whitelist'
    (msg__)->WriteSentinel(3731637258);
}

auto PHttpChannelChild::Read(
        ExpandedPrincipalInfo* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->attrs())), msg__, iter__)))) {
        FatalError("Error deserializing 'attrs' (PrincipalOriginAttributes) member of 'ExpandedPrincipalInfo'");
        return false;
    }
    // Sentinel = 'attrs'
    if ((!((msg__)->ReadSentinel(iter__, 3014987797)))) {
        FatalError("Error deserializing 'attrs' (PrincipalOriginAttributes) member of 'ExpandedPrincipalInfo'");
        return false;
    }
    if ((!(Read((&((v__)->whitelist())), msg__, iter__)))) {
        FatalError("Error deserializing 'whitelist' (PrincipalInfo[]) member of 'ExpandedPrincipalInfo'");
        return false;
    }
    // Sentinel = 'whitelist'
    if ((!((msg__)->ReadSentinel(iter__, 3731637258)))) {
        FatalError("Error deserializing 'whitelist' (PrincipalInfo[]) member of 'ExpandedPrincipalInfo'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const HostObjectURIParams& v__,
        Message* msg__) -> void
{
    Write((v__).simpleParams(), msg__);
    // Sentinel = 'simpleParams'
    (msg__)->WriteSentinel(3404291700);
    Write((v__).principal(), msg__);
    // Sentinel = 'principal'
    (msg__)->WriteSentinel(732240927);
}

auto PHttpChannelChild::Read(
        HostObjectURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->simpleParams())), msg__, iter__)))) {
        FatalError("Error deserializing 'simpleParams' (SimpleURIParams) member of 'HostObjectURIParams'");
        return false;
    }
    // Sentinel = 'simpleParams'
    if ((!((msg__)->ReadSentinel(iter__, 3404291700)))) {
        FatalError("Error deserializing 'simpleParams' (SimpleURIParams) member of 'HostObjectURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->principal())), msg__, iter__)))) {
        FatalError("Error deserializing 'principal' (OptionalPrincipalInfo) member of 'HostObjectURIParams'");
        return false;
    }
    // Sentinel = 'principal'
    if ((!((msg__)->ReadSentinel(iter__, 732240927)))) {
        FatalError("Error deserializing 'principal' (OptionalPrincipalInfo) member of 'HostObjectURIParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const PHttpChannelChild* v__,
        Message* msg__,
        bool nullable__) -> void
{
    int32_t id;
    if ((!(v__))) {
        if ((!(nullable__))) {
            FatalError("NULL actor value passed to non-nullable param");
        }
        id = 0;
    }
    else {
        id = (v__)->Id();
        if ((1) == (id)) {
            FatalError("actor has been |delete|d");
        }
    }

    Write(id, msg__);
}

auto PHttpChannelChild::Read(
        PHttpChannelChild** v__,
        const Message* msg__,
        PickleIterator* iter__,
        bool nullable__) -> bool
{
    Maybe<mozilla::ipc::IProtocol*> actor = ReadActor(msg__, iter__, nullable__, "PHttpChannel", PHttpChannelMsgStart);
    if ((actor).isNothing()) {
        return false;
    }

    (*(v__)) = static_cast<PHttpChannelChild*>((actor).value());
    return true;
}

auto PHttpChannelChild::Write(
        const PrincipalInfo& v__,
        Message* msg__) -> void
{
    typedef PrincipalInfo type__;
    Write(int((v__).type()), msg__);
    // Sentinel = 'PrincipalInfo'
    (msg__)->WriteSentinel(4194518819);

    switch ((v__).type()) {
    case type__::TContentPrincipalInfo:
        {
            Write((v__).get_ContentPrincipalInfo(), msg__);
            // Sentinel = 'TContentPrincipalInfo'
            (msg__)->WriteSentinel(3677342258);
            return;
        }
    case type__::TSystemPrincipalInfo:
        {
            Write((v__).get_SystemPrincipalInfo(), msg__);
            // Sentinel = 'TSystemPrincipalInfo'
            (msg__)->WriteSentinel(3590603679);
            return;
        }
    case type__::TNullPrincipalInfo:
        {
            Write((v__).get_NullPrincipalInfo(), msg__);
            // Sentinel = 'TNullPrincipalInfo'
            (msg__)->WriteSentinel(3477774965);
            return;
        }
    case type__::TExpandedPrincipalInfo:
        {
            Write((v__).get_ExpandedPrincipalInfo(), msg__);
            // Sentinel = 'TExpandedPrincipalInfo'
            (msg__)->WriteSentinel(589324917);
            return;
        }
    default:
        {
            FatalError("unknown union type");
            return;
        }
    }
}

auto PHttpChannelChild::Read(
        PrincipalInfo* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    typedef PrincipalInfo type__;
    int type;
    if ((!(Read((&(type)), msg__, iter__)))) {
        mozilla::ipc::UnionTypeReadError("PrincipalInfo");
        return false;
    }
    // Sentinel = 'PrincipalInfo'
    if ((!((msg__)->ReadSentinel(iter__, 4194518819)))) {
        mozilla::ipc::UnionTypeReadError("PrincipalInfo");
        return false;
    }

    switch (type) {
    case type__::TContentPrincipalInfo:
        {
            ContentPrincipalInfo tmp = ContentPrincipalInfo();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_ContentPrincipalInfo())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TContentPrincipalInfo'
            if ((!((msg__)->ReadSentinel(iter__, 3677342258)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TSystemPrincipalInfo:
        {
            SystemPrincipalInfo tmp = SystemPrincipalInfo();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_SystemPrincipalInfo())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TSystemPrincipalInfo'
            if ((!((msg__)->ReadSentinel(iter__, 3590603679)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TNullPrincipalInfo:
        {
            NullPrincipalInfo tmp = NullPrincipalInfo();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_NullPrincipalInfo())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TNullPrincipalInfo'
            if ((!((msg__)->ReadSentinel(iter__, 3477774965)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TExpandedPrincipalInfo:
        {
            ExpandedPrincipalInfo tmp = ExpandedPrincipalInfo();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_ExpandedPrincipalInfo())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TExpandedPrincipalInfo'
            if ((!((msg__)->ReadSentinel(iter__, 589324917)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    default:
        {
            FatalError("unknown union type");
            return false;
        }
    }
}

auto PHttpChannelChild::Write(
        const JARURIParams& v__,
        Message* msg__) -> void
{
    Write((v__).jarFile(), msg__);
    // Sentinel = 'jarFile'
    (msg__)->WriteSentinel(1572070078);
    Write((v__).jarEntry(), msg__);
    // Sentinel = 'jarEntry'
    (msg__)->WriteSentinel(941016033);
    Write((v__).charset(), msg__);
    // Sentinel = 'charset'
    (msg__)->WriteSentinel(1551550891);
}

auto PHttpChannelChild::Read(
        JARURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->jarFile())), msg__, iter__)))) {
        FatalError("Error deserializing 'jarFile' (URIParams) member of 'JARURIParams'");
        return false;
    }
    // Sentinel = 'jarFile'
    if ((!((msg__)->ReadSentinel(iter__, 1572070078)))) {
        FatalError("Error deserializing 'jarFile' (URIParams) member of 'JARURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->jarEntry())), msg__, iter__)))) {
        FatalError("Error deserializing 'jarEntry' (URIParams) member of 'JARURIParams'");
        return false;
    }
    // Sentinel = 'jarEntry'
    if ((!((msg__)->ReadSentinel(iter__, 941016033)))) {
        FatalError("Error deserializing 'jarEntry' (URIParams) member of 'JARURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->charset())), msg__, iter__)))) {
        FatalError("Error deserializing 'charset' (nsCString) member of 'JARURIParams'");
        return false;
    }
    // Sentinel = 'charset'
    if ((!((msg__)->ReadSentinel(iter__, 1551550891)))) {
        FatalError("Error deserializing 'charset' (nsCString) member of 'JARURIParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const ContentPrincipalInfo& v__,
        Message* msg__) -> void
{
    Write((v__).attrs(), msg__);
    // Sentinel = 'attrs'
    (msg__)->WriteSentinel(3014987797);
    Write((v__).originNoSuffix(), msg__);
    // Sentinel = 'originNoSuffix'
    (msg__)->WriteSentinel(2833071422);
    Write((v__).spec(), msg__);
    // Sentinel = 'spec'
    (msg__)->WriteSentinel(1630740541);
}

auto PHttpChannelChild::Read(
        ContentPrincipalInfo* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->attrs())), msg__, iter__)))) {
        FatalError("Error deserializing 'attrs' (PrincipalOriginAttributes) member of 'ContentPrincipalInfo'");
        return false;
    }
    // Sentinel = 'attrs'
    if ((!((msg__)->ReadSentinel(iter__, 3014987797)))) {
        FatalError("Error deserializing 'attrs' (PrincipalOriginAttributes) member of 'ContentPrincipalInfo'");
        return false;
    }
    if ((!(Read((&((v__)->originNoSuffix())), msg__, iter__)))) {
        FatalError("Error deserializing 'originNoSuffix' (ContentPrincipalInfoOriginNoSuffix) member of 'ContentPrincipalInfo'");
        return false;
    }
    // Sentinel = 'originNoSuffix'
    if ((!((msg__)->ReadSentinel(iter__, 2833071422)))) {
        FatalError("Error deserializing 'originNoSuffix' (ContentPrincipalInfoOriginNoSuffix) member of 'ContentPrincipalInfo'");
        return false;
    }
    if ((!(Read((&((v__)->spec())), msg__, iter__)))) {
        FatalError("Error deserializing 'spec' (nsCString) member of 'ContentPrincipalInfo'");
        return false;
    }
    // Sentinel = 'spec'
    if ((!((msg__)->ReadSentinel(iter__, 1630740541)))) {
        FatalError("Error deserializing 'spec' (nsCString) member of 'ContentPrincipalInfo'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const SimpleURIParams& v__,
        Message* msg__) -> void
{
    Write((v__).scheme(), msg__);
    // Sentinel = 'scheme'
    (msg__)->WriteSentinel(3619238715);
    Write((v__).path(), msg__);
    // Sentinel = 'path'
    (msg__)->WriteSentinel(913629401);
    Write((v__).ref(), msg__);
    // Sentinel = 'ref'
    (msg__)->WriteSentinel(2626476732);
    Write((v__).query(), msg__);
    // Sentinel = 'query'
    (msg__)->WriteSentinel(4249802777);
    Write((v__).isMutable(), msg__);
    // Sentinel = 'isMutable'
    (msg__)->WriteSentinel(3552466783);
}

auto PHttpChannelChild::Read(
        SimpleURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->scheme())), msg__, iter__)))) {
        FatalError("Error deserializing 'scheme' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    // Sentinel = 'scheme'
    if ((!((msg__)->ReadSentinel(iter__, 3619238715)))) {
        FatalError("Error deserializing 'scheme' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->path())), msg__, iter__)))) {
        FatalError("Error deserializing 'path' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    // Sentinel = 'path'
    if ((!((msg__)->ReadSentinel(iter__, 913629401)))) {
        FatalError("Error deserializing 'path' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->ref())), msg__, iter__)))) {
        FatalError("Error deserializing 'ref' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    // Sentinel = 'ref'
    if ((!((msg__)->ReadSentinel(iter__, 2626476732)))) {
        FatalError("Error deserializing 'ref' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->query())), msg__, iter__)))) {
        FatalError("Error deserializing 'query' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    // Sentinel = 'query'
    if ((!((msg__)->ReadSentinel(iter__, 4249802777)))) {
        FatalError("Error deserializing 'query' (nsCString) member of 'SimpleURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->isMutable())), msg__, iter__)))) {
        FatalError("Error deserializing 'isMutable' (bool) member of 'SimpleURIParams'");
        return false;
    }
    // Sentinel = 'isMutable'
    if ((!((msg__)->ReadSentinel(iter__, 3552466783)))) {
        FatalError("Error deserializing 'isMutable' (bool) member of 'SimpleURIParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const NullPrincipalURIParams& v__,
        Message* msg__) -> void
{
}

auto PHttpChannelChild::Read(
        NullPrincipalURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    return true;
}

auto PHttpChannelChild::Write(
        const IconURIParams& v__,
        Message* msg__) -> void
{
    Write((v__).uri(), msg__);
    // Sentinel = 'uri'
    (msg__)->WriteSentinel(1453210605);
    Write((v__).size(), msg__);
    // Sentinel = 'size'
    (msg__)->WriteSentinel(931048223);
    Write((v__).contentType(), msg__);
    // Sentinel = 'contentType'
    (msg__)->WriteSentinel(2092571716);
    Write((v__).fileName(), msg__);
    // Sentinel = 'fileName'
    (msg__)->WriteSentinel(3833449039);
    Write((v__).stockIcon(), msg__);
    // Sentinel = 'stockIcon'
    (msg__)->WriteSentinel(3601770784);
    Write((v__).iconSize(), msg__);
    // Sentinel = 'iconSize'
    (msg__)->WriteSentinel(2585310920);
    Write((v__).iconState(), msg__);
    // Sentinel = 'iconState'
    (msg__)->WriteSentinel(3444306207);
}

auto PHttpChannelChild::Read(
        IconURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->uri())), msg__, iter__)))) {
        FatalError("Error deserializing 'uri' (OptionalURIParams) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'uri'
    if ((!((msg__)->ReadSentinel(iter__, 1453210605)))) {
        FatalError("Error deserializing 'uri' (OptionalURIParams) member of 'IconURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->size())), msg__, iter__)))) {
        FatalError("Error deserializing 'size' (uint32_t) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'size'
    if ((!((msg__)->ReadSentinel(iter__, 931048223)))) {
        FatalError("Error deserializing 'size' (uint32_t) member of 'IconURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->contentType())), msg__, iter__)))) {
        FatalError("Error deserializing 'contentType' (nsCString) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'contentType'
    if ((!((msg__)->ReadSentinel(iter__, 2092571716)))) {
        FatalError("Error deserializing 'contentType' (nsCString) member of 'IconURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->fileName())), msg__, iter__)))) {
        FatalError("Error deserializing 'fileName' (nsCString) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'fileName'
    if ((!((msg__)->ReadSentinel(iter__, 3833449039)))) {
        FatalError("Error deserializing 'fileName' (nsCString) member of 'IconURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->stockIcon())), msg__, iter__)))) {
        FatalError("Error deserializing 'stockIcon' (nsCString) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'stockIcon'
    if ((!((msg__)->ReadSentinel(iter__, 3601770784)))) {
        FatalError("Error deserializing 'stockIcon' (nsCString) member of 'IconURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->iconSize())), msg__, iter__)))) {
        FatalError("Error deserializing 'iconSize' (int32_t) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'iconSize'
    if ((!((msg__)->ReadSentinel(iter__, 2585310920)))) {
        FatalError("Error deserializing 'iconSize' (int32_t) member of 'IconURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->iconState())), msg__, iter__)))) {
        FatalError("Error deserializing 'iconState' (int32_t) member of 'IconURIParams'");
        return false;
    }
    // Sentinel = 'iconState'
    if ((!((msg__)->ReadSentinel(iter__, 3444306207)))) {
        FatalError("Error deserializing 'iconState' (int32_t) member of 'IconURIParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const StandardURLSegment& v__,
        Message* msg__) -> void
{
    Write((v__).position(), msg__);
    // Sentinel = 'position'
    (msg__)->WriteSentinel(50847225);
    Write((v__).length(), msg__);
    // Sentinel = 'length'
    (msg__)->WriteSentinel(1726618354);
}

auto PHttpChannelChild::Read(
        StandardURLSegment* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->position())), msg__, iter__)))) {
        FatalError("Error deserializing 'position' (uint32_t) member of 'StandardURLSegment'");
        return false;
    }
    // Sentinel = 'position'
    if ((!((msg__)->ReadSentinel(iter__, 50847225)))) {
        FatalError("Error deserializing 'position' (uint32_t) member of 'StandardURLSegment'");
        return false;
    }
    if ((!(Read((&((v__)->length())), msg__, iter__)))) {
        FatalError("Error deserializing 'length' (int32_t) member of 'StandardURLSegment'");
        return false;
    }
    // Sentinel = 'length'
    if ((!((msg__)->ReadSentinel(iter__, 1726618354)))) {
        FatalError("Error deserializing 'length' (int32_t) member of 'StandardURLSegment'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const JSURIParams& v__,
        Message* msg__) -> void
{
    Write((v__).simpleParams(), msg__);
    // Sentinel = 'simpleParams'
    (msg__)->WriteSentinel(3404291700);
    Write((v__).baseURI(), msg__);
    // Sentinel = 'baseURI'
    (msg__)->WriteSentinel(1836705256);
}

auto PHttpChannelChild::Read(
        JSURIParams* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->simpleParams())), msg__, iter__)))) {
        FatalError("Error deserializing 'simpleParams' (SimpleURIParams) member of 'JSURIParams'");
        return false;
    }
    // Sentinel = 'simpleParams'
    if ((!((msg__)->ReadSentinel(iter__, 3404291700)))) {
        FatalError("Error deserializing 'simpleParams' (SimpleURIParams) member of 'JSURIParams'");
        return false;
    }
    if ((!(Read((&((v__)->baseURI())), msg__, iter__)))) {
        FatalError("Error deserializing 'baseURI' (OptionalURIParams) member of 'JSURIParams'");
        return false;
    }
    // Sentinel = 'baseURI'
    if ((!((msg__)->ReadSentinel(iter__, 1836705256)))) {
        FatalError("Error deserializing 'baseURI' (OptionalURIParams) member of 'JSURIParams'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const NullPrincipalInfo& v__,
        Message* msg__) -> void
{
    Write((v__).attrs(), msg__);
    // Sentinel = 'attrs'
    (msg__)->WriteSentinel(3014987797);
}

auto PHttpChannelChild::Read(
        NullPrincipalInfo* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    if ((!(Read((&((v__)->attrs())), msg__, iter__)))) {
        FatalError("Error deserializing 'attrs' (PrincipalOriginAttributes) member of 'NullPrincipalInfo'");
        return false;
    }
    // Sentinel = 'attrs'
    if ((!((msg__)->ReadSentinel(iter__, 3014987797)))) {
        FatalError("Error deserializing 'attrs' (PrincipalOriginAttributes) member of 'NullPrincipalInfo'");
        return false;
    }
    return true;
}

auto PHttpChannelChild::Write(
        const OptionalCorsPreflightArgs& v__,
        Message* msg__) -> void
{
    typedef OptionalCorsPreflightArgs type__;
    Write(int((v__).type()), msg__);
    // Sentinel = 'OptionalCorsPreflightArgs'
    (msg__)->WriteSentinel(3238697490);

    switch ((v__).type()) {
    case type__::Tvoid_t:
        {
            Write((v__).get_void_t(), msg__);
            // Sentinel = 'Tvoid_t'
            (msg__)->WriteSentinel(3041273328);
            return;
        }
    case type__::TCorsPreflightArgs:
        {
            Write((v__).get_CorsPreflightArgs(), msg__);
            // Sentinel = 'TCorsPreflightArgs'
            (msg__)->WriteSentinel(2263898105);
            return;
        }
    default:
        {
            FatalError("unknown union type");
            return;
        }
    }
}

auto PHttpChannelChild::Read(
        OptionalCorsPreflightArgs* v__,
        const Message* msg__,
        PickleIterator* iter__) -> bool
{
    typedef OptionalCorsPreflightArgs type__;
    int type;
    if ((!(Read((&(type)), msg__, iter__)))) {
        mozilla::ipc::UnionTypeReadError("OptionalCorsPreflightArgs");
        return false;
    }
    // Sentinel = 'OptionalCorsPreflightArgs'
    if ((!((msg__)->ReadSentinel(iter__, 3238697490)))) {
        mozilla::ipc::UnionTypeReadError("OptionalCorsPreflightArgs");
        return false;
    }

    switch (type) {
    case type__::Tvoid_t:
        {
            void_t tmp = void_t();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_void_t())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'Tvoid_t'
            if ((!((msg__)->ReadSentinel(iter__, 3041273328)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    case type__::TCorsPreflightArgs:
        {
            CorsPreflightArgs tmp = CorsPreflightArgs();
            (*(v__)) = tmp;
            if ((!(Read((&((v__)->get_CorsPreflightArgs())), msg__, iter__)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            // Sentinel = 'TCorsPreflightArgs'
            if ((!((msg__)->ReadSentinel(iter__, 2263898105)))) {
                FatalError("Error deserializing Union type");
                return false;
            }
            return true;
        }
    default:
        {
            FatalError("unknown union type");
            return false;
        }
    }
}



} // namespace net
} // namespace mozilla
