LCOV - code coverage report
Current view: top level - obj-x86_64-pc-linux-gnu/ipc/ipdl - PURLClassifierInfo.cpp (source / functions) Hit Total Coverage
Test: output.info Lines: 0 106 0.0 %
Date: 2017-07-14 16:53:18 Functions: 0 19 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/PURLClassifierInfo.h"
       8             : 
       9             : 
      10             : //-----------------------------------------------------------------------------
      11             : // Method definitions for the IPDL type |struct ClassifierInfo|
      12             : //
      13             : namespace mozilla {
      14             : namespace dom {
      15           0 : MOZ_IMPLICIT ClassifierInfo::ClassifierInfo() :
      16             :     list_(),
      17             :     provider_(),
      18           0 :     prefix_()
      19             : {
      20           0 :     Init();
      21           0 : }
      22             : 
      23           0 : ClassifierInfo::~ClassifierInfo()
      24             : {
      25           0 : }
      26             : 
      27           0 : auto ClassifierInfo::operator==(const ClassifierInfo& _o) const -> bool
      28             : {
      29           0 :     if ((!((list()) == ((_o).list())))) {
      30           0 :         return false;
      31             :     }
      32           0 :     if ((!((provider()) == ((_o).provider())))) {
      33           0 :         return false;
      34             :     }
      35           0 :     if ((!((prefix()) == ((_o).prefix())))) {
      36           0 :         return false;
      37             :     }
      38           0 :     return true;
      39             : }
      40             : 
      41           0 : auto ClassifierInfo::operator!=(const ClassifierInfo& _o) const -> bool
      42             : {
      43           0 :     return (!(operator==(_o)));
      44             : }
      45             : 
      46           0 : auto ClassifierInfo::Init() -> void
      47             : {
      48           0 : }
      49             : 
      50           0 : auto ClassifierInfo::Assign(
      51             :         const nsCString& _list,
      52             :         const nsCString& _provider,
      53             :         const nsCString& _prefix) -> void
      54             : {
      55           0 :     list_ = _list;
      56           0 :     provider_ = _provider;
      57           0 :     prefix_ = _prefix;
      58           0 : }
      59             : 
      60             : } // namespace dom
      61             : } // namespace mozilla
      62             : 
      63             : //-----------------------------------------------------------------------------
      64             : // Method definitions for the IPDL type |union MaybeInfo|
      65             : //
      66             : namespace mozilla {
      67             : namespace dom {
      68           0 : auto MaybeInfo::MaybeDestroy(Type aNewType) -> bool
      69             : {
      70           0 :     if ((mType) == (T__None)) {
      71           0 :         return true;
      72             :     }
      73           0 :     if ((mType) == (aNewType)) {
      74           0 :         return false;
      75             :     }
      76           0 :     switch (mType) {
      77             :     case TClassifierInfo:
      78             :         {
      79           0 :             (ptr_ClassifierInfo())->~ClassifierInfo__tdef();
      80           0 :             break;
      81             :         }
      82             :     case Tvoid_t:
      83             :         {
      84           0 :             (ptr_void_t())->~void_t__tdef();
      85           0 :             break;
      86             :         }
      87             :     default:
      88             :         {
      89           0 :             mozilla::ipc::LogicError("not reached");
      90           0 :             break;
      91             :         }
      92             :     }
      93           0 :     return true;
      94             : }
      95             : 
      96           0 : MOZ_IMPLICIT MaybeInfo::MaybeInfo(const ClassifierInfo& aOther)
      97             : {
      98           0 :     new (mozilla::KnownNotNull, ptr_ClassifierInfo()) ClassifierInfo(aOther);
      99           0 :     mType = TClassifierInfo;
     100           0 : }
     101             : 
     102           0 : MOZ_IMPLICIT MaybeInfo::MaybeInfo(const void_t& aOther)
     103             : {
     104           0 :     new (mozilla::KnownNotNull, ptr_void_t()) void_t(aOther);
     105           0 :     mType = Tvoid_t;
     106           0 : }
     107             : 
     108           0 : MOZ_IMPLICIT MaybeInfo::MaybeInfo(const MaybeInfo& aOther)
     109             : {
     110           0 :     (aOther).AssertSanity();
     111           0 :     switch ((aOther).type()) {
     112             :     case TClassifierInfo:
     113             :         {
     114           0 :             new (mozilla::KnownNotNull, ptr_ClassifierInfo()) ClassifierInfo((aOther).get_ClassifierInfo());
     115           0 :             break;
     116             :         }
     117             :     case Tvoid_t:
     118             :         {
     119           0 :             new (mozilla::KnownNotNull, ptr_void_t()) void_t((aOther).get_void_t());
     120           0 :             break;
     121             :         }
     122             :     case T__None:
     123             :         {
     124           0 :             break;
     125             :         }
     126             :     default:
     127             :         {
     128           0 :             mozilla::ipc::LogicError("unreached");
     129           0 :             return;
     130             :         }
     131             :     }
     132           0 :     mType = (aOther).type();
     133             : }
     134             : 
     135           0 : MaybeInfo::~MaybeInfo()
     136             : {
     137           0 :     static_cast<void>(MaybeDestroy(T__None));
     138           0 : }
     139             : 
     140           0 : auto MaybeInfo::operator=(const ClassifierInfo& aRhs) -> MaybeInfo&
     141             : {
     142           0 :     if (MaybeDestroy(TClassifierInfo)) {
     143           0 :         new (mozilla::KnownNotNull, ptr_ClassifierInfo()) ClassifierInfo;
     144             :     }
     145           0 :     (*(ptr_ClassifierInfo())) = aRhs;
     146           0 :     mType = TClassifierInfo;
     147           0 :     return (*(this));
     148             : }
     149             : 
     150           0 : auto MaybeInfo::operator=(const void_t& aRhs) -> MaybeInfo&
     151             : {
     152           0 :     if (MaybeDestroy(Tvoid_t)) {
     153           0 :         new (mozilla::KnownNotNull, ptr_void_t()) void_t;
     154             :     }
     155           0 :     (*(ptr_void_t())) = aRhs;
     156           0 :     mType = Tvoid_t;
     157           0 :     return (*(this));
     158             : }
     159             : 
     160           0 : auto MaybeInfo::operator=(const MaybeInfo& aRhs) -> MaybeInfo&
     161             : {
     162           0 :     (aRhs).AssertSanity();
     163           0 :     Type t = (aRhs).type();
     164           0 :     switch (t) {
     165             :     case TClassifierInfo:
     166             :         {
     167           0 :             if (MaybeDestroy(t)) {
     168           0 :                 new (mozilla::KnownNotNull, ptr_ClassifierInfo()) ClassifierInfo;
     169             :             }
     170           0 :             (*(ptr_ClassifierInfo())) = (aRhs).get_ClassifierInfo();
     171           0 :             break;
     172             :         }
     173             :     case Tvoid_t:
     174             :         {
     175           0 :             if (MaybeDestroy(t)) {
     176           0 :                 new (mozilla::KnownNotNull, ptr_void_t()) void_t;
     177             :             }
     178           0 :             (*(ptr_void_t())) = (aRhs).get_void_t();
     179           0 :             break;
     180             :         }
     181             :     case T__None:
     182             :         {
     183           0 :             static_cast<void>(MaybeDestroy(t));
     184           0 :             break;
     185             :         }
     186             :     default:
     187             :         {
     188           0 :             mozilla::ipc::LogicError("unreached");
     189           0 :             break;
     190             :         }
     191             :     }
     192           0 :     mType = t;
     193           0 :     return (*(this));
     194             : }
     195             : 
     196           0 : auto MaybeInfo::operator==(const ClassifierInfo& aRhs) const -> bool
     197             : {
     198           0 :     return (get_ClassifierInfo()) == (aRhs);
     199             : }
     200             : 
     201           0 : auto MaybeInfo::operator==(const void_t& aRhs) const -> bool
     202             : {
     203           0 :     return (get_void_t()) == (aRhs);
     204             : }
     205             : 
     206           0 : auto MaybeInfo::operator==(const MaybeInfo& aRhs) const -> bool
     207             : {
     208           0 :     if ((type()) != ((aRhs).type())) {
     209           0 :         return false;
     210             :     }
     211             : 
     212           0 :     switch (type()) {
     213             :     case TClassifierInfo:
     214             :         {
     215           0 :             return (get_ClassifierInfo()) == ((aRhs).get_ClassifierInfo());
     216             :         }
     217             :     case Tvoid_t:
     218             :         {
     219           0 :             return (get_void_t()) == ((aRhs).get_void_t());
     220             :         }
     221             :     default:
     222             :         {
     223           0 :             mozilla::ipc::LogicError("unreached");
     224           0 :             return false;
     225             :         }
     226             :     }
     227             : }
     228             : 
     229           0 : auto MaybeInfo::get(ClassifierInfo* aOutValue) const -> void
     230             : {
     231           0 :     (*(aOutValue)) = get_ClassifierInfo();
     232           0 : }
     233             : 
     234           0 : auto MaybeInfo::get(void_t* aOutValue) const -> void
     235             : {
     236           0 :     (*(aOutValue)) = get_void_t();
     237           0 : }
     238             : 
     239             : } // namespace dom
     240             : } // namespace mozilla

Generated by: LCOV version 1.13