LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/ipc/ipdl - PWebrtcGlobalParent.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 0 174 0.0 %
Date: 2017-07-14 16:53:18 Functions: 0 21 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/dom/PWebrtcGlobalParent.h"
       8             : #include "mozilla/dom/RTCStatsReportBinding.h"
       9             : 
      10             : #include "mozilla/dom/PContentParent.h"
      11             : 
      12             : #include "nsIFile.h"
      13             : #include "GeckoProfiler.h"
      14             : 
      15             : namespace mozilla {
      16             : namespace dom {
      17             : 
      18             : 
      19           0 : auto PWebrtcGlobalParent::Recv__delete__() -> mozilla::ipc::IPCResult
      20             : {
      21           0 :     return IPC_OK();
      22             : }
      23             : 
      24             : 
      25           0 : MOZ_IMPLICIT PWebrtcGlobalParent::PWebrtcGlobalParent() :
      26             :     mozilla::ipc::IProtocol(mozilla::ipc::ParentSide),
      27           0 :     mState(PWebrtcGlobal::__Dead)
      28             : {
      29           0 :     MOZ_COUNT_CTOR(PWebrtcGlobalParent);
      30           0 : }
      31             : 
      32           0 : PWebrtcGlobalParent::~PWebrtcGlobalParent()
      33             : {
      34           0 :     MOZ_COUNT_DTOR(PWebrtcGlobalParent);
      35           0 : }
      36             : 
      37           0 : auto PWebrtcGlobalParent::Manager() const -> PContentParent*
      38             : {
      39           0 :     return static_cast<PContentParent*>(IProtocol::Manager());
      40             : }
      41             : 
      42           0 : auto PWebrtcGlobalParent::SendGetStatsRequest(
      43             :         const int& aRequestId,
      44             :         const nsString& aPcIdFilter) -> bool
      45             : {
      46           0 :     IPC::Message* msg__ = PWebrtcGlobal::Msg_GetStatsRequest(Id());
      47             : 
      48           0 :     Write(aRequestId, msg__);
      49             :     // Sentinel = 'aRequestId'
      50           0 :     (msg__)->WriteSentinel(3709302657);
      51           0 :     Write(aPcIdFilter, msg__);
      52             :     // Sentinel = 'aPcIdFilter'
      53           0 :     (msg__)->WriteSentinel(1293029124);
      54             : 
      55             : 
      56             : 
      57             : 
      58           0 :     if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
      59           0 :         mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
      60             :     }
      61           0 :     AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_GetStatsRequest", OTHER);
      62           0 :     PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_GetStatsRequest__ID, (&(mState)));
      63             : 
      64           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
      65           0 :     return sendok__;
      66             : }
      67             : 
      68           0 : auto PWebrtcGlobalParent::SendClearStatsRequest() -> bool
      69             : {
      70           0 :     IPC::Message* msg__ = PWebrtcGlobal::Msg_ClearStatsRequest(Id());
      71             : 
      72             : 
      73             : 
      74             : 
      75             : 
      76           0 :     if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
      77           0 :         mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
      78             :     }
      79           0 :     AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_ClearStatsRequest", OTHER);
      80           0 :     PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_ClearStatsRequest__ID, (&(mState)));
      81             : 
      82           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
      83           0 :     return sendok__;
      84             : }
      85             : 
      86           0 : auto PWebrtcGlobalParent::SendGetLogRequest(
      87             :         const int& aRequestId,
      88             :         const nsCString& aPattern) -> bool
      89             : {
      90           0 :     IPC::Message* msg__ = PWebrtcGlobal::Msg_GetLogRequest(Id());
      91             : 
      92           0 :     Write(aRequestId, msg__);
      93             :     // Sentinel = 'aRequestId'
      94           0 :     (msg__)->WriteSentinel(3709302657);
      95           0 :     Write(aPattern, msg__);
      96             :     // Sentinel = 'aPattern'
      97           0 :     (msg__)->WriteSentinel(3502183121);
      98             : 
      99             : 
     100             : 
     101             : 
     102           0 :     if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     103           0 :         mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
     104             :     }
     105           0 :     AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_GetLogRequest", OTHER);
     106           0 :     PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_GetLogRequest__ID, (&(mState)));
     107             : 
     108           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
     109           0 :     return sendok__;
     110             : }
     111             : 
     112           0 : auto PWebrtcGlobalParent::SendClearLogRequest() -> bool
     113             : {
     114           0 :     IPC::Message* msg__ = PWebrtcGlobal::Msg_ClearLogRequest(Id());
     115             : 
     116             : 
     117             : 
     118             : 
     119             : 
     120           0 :     if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     121           0 :         mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
     122             :     }
     123           0 :     AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_ClearLogRequest", OTHER);
     124           0 :     PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_ClearLogRequest__ID, (&(mState)));
     125             : 
     126           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
     127           0 :     return sendok__;
     128             : }
     129             : 
     130           0 : auto PWebrtcGlobalParent::SendSetAecLogging(const bool& aEnable) -> bool
     131             : {
     132           0 :     IPC::Message* msg__ = PWebrtcGlobal::Msg_SetAecLogging(Id());
     133             : 
     134           0 :     Write(aEnable, msg__);
     135             :     // Sentinel = 'aEnable'
     136           0 :     (msg__)->WriteSentinel(163837555);
     137             : 
     138             : 
     139             : 
     140             : 
     141           0 :     if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     142           0 :         mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
     143             :     }
     144           0 :     AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_SetAecLogging", OTHER);
     145           0 :     PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_SetAecLogging__ID, (&(mState)));
     146             : 
     147           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
     148           0 :     return sendok__;
     149             : }
     150             : 
     151           0 : auto PWebrtcGlobalParent::SendSetDebugMode(const int& aLevel) -> bool
     152             : {
     153           0 :     IPC::Message* msg__ = PWebrtcGlobal::Msg_SetDebugMode(Id());
     154             : 
     155           0 :     Write(aLevel, msg__);
     156             :     // Sentinel = 'aLevel'
     157           0 :     (msg__)->WriteSentinel(1717579975);
     158             : 
     159             : 
     160             : 
     161             : 
     162           0 :     if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     163           0 :         mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Sending ", (msg__)->type(), mozilla::ipc::MessageDirection::eSending);
     164             :     }
     165           0 :     AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_SetDebugMode", OTHER);
     166           0 :     PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_SetDebugMode__ID, (&(mState)));
     167             : 
     168           0 :     bool sendok__ = (GetIPCChannel())->Send(msg__);
     169           0 :     return sendok__;
     170             : }
     171             : 
     172           0 : auto PWebrtcGlobalParent::RemoveManagee(
     173             :         int32_t aProtocolId,
     174             :         ProtocolBase* aListener) -> void
     175             : {
     176           0 :     FatalError("unreached");
     177           0 :     return;
     178             : }
     179             : 
     180           0 : auto PWebrtcGlobalParent::OnMessageReceived(const Message& msg__) -> PWebrtcGlobalParent::Result
     181             : {
     182           0 :     switch ((msg__).type()) {
     183             :     case PWebrtcGlobal::Msg_GetStatsResult__ID:
     184             :         {
     185           0 :             if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     186           0 :                 mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
     187             :             }
     188           0 :             AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_GetStatsResult", OTHER);
     189             : 
     190           0 :             PickleIterator iter__(msg__);
     191             :             int aRequestId;
     192           0 :             nsTArray<RTCStatsReportInternal> aStats;
     193             : 
     194           0 :             if ((!(Read((&(aRequestId)), (&(msg__)), (&(iter__)))))) {
     195           0 :                 FatalError("Error deserializing 'int'");
     196           0 :                 return MsgValueError;
     197             :             }
     198             :             // Sentinel = 'aRequestId'
     199           0 :             if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3709302657)))) {
     200           0 :                 mozilla::ipc::SentinelReadError("Error deserializing 'int'");
     201           0 :                 return MsgValueError;
     202             :             }
     203           0 :             if ((!(Read((&(aStats)), (&(msg__)), (&(iter__)))))) {
     204           0 :                 FatalError("Error deserializing 'nsTArray'");
     205           0 :                 return MsgValueError;
     206             :             }
     207             :             // Sentinel = 'aStats'
     208           0 :             if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3694751948)))) {
     209           0 :                 mozilla::ipc::SentinelReadError("Error deserializing 'nsTArray'");
     210           0 :                 return MsgValueError;
     211             :             }
     212           0 :             (msg__).EndRead(iter__, (msg__).type());
     213           0 :             PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_GetStatsResult__ID, (&(mState)));
     214           0 :             if ((!(RecvGetStatsResult(mozilla::Move(aRequestId), mozilla::Move(aStats))))) {
     215           0 :                 mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
     216             :                 // Error handled in mozilla::ipc::IPCResult
     217           0 :                 return MsgProcessingError;
     218             :             }
     219             : 
     220           0 :             return MsgProcessed;
     221             :         }
     222             :     case PWebrtcGlobal::Msg_GetLogResult__ID:
     223             :         {
     224           0 :             if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     225           0 :                 mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
     226             :             }
     227           0 :             AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg_GetLogResult", OTHER);
     228             : 
     229           0 :             PickleIterator iter__(msg__);
     230             :             int aRequestId;
     231           0 :             WebrtcGlobalLog aLog;
     232             : 
     233           0 :             if ((!(Read((&(aRequestId)), (&(msg__)), (&(iter__)))))) {
     234           0 :                 FatalError("Error deserializing 'int'");
     235           0 :                 return MsgValueError;
     236             :             }
     237             :             // Sentinel = 'aRequestId'
     238           0 :             if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 3709302657)))) {
     239           0 :                 mozilla::ipc::SentinelReadError("Error deserializing 'int'");
     240           0 :                 return MsgValueError;
     241             :             }
     242           0 :             if ((!(Read((&(aLog)), (&(msg__)), (&(iter__)))))) {
     243           0 :                 FatalError("Error deserializing 'WebrtcGlobalLog'");
     244           0 :                 return MsgValueError;
     245             :             }
     246             :             // Sentinel = 'aLog'
     247           0 :             if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 2709198341)))) {
     248           0 :                 mozilla::ipc::SentinelReadError("Error deserializing 'WebrtcGlobalLog'");
     249           0 :                 return MsgValueError;
     250             :             }
     251           0 :             (msg__).EndRead(iter__, (msg__).type());
     252           0 :             PWebrtcGlobal::Transition(PWebrtcGlobal::Msg_GetLogResult__ID, (&(mState)));
     253           0 :             if ((!(RecvGetLogResult(mozilla::Move(aRequestId), mozilla::Move(aLog))))) {
     254           0 :                 mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
     255             :                 // Error handled in mozilla::ipc::IPCResult
     256           0 :                 return MsgProcessingError;
     257             :             }
     258             : 
     259           0 :             return MsgProcessed;
     260             :         }
     261             :     case PWebrtcGlobal::Msg___delete____ID:
     262             :         {
     263           0 :             if (mozilla::ipc::LoggingEnabledFor("PWebrtcGlobalParent")) {
     264           0 :                 mozilla::ipc::LogMessageForProtocol("PWebrtcGlobalParent", OtherPid(), "Received ", ((&(msg__)))->type(), mozilla::ipc::MessageDirection::eReceiving);
     265             :             }
     266           0 :             AUTO_PROFILER_LABEL("PWebrtcGlobal::Msg___delete__", OTHER);
     267             : 
     268           0 :             PickleIterator iter__(msg__);
     269             :             PWebrtcGlobalParent* actor;
     270             : 
     271           0 :             if ((!(Read((&(actor)), (&(msg__)), (&(iter__)), false)))) {
     272           0 :                 FatalError("Error deserializing 'PWebrtcGlobalParent'");
     273           0 :                 return MsgValueError;
     274             :             }
     275             :             // Sentinel = 'actor'
     276           0 :             if ((!(((&(msg__)))->ReadSentinel((&(iter__)), 875202478)))) {
     277           0 :                 mozilla::ipc::SentinelReadError("Error deserializing 'PWebrtcGlobalParent'");
     278           0 :                 return MsgValueError;
     279             :             }
     280           0 :             (msg__).EndRead(iter__, (msg__).type());
     281           0 :             PWebrtcGlobal::Transition(PWebrtcGlobal::Msg___delete____ID, (&(mState)));
     282           0 :             if ((!(Recv__delete__()))) {
     283           0 :                 mozilla::ipc::ProtocolErrorBreakpoint("Handler returned error code!");
     284             :                 // Error handled in mozilla::ipc::IPCResult
     285           0 :                 return MsgProcessingError;
     286             :             }
     287             : 
     288             : 
     289           0 :             IProtocol* mgr = (actor)->Manager();
     290           0 :             (actor)->DestroySubtree(Deletion);
     291           0 :             (actor)->DeallocSubtree();
     292           0 :             (mgr)->RemoveManagee(PWebrtcGlobalMsgStart, actor);
     293             : 
     294           0 :             return MsgProcessed;
     295             :         }
     296             :     default:
     297             :         {
     298           0 :             return MsgNotKnown;
     299             :         }
     300             :     }
     301             : }
     302             : 
     303           0 : auto PWebrtcGlobalParent::OnMessageReceived(
     304             :         const Message& msg__,
     305             :         Message*& reply__) -> PWebrtcGlobalParent::Result
     306             : {
     307           0 :     return MsgNotKnown;
     308             : }
     309             : 
     310           0 : auto PWebrtcGlobalParent::OnCallReceived(
     311             :         const Message& msg__,
     312             :         Message*& reply__) -> PWebrtcGlobalParent::Result
     313             : {
     314           0 :     MOZ_ASSERT_UNREACHABLE("message protocol not supported");
     315             :     return MsgNotKnown;
     316             : }
     317             : 
     318           0 : auto PWebrtcGlobalParent::GetProtocolTypeId() -> int32_t
     319             : {
     320           0 :     return PWebrtcGlobalMsgStart;
     321             : }
     322             : 
     323           0 : auto PWebrtcGlobalParent::ProtocolName() const -> const char*
     324             : {
     325           0 :     return "PWebrtcGlobalParent";
     326             : }
     327             : 
     328           0 : auto PWebrtcGlobalParent::DestroySubtree(ActorDestroyReason why) -> void
     329             : {
     330             :     // Unregister from our manager.
     331           0 :     Unregister(Id());
     332             : 
     333             :     // Reject owning pending promises.
     334           0 :     (GetIPCChannel())->RejectPendingPromisesForActor(this);
     335             : 
     336             :     // Finally, destroy "us".
     337           0 :     ActorDestroy(why);
     338           0 : }
     339             : 
     340           0 : auto PWebrtcGlobalParent::DeallocSubtree() -> void
     341             : {
     342           0 : }
     343             : 
     344           0 : auto PWebrtcGlobalParent::Write(
     345             :         const PWebrtcGlobalParent* v__,
     346             :         Message* msg__,
     347             :         bool nullable__) -> void
     348             : {
     349             :     int32_t id;
     350           0 :     if ((!(v__))) {
     351           0 :         if ((!(nullable__))) {
     352           0 :             FatalError("NULL actor value passed to non-nullable param");
     353             :         }
     354           0 :         id = 0;
     355             :     }
     356             :     else {
     357           0 :         id = (v__)->Id();
     358           0 :         if ((1) == (id)) {
     359           0 :             FatalError("actor has been |delete|d");
     360             :         }
     361             :     }
     362             : 
     363           0 :     Write(id, msg__);
     364           0 : }
     365             : 
     366           0 : auto PWebrtcGlobalParent::Read(
     367             :         PWebrtcGlobalParent** v__,
     368             :         const Message* msg__,
     369             :         PickleIterator* iter__,
     370             :         bool nullable__) -> bool
     371             : {
     372           0 :     Maybe<mozilla::ipc::IProtocol*> actor = ReadActor(msg__, iter__, nullable__, "PWebrtcGlobal", PWebrtcGlobalMsgStart);
     373           0 :     if ((actor).isNothing()) {
     374           0 :         return false;
     375             :     }
     376             : 
     377           0 :     (*(v__)) = static_cast<PWebrtcGlobalParent*>((actor).value());
     378           0 :     return true;
     379             : }
     380             : 
     381             : 
     382             : 
     383             : } // namespace dom
     384             : } // namespace mozilla

Generated by: LCOV version 1.13