LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/ipc/ipdl - PPrintSettingsDialog.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 0 99 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/embedding/PPrintSettingsDialog.h"
       8             : 
       9             : namespace mozilla {
      10             : namespace embedding {
      11             : namespace PPrintSettingsDialog {
      12             : 
      13             : nsresult
      14           0 : CreateEndpoints(
      15             :         base::ProcessId aParentDestPid,
      16             :         base::ProcessId aChildDestPid,
      17             :         mozilla::ipc::Endpoint<mozilla::embedding::PPrintSettingsDialogParent>* aParent,
      18             :         mozilla::ipc::Endpoint<mozilla::embedding::PPrintSettingsDialogChild>* aChild)
      19             : {
      20           0 :     return mozilla::ipc::CreateEndpoints(mozilla::ipc::PrivateIPDLInterface(), aParentDestPid, aChildDestPid, PPrintSettingsDialogMsgStart, PPrintSettingsDialogMsgStartChild, 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___delete__(int32_t routingId)
      43             : {
      44           0 :     return new IPC::Message(routingId, Msg___delete____ID, 0, IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, "PPrintSettingsDialog::Msg___delete__", true);
      45             : }
      46             : IPC::Message*
      47           0 : Reply___delete__(int32_t routingId)
      48             : {
      49           0 :     return new IPC::Message(routingId, Reply___delete____ID, 0, IPC::Message::NOT_NESTED, IPC::Message::NORMAL_PRIORITY, IPC::Message::COMPRESSION_NONE, "PPrintSettingsDialog::Reply___delete__", true);
      50             : }
      51             : 
      52             : } // namespace PPrintSettingsDialog
      53             : } // namespace embedding
      54             : } // namespace mozilla
      55             : 
      56             : //-----------------------------------------------------------------------------
      57             : // Method definitions for the IPDL type |union PrintDataOrNSResult|
      58             : //
      59             : namespace mozilla {
      60             : namespace embedding {
      61           0 : auto PrintDataOrNSResult::MaybeDestroy(Type aNewType) -> bool
      62             : {
      63           0 :     if ((mType) == (T__None)) {
      64           0 :         return true;
      65             :     }
      66           0 :     if ((mType) == (aNewType)) {
      67           0 :         return false;
      68             :     }
      69           0 :     switch (mType) {
      70             :     case TPrintData:
      71             :         {
      72           0 :             (ptr_PrintData())->~PrintData__tdef();
      73           0 :             break;
      74             :         }
      75             :     case Tnsresult:
      76             :         {
      77           0 :             (ptr_nsresult())->~nsresult__tdef();
      78           0 :             break;
      79             :         }
      80             :     default:
      81             :         {
      82           0 :             mozilla::ipc::LogicError("not reached");
      83           0 :             break;
      84             :         }
      85             :     }
      86           0 :     return true;
      87             : }
      88             : 
      89           0 : MOZ_IMPLICIT PrintDataOrNSResult::PrintDataOrNSResult(const PrintData& aOther)
      90             : {
      91           0 :     new (mozilla::KnownNotNull, ptr_PrintData()) PrintData(aOther);
      92           0 :     mType = TPrintData;
      93           0 : }
      94             : 
      95           0 : MOZ_IMPLICIT PrintDataOrNSResult::PrintDataOrNSResult(const nsresult& aOther)
      96             : {
      97           0 :     new (mozilla::KnownNotNull, ptr_nsresult()) nsresult(aOther);
      98           0 :     mType = Tnsresult;
      99           0 : }
     100             : 
     101           0 : MOZ_IMPLICIT PrintDataOrNSResult::PrintDataOrNSResult(const PrintDataOrNSResult& aOther)
     102             : {
     103           0 :     (aOther).AssertSanity();
     104           0 :     switch ((aOther).type()) {
     105             :     case TPrintData:
     106             :         {
     107           0 :             new (mozilla::KnownNotNull, ptr_PrintData()) PrintData((aOther).get_PrintData());
     108           0 :             break;
     109             :         }
     110             :     case Tnsresult:
     111             :         {
     112           0 :             new (mozilla::KnownNotNull, ptr_nsresult()) nsresult((aOther).get_nsresult());
     113           0 :             break;
     114             :         }
     115             :     case T__None:
     116             :         {
     117           0 :             break;
     118             :         }
     119             :     default:
     120             :         {
     121           0 :             mozilla::ipc::LogicError("unreached");
     122           0 :             return;
     123             :         }
     124             :     }
     125           0 :     mType = (aOther).type();
     126             : }
     127             : 
     128           0 : PrintDataOrNSResult::~PrintDataOrNSResult()
     129             : {
     130           0 :     static_cast<void>(MaybeDestroy(T__None));
     131           0 : }
     132             : 
     133           0 : auto PrintDataOrNSResult::operator=(const PrintData& aRhs) -> PrintDataOrNSResult&
     134             : {
     135           0 :     if (MaybeDestroy(TPrintData)) {
     136           0 :         new (mozilla::KnownNotNull, ptr_PrintData()) PrintData;
     137             :     }
     138           0 :     (*(ptr_PrintData())) = aRhs;
     139           0 :     mType = TPrintData;
     140           0 :     return (*(this));
     141             : }
     142             : 
     143           0 : auto PrintDataOrNSResult::operator=(const nsresult& aRhs) -> PrintDataOrNSResult&
     144             : {
     145           0 :     if (MaybeDestroy(Tnsresult)) {
     146           0 :         new (mozilla::KnownNotNull, ptr_nsresult()) nsresult;
     147             :     }
     148           0 :     (*(ptr_nsresult())) = aRhs;
     149           0 :     mType = Tnsresult;
     150           0 :     return (*(this));
     151             : }
     152             : 
     153           0 : auto PrintDataOrNSResult::operator=(const PrintDataOrNSResult& aRhs) -> PrintDataOrNSResult&
     154             : {
     155           0 :     (aRhs).AssertSanity();
     156           0 :     Type t = (aRhs).type();
     157           0 :     switch (t) {
     158             :     case TPrintData:
     159             :         {
     160           0 :             if (MaybeDestroy(t)) {
     161           0 :                 new (mozilla::KnownNotNull, ptr_PrintData()) PrintData;
     162             :             }
     163           0 :             (*(ptr_PrintData())) = (aRhs).get_PrintData();
     164           0 :             break;
     165             :         }
     166             :     case Tnsresult:
     167             :         {
     168           0 :             if (MaybeDestroy(t)) {
     169           0 :                 new (mozilla::KnownNotNull, ptr_nsresult()) nsresult;
     170             :             }
     171           0 :             (*(ptr_nsresult())) = (aRhs).get_nsresult();
     172           0 :             break;
     173             :         }
     174             :     case T__None:
     175             :         {
     176           0 :             static_cast<void>(MaybeDestroy(t));
     177           0 :             break;
     178             :         }
     179             :     default:
     180             :         {
     181           0 :             mozilla::ipc::LogicError("unreached");
     182           0 :             break;
     183             :         }
     184             :     }
     185           0 :     mType = t;
     186           0 :     return (*(this));
     187             : }
     188             : 
     189           0 : auto PrintDataOrNSResult::operator==(const PrintData& aRhs) const -> bool
     190             : {
     191           0 :     return (get_PrintData()) == (aRhs);
     192             : }
     193             : 
     194           0 : auto PrintDataOrNSResult::operator==(const nsresult& aRhs) const -> bool
     195             : {
     196           0 :     return (get_nsresult()) == (aRhs);
     197             : }
     198             : 
     199           0 : auto PrintDataOrNSResult::operator==(const PrintDataOrNSResult& aRhs) const -> bool
     200             : {
     201           0 :     if ((type()) != ((aRhs).type())) {
     202           0 :         return false;
     203             :     }
     204             : 
     205           0 :     switch (type()) {
     206             :     case TPrintData:
     207             :         {
     208           0 :             return (get_PrintData()) == ((aRhs).get_PrintData());
     209             :         }
     210             :     case Tnsresult:
     211             :         {
     212           0 :             return (get_nsresult()) == ((aRhs).get_nsresult());
     213             :         }
     214             :     default:
     215             :         {
     216           0 :             mozilla::ipc::LogicError("unreached");
     217           0 :             return false;
     218             :         }
     219             :     }
     220             : }
     221             : 
     222           0 : auto PrintDataOrNSResult::get(PrintData* aOutValue) const -> void
     223             : {
     224           0 :     (*(aOutValue)) = get_PrintData();
     225           0 : }
     226             : 
     227           0 : auto PrintDataOrNSResult::get(nsresult* aOutValue) const -> void
     228             : {
     229           0 :     (*(aOutValue)) = get_nsresult();
     230           0 : }
     231             : 
     232             : } // namespace embedding
     233             : } // namespace mozilla

Generated by: LCOV version 1.13