LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/ipc/ipdl - PHeapSnapshotTempFileHelper.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 0 126 0.0 %
Date: 2017-07-14 16:53:18 Functions: 0 25 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/devtools/PHeapSnapshotTempFileHelper.h"
       8             : 
       9             : namespace mozilla {
      10             : namespace devtools {
      11             : namespace PHeapSnapshotTempFileHelper {
      12             : 
      13             : nsresult
      14           0 : CreateEndpoints(
      15             :         base::ProcessId aParentDestPid,
      16             :         base::ProcessId aChildDestPid,
      17             :         mozilla::ipc::Endpoint<mozilla::devtools::PHeapSnapshotTempFileHelperParent>* aParent,
      18             :         mozilla::ipc::Endpoint<mozilla::devtools::PHeapSnapshotTempFileHelperChild>* aChild)
      19             : {
      20           0 :     return mozilla::ipc::CreateEndpoints(mozilla::ipc::PrivateIPDLInterface(), aParentDestPid, aChildDestPid, PHeapSnapshotTempFileHelperMsgStart, PHeapSnapshotTempFileHelperMsgStartChild, aParent, aChild);
      21             : }
      22             : void
      23           0 : Transition(
      24             :         MessageType msg,
      25             :         State* next)
      26             : {
      27           0 :     switch ((*(next))) {
      28             :     case __Null:
      29           0 :         if ((Msg___delete____ID) == (msg)) {
      30           0 :             (*(next)) = __Dead;
      31             :         }
      32           0 :         break;
      33             :     case __Dead:
      34           0 :         mozilla::ipc::LogicError("__delete__()d actor");
      35           0 :         break;
      36             :     default:
      37           0 :         mozilla::ipc::LogicError("corrupted actor state");
      38           0 :         break;
      39             :     }
      40           0 : }
      41             : IPC::Message*
      42           0 : Msg_OpenHeapSnapshotTempFile(int32_t routingId)
      43             : {
      44           0 :     return new IPC::Message(routingId, Msg_OpenHeapSnapshotTempFile__ID, 0, IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, "PHeapSnapshotTempFileHelper::Msg_OpenHeapSnapshotTempFile", true);
      45             : }
      46             : IPC::Message*
      47           0 : Reply_OpenHeapSnapshotTempFile(int32_t routingId)
      48             : {
      49           0 :     return new IPC::Message(routingId, Reply_OpenHeapSnapshotTempFile__ID, 0, IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, "PHeapSnapshotTempFileHelper::Reply_OpenHeapSnapshotTempFile", true);
      50             : }
      51             : IPC::Message*
      52           0 : Msg___delete__(int32_t routingId)
      53             : {
      54           0 :     return new IPC::Message(routingId, Msg___delete____ID, 0, IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, "PHeapSnapshotTempFileHelper::Msg___delete__", true);
      55             : }
      56             : IPC::Message*
      57           0 : Reply___delete__(int32_t routingId)
      58             : {
      59           0 :     return new IPC::Message(routingId, Reply___delete____ID, 0, IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, "PHeapSnapshotTempFileHelper::Reply___delete__", true);
      60             : }
      61             : 
      62             : } // namespace PHeapSnapshotTempFileHelper
      63             : } // namespace devtools
      64             : } // namespace mozilla
      65             : 
      66             : //-----------------------------------------------------------------------------
      67             : // Method definitions for the IPDL type |struct OpenedFile|
      68             : //
      69             : namespace mozilla {
      70             : namespace devtools {
      71           0 : MOZ_IMPLICIT OpenedFile::OpenedFile() :
      72             :     path_(),
      73           0 :     snapshotId_()
      74             : {
      75           0 :     Init();
      76           0 : }
      77             : 
      78           0 : OpenedFile::~OpenedFile()
      79             : {
      80           0 : }
      81             : 
      82           0 : auto OpenedFile::operator==(const OpenedFile& _o) const -> bool
      83             : {
      84           0 :     if ((!((path()) == ((_o).path())))) {
      85           0 :         return false;
      86             :     }
      87           0 :     if ((!((snapshotId()) == ((_o).snapshotId())))) {
      88           0 :         return false;
      89             :     }
      90           0 :     if ((!((descriptor()) == ((_o).descriptor())))) {
      91           0 :         return false;
      92             :     }
      93           0 :     return true;
      94             : }
      95             : 
      96           0 : auto OpenedFile::operator!=(const OpenedFile& _o) const -> bool
      97             : {
      98           0 :     return (!(operator==(_o)));
      99             : }
     100             : 
     101           0 : auto OpenedFile::Init() -> void
     102             : {
     103           0 : }
     104             : 
     105           0 : auto OpenedFile::Assign(
     106             :         const nsString& _path,
     107             :         const nsString& _snapshotId,
     108             :         const FileDescriptor& _descriptor) -> void
     109             : {
     110           0 :     path_ = _path;
     111           0 :     snapshotId_ = _snapshotId;
     112           0 :     descriptor_ = _descriptor;
     113           0 : }
     114             : 
     115             : } // namespace devtools
     116             : } // namespace mozilla
     117             : 
     118             : //-----------------------------------------------------------------------------
     119             : // Method definitions for the IPDL type |union OpenHeapSnapshotTempFileResponse|
     120             : //
     121             : namespace mozilla {
     122             : namespace devtools {
     123           0 : auto OpenHeapSnapshotTempFileResponse::MaybeDestroy(Type aNewType) -> bool
     124             : {
     125           0 :     if ((mType) == (T__None)) {
     126           0 :         return true;
     127             :     }
     128           0 :     if ((mType) == (aNewType)) {
     129           0 :         return false;
     130             :     }
     131           0 :     switch (mType) {
     132             :     case Tnsresult:
     133             :         {
     134           0 :             (ptr_nsresult())->~nsresult__tdef();
     135           0 :             break;
     136             :         }
     137             :     case TOpenedFile:
     138             :         {
     139           0 :             (ptr_OpenedFile())->~OpenedFile__tdef();
     140           0 :             break;
     141             :         }
     142             :     default:
     143             :         {
     144           0 :             mozilla::ipc::LogicError("not reached");
     145           0 :             break;
     146             :         }
     147             :     }
     148           0 :     return true;
     149             : }
     150             : 
     151           0 : MOZ_IMPLICIT OpenHeapSnapshotTempFileResponse::OpenHeapSnapshotTempFileResponse(const nsresult& aOther)
     152             : {
     153           0 :     new (mozilla::KnownNotNull, ptr_nsresult()) nsresult(aOther);
     154           0 :     mType = Tnsresult;
     155           0 : }
     156             : 
     157           0 : MOZ_IMPLICIT OpenHeapSnapshotTempFileResponse::OpenHeapSnapshotTempFileResponse(const OpenedFile& aOther)
     158             : {
     159           0 :     new (mozilla::KnownNotNull, ptr_OpenedFile()) OpenedFile(aOther);
     160           0 :     mType = TOpenedFile;
     161           0 : }
     162             : 
     163           0 : MOZ_IMPLICIT OpenHeapSnapshotTempFileResponse::OpenHeapSnapshotTempFileResponse(const OpenHeapSnapshotTempFileResponse& aOther)
     164             : {
     165           0 :     (aOther).AssertSanity();
     166           0 :     switch ((aOther).type()) {
     167             :     case Tnsresult:
     168             :         {
     169           0 :             new (mozilla::KnownNotNull, ptr_nsresult()) nsresult((aOther).get_nsresult());
     170           0 :             break;
     171             :         }
     172             :     case TOpenedFile:
     173             :         {
     174           0 :             new (mozilla::KnownNotNull, ptr_OpenedFile()) OpenedFile((aOther).get_OpenedFile());
     175           0 :             break;
     176             :         }
     177             :     case T__None:
     178             :         {
     179           0 :             break;
     180             :         }
     181             :     default:
     182             :         {
     183           0 :             mozilla::ipc::LogicError("unreached");
     184           0 :             return;
     185             :         }
     186             :     }
     187           0 :     mType = (aOther).type();
     188             : }
     189             : 
     190           0 : OpenHeapSnapshotTempFileResponse::~OpenHeapSnapshotTempFileResponse()
     191             : {
     192           0 :     static_cast<void>(MaybeDestroy(T__None));
     193           0 : }
     194             : 
     195           0 : auto OpenHeapSnapshotTempFileResponse::operator=(const nsresult& aRhs) -> OpenHeapSnapshotTempFileResponse&
     196             : {
     197           0 :     if (MaybeDestroy(Tnsresult)) {
     198           0 :         new (mozilla::KnownNotNull, ptr_nsresult()) nsresult;
     199             :     }
     200           0 :     (*(ptr_nsresult())) = aRhs;
     201           0 :     mType = Tnsresult;
     202           0 :     return (*(this));
     203             : }
     204             : 
     205           0 : auto OpenHeapSnapshotTempFileResponse::operator=(const OpenedFile& aRhs) -> OpenHeapSnapshotTempFileResponse&
     206             : {
     207           0 :     if (MaybeDestroy(TOpenedFile)) {
     208           0 :         new (mozilla::KnownNotNull, ptr_OpenedFile()) OpenedFile;
     209             :     }
     210           0 :     (*(ptr_OpenedFile())) = aRhs;
     211           0 :     mType = TOpenedFile;
     212           0 :     return (*(this));
     213             : }
     214             : 
     215           0 : auto OpenHeapSnapshotTempFileResponse::operator=(const OpenHeapSnapshotTempFileResponse& aRhs) -> OpenHeapSnapshotTempFileResponse&
     216             : {
     217           0 :     (aRhs).AssertSanity();
     218           0 :     Type t = (aRhs).type();
     219           0 :     switch (t) {
     220             :     case Tnsresult:
     221             :         {
     222           0 :             if (MaybeDestroy(t)) {
     223           0 :                 new (mozilla::KnownNotNull, ptr_nsresult()) nsresult;
     224             :             }
     225           0 :             (*(ptr_nsresult())) = (aRhs).get_nsresult();
     226           0 :             break;
     227             :         }
     228             :     case TOpenedFile:
     229             :         {
     230           0 :             if (MaybeDestroy(t)) {
     231           0 :                 new (mozilla::KnownNotNull, ptr_OpenedFile()) OpenedFile;
     232             :             }
     233           0 :             (*(ptr_OpenedFile())) = (aRhs).get_OpenedFile();
     234           0 :             break;
     235             :         }
     236             :     case T__None:
     237             :         {
     238           0 :             static_cast<void>(MaybeDestroy(t));
     239           0 :             break;
     240             :         }
     241             :     default:
     242             :         {
     243           0 :             mozilla::ipc::LogicError("unreached");
     244           0 :             break;
     245             :         }
     246             :     }
     247           0 :     mType = t;
     248           0 :     return (*(this));
     249             : }
     250             : 
     251           0 : auto OpenHeapSnapshotTempFileResponse::operator==(const nsresult& aRhs) const -> bool
     252             : {
     253           0 :     return (get_nsresult()) == (aRhs);
     254             : }
     255             : 
     256           0 : auto OpenHeapSnapshotTempFileResponse::operator==(const OpenedFile& aRhs) const -> bool
     257             : {
     258           0 :     return (get_OpenedFile()) == (aRhs);
     259             : }
     260             : 
     261           0 : auto OpenHeapSnapshotTempFileResponse::operator==(const OpenHeapSnapshotTempFileResponse& aRhs) const -> bool
     262             : {
     263           0 :     if ((type()) != ((aRhs).type())) {
     264           0 :         return false;
     265             :     }
     266             : 
     267           0 :     switch (type()) {
     268             :     case Tnsresult:
     269             :         {
     270           0 :             return (get_nsresult()) == ((aRhs).get_nsresult());
     271             :         }
     272             :     case TOpenedFile:
     273             :         {
     274           0 :             return (get_OpenedFile()) == ((aRhs).get_OpenedFile());
     275             :         }
     276             :     default:
     277             :         {
     278           0 :             mozilla::ipc::LogicError("unreached");
     279           0 :             return false;
     280             :         }
     281             :     }
     282             : }
     283             : 
     284           0 : auto OpenHeapSnapshotTempFileResponse::get(nsresult* aOutValue) const -> void
     285             : {
     286           0 :     (*(aOutValue)) = get_nsresult();
     287           0 : }
     288             : 
     289           0 : auto OpenHeapSnapshotTempFileResponse::get(OpenedFile* aOutValue) const -> void
     290             : {
     291           0 :     (*(aOutValue)) = get_OpenedFile();
     292           0 : }
     293             : 
     294             : } // namespace devtools
     295             : } // namespace mozilla

Generated by: LCOV version 1.13