LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/ipc/ipdl - PStunAddrsRequestChild.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 0 90 0.0 %
Date: 2017-07-14 16:53:18 Functions: 0 17 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : //
       2             : // Automatically generated by ipdlc.
       3             : // Edit at your own risk
       4             : //
       5             : 
       6             : 
       7             : #include "mozilla/net/PStunAddrsRequestChild.h"
       8             : 
       9             : #include "mozilla/net/PNeckoChild.h"
      10             : 
      11             : #include "nsIFile.h"
      12             : #include "GeckoProfiler.h"
      13             : 
      14             : namespace mozilla {
      15             : namespace net {
      16             : 
      17             : 
      18           0 : auto PStunAddrsRequestChild::ActorDestroy(ActorDestroyReason aWhy) -> void
      19             : {
      20           0 : }
      21             : 
      22           0 : MOZ_IMPLICIT PStunAddrsRequestChild::PStunAddrsRequestChild() :
      23             :     mozilla::ipc::IProtocol(mozilla::ipc::ChildSide),
      24           0 :     mState(PStunAddrsRequest::__Dead)
      25             : {
      26           0 :     MOZ_COUNT_CTOR(PStunAddrsRequestChild);
      27           0 : }
      28             : 
      29           0 : PStunAddrsRequestChild::~PStunAddrsRequestChild()
      30             : {
      31           0 :     MOZ_COUNT_DTOR(PStunAddrsRequestChild);
      32           0 : }
      33             : 
      34           0 : auto PStunAddrsRequestChild::Manager() const -> PNeckoChild*
      35             : {
      36           0 :     return static_cast<PNeckoChild*>(IProtocol::Manager());
      37             : }
      38             : 
      39           0 : auto PStunAddrsRequestChild::SendGetStunAddrs() -> bool
      40             : {
      41           0 :     IPC::Message* msg__ = PStunAddrsRequest::Msg_GetStunAddrs(Id());
      42             : 
      43             : 
      44             : 
      45             : 
      46             : 
      47           0 :     if (mozilla::ipc::LoggingEnabledFor("PStunAddrsRequestChild")) {
      48           0 :         mozilla::ipc::LogMessageForProtocol("PStunAddrsRequestChild", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
      49             :     }
      50           0 :     AUTO_PROFILER_LABEL("PStunAddrsRequest::Msg_GetStunAddrs", OTHER);
      51           0 :     PStunAddrsRequest::Transition(PStunAddrsRequest::Msg_GetStunAddrs__ID, (&(mState)));
      52             : 
      53           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
      54           0 :     return sendok__;
      55             : }
      56             : 
      57           0 : auto PStunAddrsRequestChild::Send__delete__(PStunAddrsRequestChild* actor) -> bool
      58             : {
      59           0 :     if ((!(actor))) {
      60           0 :         return false;
      61             :     }
      62             : 
      63           0 :     IPC::Message* msg__ = PStunAddrsRequest::Msg___delete__((actor)->Id());
      64             : 
      65           0 :     (actor)->Write(actor, msg__, false);
      66             :     // Sentinel = 'actor'
      67           0 :     (msg__)->WriteSentinel(875202478);
      68             : 
      69             : 
      70             : 
      71           0 :     if (mozilla::ipc::LoggingEnabledFor("PStunAddrsRequestChild")) {
      72           0 :         mozilla::ipc::LogMessageForProtocol("PStunAddrsRequestChild", (actor)->OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
      73             :     }
      74           0 :     AUTO_PROFILER_LABEL("PStunAddrsRequest::Msg___delete__", OTHER);
      75           0 :     PStunAddrsRequest::Transition(PStunAddrsRequest::Msg___delete____ID, (&((actor)->mState)));
      76             : 
      77           0 :     bool sendok__ = ((actor)->GetIPCChannel())->Send(msg__);
      78             : 
      79           0 :     IProtocol* mgr = (actor)->Manager();
      80           0 :     (actor)->DestroySubtree(Deletion);
      81           0 :     (actor)->DeallocSubtree();
      82           0 :     (mgr)->RemoveManagee(PStunAddrsRequestMsgStart, actor);
      83           0 :     return sendok__;
      84             : }
      85             : 
      86           0 : auto PStunAddrsRequestChild::RemoveManagee(
      87             :         int32_t aProtocolId,
      88             :         ProtocolBase* aListener) -> void
      89             : {
      90           0 :     FatalError("unreached");
      91           0 :     return;
      92             : }
      93             : 
      94           0 : auto PStunAddrsRequestChild::OnMessageReceived(const Message& msg__) -> PStunAddrsRequestChild::Result
      95             : {
      96           0 :     switch ((msg__).type()) {
      97             :     case PStunAddrsRequest::Reply___delete____ID:
      98             :         {
      99           0 :             return MsgProcessed;
     100             :         }
     101             :     case PStunAddrsRequest::Msg_OnStunAddrsAvailable__ID:
     102             :         {
     103           0 :             if (mozilla::ipc::LoggingEnabledFor("PStunAddrsRequestChild")) {
     104           0 :                 mozilla::ipc::LogMessageForProtocol("PStunAddrsRequestChild", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
     105             :             }
     106           0 :             AUTO_PROFILER_LABEL("PStunAddrsRequest::Msg_OnStunAddrsAvailable", OTHER);
     107             : 
     108           0 :             PickleIterator iter__(msg__);
     109           0 :             NrIceStunAddrArray iceStunAddrs;
     110             : 
     111           0 :             if ((!(Read((&(iceStunAddrs)), (&(msg__)), (&(iter__)))))) {
     112           0 :                 FatalError("Error deserializing 'NrIceStunAddrArray'");
     113           0 :                 return MsgValueError;
     114             :             }
     115             :             // Sentinel = 'iceStunAddrs'
     116           0 :             if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2257180203)))) {
     117           0 :                 mozilla::ipc::SentinelReadError("Error deserializing 'NrIceStunAddrArray'");
     118           0 :                 return MsgValueError;
     119             :             }
     120           0 :             (msg__).EndRead(iter__, (msg__).type());
     121           0 :             PStunAddrsRequest::Transition(PStunAddrsRequest::Msg_OnStunAddrsAvailable__ID, (&(mState)));
     122           0 :             if ((!(RecvOnStunAddrsAvailable(mozilla::Move(iceStunAddrs))))) {
     123           0 :                 mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
     124             :                 // Error handled in mozilla::ipc::IPCResult
     125           0 :                 return MsgProcessingError;
     126             :             }
     127             : 
     128           0 :             return MsgProcessed;
     129             :         }
     130             :     default:
     131             :         {
     132           0 :             return MsgNotKnown;
     133             :         }
     134             :     }
     135             : }
     136             : 
     137           0 : auto PStunAddrsRequestChild::OnMessageReceived(
     138             :         const Message& msg__,
     139             :         Message*& reply__) -> PStunAddrsRequestChild::Result
     140             : {
     141           0 :     return MsgNotKnown;
     142             : }
     143             : 
     144           0 : auto PStunAddrsRequestChild::OnCallReceived(
     145             :         const Message& msg__,
     146             :         Message*& reply__) -> PStunAddrsRequestChild::Result
     147             : {
     148           0 :     MOZ_ASSERT_UNREACHABLE("message protocol not supported");
     149             :     return MsgNotKnown;
     150             : }
     151             : 
     152           0 : auto PStunAddrsRequestChild::GetProtocolTypeId() -> int32_t
     153             : {
     154           0 :     return PStunAddrsRequestMsgStart;
     155             : }
     156             : 
     157           0 : auto PStunAddrsRequestChild::ProtocolName() const -> const char*
     158             : {
     159           0 :     return "PStunAddrsRequestChild";
     160             : }
     161             : 
     162           0 : auto PStunAddrsRequestChild::DestroySubtree(ActorDestroyReason why) -> void
     163             : {
     164             :     // Unregister from our manager.
     165           0 :     Unregister(Id());
     166             : 
     167             :     // Reject owning pending promises.
     168           0 :     (GetIPCChannel())->RejectPendingPromisesForActor(this);
     169             : 
     170             :     // Finally, destroy "us".
     171           0 :     ActorDestroy(why);
     172           0 : }
     173             : 
     174           0 : auto PStunAddrsRequestChild::DeallocSubtree() -> void
     175             : {
     176           0 : }
     177             : 
     178           0 : auto PStunAddrsRequestChild::Write(
     179             :         const PStunAddrsRequestChild* v__,
     180             :         Message* msg__,
     181             :         bool nullable__) -> void
     182             : {
     183             :     int32_t id;
     184           0 :     if ((!(v__))) {
     185           0 :         if ((!(nullable__))) {
     186           0 :             FatalError("NULL actor value passed to non-nullable param");
     187             :         }
     188           0 :         id = 0;
     189             :     }
     190             :     else {
     191           0 :         id = (v__)->Id();
     192           0 :         if ((1) == (id)) {
     193           0 :             FatalError("actor has been |delete|d");
     194             :         }
     195             :     }
     196             : 
     197           0 :     Write(id, msg__);
     198           0 : }
     199             : 
     200           0 : auto PStunAddrsRequestChild::Read(
     201             :         PStunAddrsRequestChild** v__,
     202             :         const Message* msg__,
     203             :         PickleIterator* iter__,
     204             :         bool nullable__) -> bool
     205             : {
     206           0 :     Maybe<mozilla::ipc::IProtocol*> actor = ReadActor(msg__, iter__, nullable__, "PStunAddrsRequest", PStunAddrsRequestMsgStart);
     207           0 :     if ((actor).isNothing()) {
     208           0 :         return false;
     209             :     }
     210             : 
     211           0 :     (*(v__)) = static_cast<PStunAddrsRequestChild*>((actor).value());
     212           0 :     return true;
     213             : }
     214             : 
     215             : 
     216             : 
     217             : } // namespace net
     218             : } // namespace mozilla

Generated by: LCOV version 1.13