Back to index

lightning-sunbird  0.9+nobinonly
Classes | Defines
nsISupportsImpl.h File Reference
#include "nscore.h"
#include "nsISupportsBase.h"
#include "prthread.h"
#include "pratom.h"
#include "nsDebug.h"
#include "nsTraceRefcnt.h"
#include "nsIClassInfo.h"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  nsAutoRefCnt

Defines

#define NS_DECL_OWNINGTHREAD   /* nothing */
#define NS_ASSERT_OWNINGTHREAD(_class)   ((void)0)
#define NS_DECL_ISUPPORTS
 Declare the reference count variable and the implementations of the AddRef and QueryInterface methods.
#define NS_INIT_ISUPPORTS()   ((void)0)
 Previously used to initialize the reference count, but no longer needed.
#define NS_IMPL_ADDREF(_class)
 Use this macro to implement the AddRef method for a given _class
#define NS_IMPL_ADDREF_USING_AGGREGATOR(_class, _aggregator)
 Use this macro to implement the AddRef method for a given _class implemented as a wholly owned aggregated object intended to implement interface(s) for its owner.
#define NS_IMPL_RELEASE_WITH_DESTROY(_class, _destroy)
 Use this macro to implement the Release method for a given _class.
#define NS_IMPL_RELEASE(_class)   NS_IMPL_RELEASE_WITH_DESTROY(_class, NS_DELETEXPCOM(this))
 Use this macro to implement the Release method for a given _class
#define NS_IMPL_RELEASE_USING_AGGREGATOR(_class, _aggregator)
 Use this macro to implement the Release method for a given _class implemented as a wholly owned aggregated object intended to implement interface(s) for its owner.
#define NS_IMPL_QUERY_HEAD(_class)
 This implements query interface with two assumptions: First, the class in question implements nsISupports and its own interface and nothing else.
#define NS_IMPL_QUERY_BODY(_interface)
#define NS_IMPL_QUERY_BODY_CONDITIONAL(_interface, condition)
#define NS_IMPL_QUERY_BODY_AMBIGUOUS(_interface, _implClass)
#define NS_IMPL_QUERY_BODY_AGGREGATED(_interface, _aggregate)
#define NS_IMPL_QUERY_TAIL_GUTS
#define NS_IMPL_QUERY_TAIL_INHERITING(_baseclass)
#define NS_IMPL_QUERY_TAIL_USING_AGGREGATOR(_aggregator)
#define NS_IMPL_QUERY_TAIL(_supports_interface)
#define NS_INTERFACE_MAP_BEGIN(_implClass)   NS_IMPL_QUERY_HEAD(_implClass)
#define NS_INTERFACE_MAP_ENTRY(_interface)   NS_IMPL_QUERY_BODY(_interface)
#define NS_INTERFACE_MAP_ENTRY_CONDITIONAL(_interface, condition)   NS_IMPL_QUERY_BODY_CONDITIONAL(_interface, condition)
#define NS_INTERFACE_MAP_ENTRY_AGGREGATED(_interface, _aggregate)   NS_IMPL_QUERY_BODY_AGGREGATED(_interface,_aggregate)
#define NS_INTERFACE_MAP_END   NS_IMPL_QUERY_TAIL_GUTS
#define NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(_interface, _implClass)   NS_IMPL_QUERY_BODY_AMBIGUOUS(_interface, _implClass)
#define NS_INTERFACE_MAP_END_INHERITING(_baseClass)   NS_IMPL_QUERY_TAIL_INHERITING(_baseClass)
#define NS_INTERFACE_MAP_END_AGGREGATED(_aggregator)   NS_IMPL_QUERY_TAIL_USING_AGGREGATOR(_aggregator)
#define NS_IMPL_QUERY_INTERFACE0(_class)
#define NS_IMPL_QUERY_INTERFACE1(_class, _i1)
#define NS_IMPL_QUERY_INTERFACE2(_class, _i1, _i2)
#define NS_IMPL_QUERY_INTERFACE3(_class, _i1, _i2, _i3)
#define NS_IMPL_QUERY_INTERFACE4(_class, _i1, _i2, _i3, _i4)
#define NS_IMPL_QUERY_INTERFACE5(_class, _i1, _i2, _i3, _i4, _i5)
#define NS_IMPL_QUERY_INTERFACE6(_class, _i1, _i2, _i3, _i4, _i5, _i6)
#define NS_IMPL_QUERY_INTERFACE7(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7)
#define NS_IMPL_QUERY_INTERFACE8(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8)
#define NS_IMPL_QUERY_INTERFACE9(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9)
#define NS_IMPL_QUERY_INTERFACE10(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10)
#define NS_IMPL_QUERY_INTERFACE11(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10, _i11)
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE0   NS_IMPL_QUERY_INTERFACE0
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE1   NS_IMPL_QUERY_INTERFACE1
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE2   NS_IMPL_QUERY_INTERFACE2
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE3   NS_IMPL_QUERY_INTERFACE3
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE4   NS_IMPL_QUERY_INTERFACE4
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE5   NS_IMPL_QUERY_INTERFACE5
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE6   NS_IMPL_QUERY_INTERFACE6
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE7   NS_IMPL_QUERY_INTERFACE7
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE8   NS_IMPL_QUERY_INTERFACE8
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE9   NS_IMPL_QUERY_INTERFACE9
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE10   NS_IMPL_QUERY_INTERFACE10
#define NS_IMPL_THREADSAFE_QUERY_INTERFACE11   NS_IMPL_QUERY_INTERFACE11
#define NS_DECL_ISUPPORTS_INHERITED
 Declare that you're going to inherit from something that already implements nsISupports, but also implements an additional interface, thus causing an ambiguity.
#define NS_IMPL_ADDREF_INHERITED(Class, Super)
 These macros can be used in conjunction with NS_DECL_ISUPPORTS_INHERITED to implement the nsISupports methods, forwarding the invocations to a superclass that already implements nsISupports.
#define NS_IMPL_RELEASE_INHERITED(Class, Super)
#define NS_IMPL_QUERY_INTERFACE_INHERITED0(Class, Super)
#define NS_IMPL_QUERY_INTERFACE_INHERITED1(Class, Super, i1)
#define NS_IMPL_QUERY_INTERFACE_INHERITED2(Class, Super, i1, i2)
#define NS_IMPL_QUERY_INTERFACE_INHERITED3(Class, Super, i1, i2, i3)
#define NS_IMPL_QUERY_INTERFACE_INHERITED4(Class, Super, i1, i2, i3, i4)
#define NS_IMPL_QUERY_INTERFACE_INHERITED5(Class, Super, i1, i2, i3, i4, i5)
#define NS_IMPL_QUERY_INTERFACE_INHERITED6(Class, Super, i1, i2, i3, i4, i5, i6)
#define NS_IMPL_ISUPPORTS0(_class)
 Convenience macros for implementing all nsISupports methods for a simple class.
#define NS_IMPL_ISUPPORTS1(_class, _interface)
#define NS_IMPL_ISUPPORTS2(_class, _i1, _i2)
#define NS_IMPL_ISUPPORTS3(_class, _i1, _i2, _i3)
#define NS_IMPL_ISUPPORTS4(_class, _i1, _i2, _i3, _i4)
#define NS_IMPL_ISUPPORTS5(_class, _i1, _i2, _i3, _i4, _i5)
#define NS_IMPL_ISUPPORTS6(_class, _i1, _i2, _i3, _i4, _i5, _i6)
#define NS_IMPL_ISUPPORTS7(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7)
#define NS_IMPL_ISUPPORTS8(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8)
#define NS_IMPL_ISUPPORTS9(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8,_i9)
#define NS_IMPL_ISUPPORTS10(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8,_i9, _i10)
#define NS_IMPL_ISUPPORTS11(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8,_i9, _i10, _i11)
#define NS_IMPL_ISUPPORTS_INHERITED0(Class, Super)
#define NS_IMPL_ISUPPORTS_INHERITED1(Class, Super, i1)
#define NS_IMPL_ISUPPORTS_INHERITED2(Class, Super, i1, i2)
#define NS_IMPL_ISUPPORTS_INHERITED3(Class, Super, i1, i2, i3)
#define NS_IMPL_ISUPPORTS_INHERITED4(Class, Super, i1, i2, i3, i4)
#define NS_IMPL_ISUPPORTS_INHERITED5(Class, Super, i1, i2, i3, i4, i5)
#define NS_IMPL_ISUPPORTS_INHERITED6(Class, Super, i1, i2, i3, i4, i5, i6)
#define NS_IMPL_THREADSAFE_ADDREF(_class)
 Threadsafe implementations of the ISupports convenience macros.
#define NS_IMPL_THREADSAFE_RELEASE(_class)
 Use this macro to implement the Release method for a given _class
#define NS_IMPL_THREADSAFE_ISUPPORTS0(_class)
#define NS_IMPL_THREADSAFE_ISUPPORTS1(_class, _interface)
#define NS_IMPL_THREADSAFE_ISUPPORTS2(_class, _i1, _i2)
#define NS_IMPL_THREADSAFE_ISUPPORTS3(_class, _i1, _i2, _i3)
#define NS_IMPL_THREADSAFE_ISUPPORTS4(_class, _i1, _i2, _i3, _i4)
#define NS_IMPL_THREADSAFE_ISUPPORTS5(_class, _i1, _i2, _i3, _i4, _i5)
#define NS_IMPL_THREADSAFE_ISUPPORTS6(_class, _i1, _i2, _i3, _i4, _i5, _i6)
#define NS_IMPL_THREADSAFE_ISUPPORTS7(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7)
#define NS_IMPL_THREADSAFE_ISUPPORTS8(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8)
#define NS_IMPL_THREADSAFE_ISUPPORTS9(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9)
#define NS_IMPL_THREADSAFE_ISUPPORTS10(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10)
#define NS_IMPL_THREADSAFE_ISUPPORTS11(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10, _i11)
#define NS_CLASSINFO_NAME(_class)   _class##_classInfoGlobal
#define NS_CI_INTERFACE_GETTER_NAME(_class)   _class##_GetInterfacesHelper
#define NS_DECL_CI_INTERFACE_GETTER(_class)
#define NS_DECL_CLASSINFO(_class)
#define NS_IMPL_QUERY_CLASSINFO(_class)
#define NS_CLASSINFO_HELPER_BEGIN(_class, _c)
#define NS_CLASSINFO_HELPER_ENTRY(_i, _interface)
#define NS_CLASSINFO_HELPER_END
#define NS_IMPL_CI_INTERFACE_GETTER1(_class, _interface)
#define NS_IMPL_QUERY_INTERFACE1_CI(_class, _i1)
#define NS_IMPL_ISUPPORTS1_CI(_class, _interface)
#define NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)
#define NS_IMPL_QUERY_INTERFACE2_CI(_class, _i1, _i2)
#define NS_IMPL_ISUPPORTS2_CI(_class, _i1, _i2)
#define NS_IMPL_CI_INTERFACE_GETTER3(_class, _i1, _i2, _i3)
#define NS_IMPL_QUERY_INTERFACE3_CI(_class, _i1, _i2, _i3)
#define NS_IMPL_ISUPPORTS3_CI(_class, _i1, _i2, _i3)
#define NS_IMPL_CI_INTERFACE_GETTER4(_class, _i1, _i2, _i3, _i4)
#define NS_IMPL_QUERY_INTERFACE4_CI(_class, _i1, _i2, _i3, _i4)
#define NS_IMPL_ISUPPORTS4_CI(_class, _i1, _i2, _i3, _i4)
#define NS_IMPL_CI_INTERFACE_GETTER5(_class, _i1, _i2, _i3, _i4, _i5)
#define NS_IMPL_QUERY_INTERFACE5_CI(_class, _i1, _i2, _i3, _i4, _i5)
#define NS_IMPL_ISUPPORTS5_CI(_class, _i1, _i2, _i3, _i4, _i5)
#define NS_IMPL_CI_INTERFACE_GETTER6(_class, _i1, _i2, _i3, _i4, _i5, _i6)
#define NS_IMPL_QUERY_INTERFACE6_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6)
#define NS_IMPL_ISUPPORTS6_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6)
#define NS_IMPL_CI_INTERFACE_GETTER7(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7)
#define NS_IMPL_QUERY_INTERFACE7_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7)
#define NS_IMPL_ISUPPORTS7_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7)
#define NS_IMPL_CI_INTERFACE_GETTER8(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8)
#define NS_IMPL_QUERY_INTERFACE8_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8)
#define NS_IMPL_ISUPPORTS8_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8)
#define NS_IMPL_CI_INTERFACE_GETTER9(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9)
#define NS_IMPL_QUERY_INTERFACE9_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9)
#define NS_IMPL_ISUPPORTS9_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,_i8, _i9)
#define NS_IMPL_CI_INTERFACE_GETTER10(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10)
#define NS_IMPL_CI_INTERFACE_GETTER11(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10, _i11)
#define NS_IMPL_QUERY_INTERFACE10_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10)
#define NS_IMPL_QUERY_INTERFACE11_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6,_i7, _i8, _i9, _i10, _i11)
#define NS_IMPL_ISUPPORTS10_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,_i8, _i9, _i10)
#define NS_IMPL_ISUPPORTS11_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,_i8, _i9, _i10, _i11)
#define NS_INTERFACE_MAP_END_THREADSAFE   NS_IMPL_QUERY_TAIL_GUTS

Define Documentation

#define NS_ASSERT_OWNINGTHREAD (   _class)    ((void)0)

Definition at line 87 of file nsISupportsImpl.h.

#define NS_CI_INTERFACE_GETTER_NAME (   _class)    _class##_GetInterfacesHelper

Definition at line 823 of file nsISupportsImpl.h.

#define NS_CLASSINFO_HELPER_BEGIN (   _class,
  _c 
)
Value:

Definition at line 839 of file nsISupportsImpl.h.

Value:
return NS_OK;                                                             \
}

Definition at line 850 of file nsISupportsImpl.h.

#define NS_CLASSINFO_HELPER_ENTRY (   _i,
  _interface 
)
Value:
(*array)[_i] = (nsIID *)nsMemory::Clone(&NS_GET_IID(_interface),          \
                                            sizeof(nsIID));

Definition at line 846 of file nsISupportsImpl.h.

#define NS_CLASSINFO_NAME (   _class)    _class##_classInfoGlobal

Definition at line 822 of file nsISupportsImpl.h.

Value:

Definition at line 825 of file nsISupportsImpl.h.

#define NS_DECL_CLASSINFO (   _class)
Value:

Definition at line 829 of file nsISupportsImpl.h.

Value:
public:                                                                       \
  NS_IMETHOD QueryInterface(REFNSIID aIID,                                    \
                            void** aInstancePtr);                             \
  NS_IMETHOD_(nsrefcnt) AddRef(void);                                         \
  NS_IMETHOD_(nsrefcnt) Release(void);                                        \
protected:                                                                    \
  nsAutoRefCnt mRefCnt;                                                       \
  NS_DECL_OWNINGTHREAD                                                        \
public:

Declare the reference count variable and the implementations of the AddRef and QueryInterface methods.

Definition at line 118 of file nsISupportsImpl.h.

Value:
public:                                                                       \
  NS_IMETHOD QueryInterface(REFNSIID aIID,                                    \
                            void** aInstancePtr);                             \
  NS_IMETHOD_(nsrefcnt) AddRef(void);                                         \
  NS_IMETHOD_(nsrefcnt) Release(void);                                        \

Declare that you're going to inherit from something that already implements nsISupports, but also implements an additional interface, thus causing an ambiguity.

In this case you don't need another mRefCnt, you just need to forward the definitions to the appropriate superclass. E.g.

class Bar : public Foo, public nsIBar { // both provide nsISupports public: NS_DECL_ISUPPORTS_INHERITED ...other nsIBar and Bar methods... };

Definition at line 503 of file nsISupportsImpl.h.

#define NS_DECL_OWNINGTHREAD   /* nothing */

Definition at line 86 of file nsISupportsImpl.h.

#define NS_IMPL_ADDREF (   _class)
Value:
NS_IMETHODIMP_(nsrefcnt) _class::AddRef(void)                                 \
{                                                                             \
  NS_PRECONDITION(PRInt32(mRefCnt) >= 0, "illegal refcnt");                   \
  NS_ASSERT_OWNINGTHREAD(_class);                                             \
  ++mRefCnt;                                                                  \
  NS_LOG_ADDREF(this, mRefCnt, #_class, sizeof(*this));                       \
  return mRefCnt;                                                             \
}

Use this macro to implement the AddRef method for a given _class

Parameters:
_classThe name of the class implementing the method

Definition at line 143 of file nsISupportsImpl.h.

#define NS_IMPL_ADDREF_INHERITED (   Class,
  Super 
)
Value:
NS_IMETHODIMP_(nsrefcnt) Class::AddRef(void)                                  \
{                                                                             \
  return Super::AddRef();                                                     \
}                                                                             \

These macros can be used in conjunction with NS_DECL_ISUPPORTS_INHERITED to implement the nsISupports methods, forwarding the invocations to a superclass that already implements nsISupports.

Note that I didn't make these inlined because they're virtual methods.

Definition at line 518 of file nsISupportsImpl.h.

#define NS_IMPL_ADDREF_USING_AGGREGATOR (   _class,
  _aggregator 
)
Value:
NS_IMETHODIMP_(nsrefcnt) _class::AddRef(void)                                 \
{                                                                             \
  NS_PRECONDITION(_aggregator, "null aggregator");                            \
  return (_aggregator)->AddRef();                                             \
}

Use this macro to implement the AddRef method for a given _class implemented as a wholly owned aggregated object intended to implement interface(s) for its owner.

Parameters:
_classThe name of the class implementing the method
_aggregatorthe owning/containing object

Definition at line 160 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER1 (   _class,
  _interface 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 1)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _interface)                                 \
   NS_CLASSINFO_HELPER_END

Definition at line 854 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER10 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 10)                                      \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
     NS_CLASSINFO_HELPER_ENTRY(5, _i6)                                        \
     NS_CLASSINFO_HELPER_ENTRY(6, _i7)                                        \
     NS_CLASSINFO_HELPER_ENTRY(7, _i8)                                        \
     NS_CLASSINFO_HELPER_ENTRY(8, _i9)                                        \
     NS_CLASSINFO_HELPER_ENTRY(9, _i10)                                       \
   NS_CLASSINFO_HELPER_END

Definition at line 1097 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER11 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10,
  _i11 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 11)                                      \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
     NS_CLASSINFO_HELPER_ENTRY(5, _i6)                                        \
     NS_CLASSINFO_HELPER_ENTRY(6, _i7)                                        \
     NS_CLASSINFO_HELPER_ENTRY(7, _i8)                                        \
     NS_CLASSINFO_HELPER_ENTRY(8, _i9)                                        \
     NS_CLASSINFO_HELPER_ENTRY(9, _i10)                                       \
     NS_CLASSINFO_HELPER_ENTRY(10, _i11)                                      \
   NS_CLASSINFO_HELPER_END

Definition at line 1112 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER2 (   _class,
  _i1,
  _i2 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 2)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 872 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER3 (   _class,
  _i1,
  _i2,
  _i3 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 3)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 892 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER4 (   _class,
  _i1,
  _i2,
  _i3,
  _i4 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 4)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 914 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER5 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 5)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 938 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER6 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 6)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
     NS_CLASSINFO_HELPER_ENTRY(5, _i6)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 964 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER7 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 7)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
     NS_CLASSINFO_HELPER_ENTRY(5, _i6)                                        \
     NS_CLASSINFO_HELPER_ENTRY(6, _i7)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 992 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER8 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 8)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
     NS_CLASSINFO_HELPER_ENTRY(5, _i6)                                        \
     NS_CLASSINFO_HELPER_ENTRY(6, _i7)                                        \
     NS_CLASSINFO_HELPER_ENTRY(7, _i8)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 1024 of file nsISupportsImpl.h.

#define NS_IMPL_CI_INTERFACE_GETTER9 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9 
)
Value:
NS_CLASSINFO_HELPER_BEGIN(_class, 9)                                       \
     NS_CLASSINFO_HELPER_ENTRY(0, _i1)                                        \
     NS_CLASSINFO_HELPER_ENTRY(1, _i2)                                        \
     NS_CLASSINFO_HELPER_ENTRY(2, _i3)                                        \
     NS_CLASSINFO_HELPER_ENTRY(3, _i4)                                        \
     NS_CLASSINFO_HELPER_ENTRY(4, _i5)                                        \
     NS_CLASSINFO_HELPER_ENTRY(5, _i6)                                        \
     NS_CLASSINFO_HELPER_ENTRY(6, _i7)                                        \
     NS_CLASSINFO_HELPER_ENTRY(7, _i8)                                        \
     NS_CLASSINFO_HELPER_ENTRY(8, _i9)                                        \
   NS_CLASSINFO_HELPER_END

Definition at line 1058 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS0 (   _class)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE0(_class)

Convenience macros for implementing all nsISupports methods for a simple class.

Parameters:
_classThe name of the class implementing the method
_classiiddefThe name of the define symbol that defines the IID for the class (e.g. NS_ISUPPORTS_IID)

Definition at line 587 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS1 (   _class,
  _interface 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE1(_class, _interface)

Definition at line 592 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS10 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE10(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8,   \
                            _i9, _i10)

Definition at line 638 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS10_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE10_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,     \
                               _i8, _i9, _i10)                                \
  NS_IMPL_CI_INTERFACE_GETTER10(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,    \
                                _i8, _i9, _i10)

Definition at line 1163 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS11 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10,
  _i11 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE11(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8,   \
                            _i9, _i10, _i11)

Definition at line 645 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS11_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10,
  _i11 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE11_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,     \
                               _i8, _i9, _i10, _i11)                          \
  NS_IMPL_CI_INTERFACE_GETTER11(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,    \
                                _i8, _i9, _i10, _i11)

Definition at line 1172 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS1_CI (   _class,
  _interface 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE1_CI(_class, _interface)                             \
  NS_IMPL_CI_INTERFACE_GETTER1(_class, _interface)

Definition at line 866 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS2 (   _class,
  _i1,
  _i2 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE2(_class, _i1, _i2)

Definition at line 597 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS2_CI (   _class,
  _i1,
  _i2 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE2_CI(_class, _i1, _i2)                               \
  NS_IMPL_CI_INTERFACE_GETTER2(_class, _i1, _i2)

Definition at line 886 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS3 (   _class,
  _i1,
  _i2,
  _i3 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE3(_class, _i1, _i2, _i3)

Definition at line 602 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS3_CI (   _class,
  _i1,
  _i2,
  _i3 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE3_CI(_class, _i1, _i2, _i3)                          \
  NS_IMPL_CI_INTERFACE_GETTER3(_class, _i1, _i2, _i3)

Definition at line 908 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS4 (   _class,
  _i1,
  _i2,
  _i3,
  _i4 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE4(_class, _i1, _i2, _i3, _i4)

Definition at line 607 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS4_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE4_CI(_class, _i1, _i2, _i3, _i4)                     \
  NS_IMPL_CI_INTERFACE_GETTER4(_class, _i1, _i2, _i3, _i4)

Definition at line 932 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS5 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE5(_class, _i1, _i2, _i3, _i4, _i5)

Definition at line 612 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS5_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE5_CI(_class, _i1, _i2, _i3, _i4, _i5)                \
  NS_IMPL_CI_INTERFACE_GETTER5(_class, _i1, _i2, _i3, _i4, _i5)

Definition at line 958 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS6 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE6(_class, _i1, _i2, _i3, _i4, _i5, _i6)

Definition at line 617 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS6_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE6_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6)           \
  NS_IMPL_CI_INTERFACE_GETTER6(_class, _i1, _i2, _i3, _i4, _i5, _i6)

Definition at line 986 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS7 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE7(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7)

Definition at line 622 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS7_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE7_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7)      \
  NS_IMPL_CI_INTERFACE_GETTER7(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7)

Definition at line 1018 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS8 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE8(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8)

Definition at line 627 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS8_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE8_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8) \
  NS_IMPL_CI_INTERFACE_GETTER8(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8)

Definition at line 1052 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS9 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE9(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7, _i8, _i9)

Definition at line 632 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS9_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9 
)
Value:
NS_IMPL_ADDREF(_class)                                                      \
  NS_IMPL_RELEASE(_class)                                                     \
  NS_IMPL_QUERY_INTERFACE9_CI(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,      \
                              _i8, _i9)                                       \
  NS_IMPL_CI_INTERFACE_GETTER9(_class, _i1, _i2, _i3, _i4, _i5, _i6, _i7,     \
                               _i8, _i9)

Definition at line 1088 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED0 (   Class,
  Super 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED0(Class, Super)                          \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 652 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED1 (   Class,
  Super,
  i1 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED1(Class, Super, i1)                      \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 657 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED2 (   Class,
  Super,
  i1,
  i2 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED2(Class, Super, i1, i2)                  \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 662 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED3 (   Class,
  Super,
  i1,
  i2,
  i3 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED3(Class, Super, i1, i2, i3)              \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 667 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED4 (   Class,
  Super,
  i1,
  i2,
  i3,
  i4 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED4(Class, Super, i1, i2, i3, i4)          \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 672 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED5 (   Class,
  Super,
  i1,
  i2,
  i3,
  i4,
  i5 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED5(Class, Super, i1, i2, i3, i4, i5)      \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 677 of file nsISupportsImpl.h.

#define NS_IMPL_ISUPPORTS_INHERITED6 (   Class,
  Super,
  i1,
  i2,
  i3,
  i4,
  i5,
  i6 
)
Value:
NS_IMPL_QUERY_INTERFACE_INHERITED6(Class, Super, i1, i2, i3, i4, i5, i6)  \
    NS_IMPL_ADDREF_INHERITED(Class, Super)                                    \
    NS_IMPL_RELEASE_INHERITED(Class, Super)                                   \

Definition at line 682 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_BODY (   _interface)
Value:
if ( aIID.Equals(NS_GET_IID(_interface)) )                                  \
    foundInterface = NS_STATIC_CAST(_interface*, this);                       \
  else

Definition at line 257 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_BODY_AGGREGATED (   _interface,
  _aggregate 
)
Value:
if ( aIID.Equals(NS_GET_IID(_interface)) )                                  \
    foundInterface = NS_STATIC_CAST(_interface*, _aggregate);                 \
  else

Definition at line 273 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_BODY_AMBIGUOUS (   _interface,
  _implClass 
)
Value:
if ( aIID.Equals(NS_GET_IID(_interface)) )                                  \
    foundInterface = NS_STATIC_CAST(_interface*,                              \
                                    NS_STATIC_CAST(_implClass*, this));       \
  else

Definition at line 267 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_BODY_CONDITIONAL (   _interface,
  condition 
)
Value:
if ( (condition) && aIID.Equals(NS_GET_IID(_interface)))                    \
    foundInterface = NS_STATIC_CAST(_interface*, this);                       \
  else

Definition at line 262 of file nsISupportsImpl.h.

Value:
if ( aIID.Equals(NS_GET_IID(nsIClassInfo)) ) {                              \
    extern nsIClassInfo *NS_CLASSINFO_NAME(_class);                           \
    foundInterface = NS_STATIC_CAST(nsIClassInfo*, NS_CLASSINFO_NAME(_class));\
  } else

Definition at line 833 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_HEAD (   _class)
Value:
NS_IMETHODIMP _class::QueryInterface(REFNSIID aIID, void** aInstancePtr)      \
{                                                                             \
  NS_ASSERTION(aInstancePtr,                                                  \
               "QueryInterface requires a non-NULL destination!");            \
  nsISupports* foundInterface;

This implements query interface with two assumptions: First, the class in question implements nsISupports and its own interface and nothing else.

Second, the implementation of the class's primary inheritance chain leads to its own interface.

Parameters:
_classThe name of the class implementing the method
_classiiddefThe name of the define symbol that defines the IID for the class (e.g. NS_ISUPPORTS_IID)

Definition at line 250 of file nsISupportsImpl.h.

Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(nsISupports)                                       \
  NS_INTERFACE_MAP_END

Definition at line 347 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE1 (   _class,
  _i1 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 352 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE10 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY(_i9)                                               \
    NS_INTERFACE_MAP_ENTRY(_i10)                                              \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 444 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE10_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY(_i9)                                               \
    NS_INTERFACE_MAP_ENTRY(_i10)                                              \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 1128 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE11 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10,
  _i11 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY(_i9)                                               \
    NS_INTERFACE_MAP_ENTRY(_i10)                                              \
    NS_INTERFACE_MAP_ENTRY(_i11)                                              \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 460 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE11_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10,
  _i11 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY(_i9)                                               \
    NS_INTERFACE_MAP_ENTRY(_i10)                                              \
    NS_INTERFACE_MAP_ENTRY(_i11)                                              \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 1145 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE1_CI (   _class,
  _i1 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 859 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE2 (   _class,
  _i1,
  _i2 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 358 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE2_CI (   _class,
  _i1,
  _i2 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 878 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE3 (   _class,
  _i1,
  _i2,
  _i3 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 365 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE3_CI (   _class,
  _i1,
  _i2,
  _i3 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 899 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE4 (   _class,
  _i1,
  _i2,
  _i3,
  _i4 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 373 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE4_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 922 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE5 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 382 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE5_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 947 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE6 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 392 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE6_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 974 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE7 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 403 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE7_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 1004 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE8 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 415 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE8_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 1037 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE9 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY(_i9)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
  NS_INTERFACE_MAP_END

Definition at line 429 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE9_CI (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9 
)
Value:
NS_INTERFACE_MAP_BEGIN(_class)                                              \
    NS_INTERFACE_MAP_ENTRY(_i1)                                               \
    NS_INTERFACE_MAP_ENTRY(_i2)                                               \
    NS_INTERFACE_MAP_ENTRY(_i3)                                               \
    NS_INTERFACE_MAP_ENTRY(_i4)                                               \
    NS_INTERFACE_MAP_ENTRY(_i5)                                               \
    NS_INTERFACE_MAP_ENTRY(_i6)                                               \
    NS_INTERFACE_MAP_ENTRY(_i7)                                               \
    NS_INTERFACE_MAP_ENTRY(_i8)                                               \
    NS_INTERFACE_MAP_ENTRY(_i9)                                               \
    NS_INTERFACE_MAP_ENTRY_AMBIGUOUS(nsISupports, _i1)                        \
    NS_IMPL_QUERY_CLASSINFO(_class)                                           \
  NS_INTERFACE_MAP_END

Definition at line 1072 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED0 (   Class,
  Super 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 530 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED1 (   Class,
  Super,
  i1 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_BODY(i1)                                                      \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 534 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED2 (   Class,
  Super,
  i1,
  i2 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_BODY(i1)                                                      \
  NS_IMPL_QUERY_BODY(i2)                                                      \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 539 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED3 (   Class,
  Super,
  i1,
  i2,
  i3 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_BODY(i1)                                                      \
  NS_IMPL_QUERY_BODY(i2)                                                      \
  NS_IMPL_QUERY_BODY(i3)                                                      \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 545 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED4 (   Class,
  Super,
  i1,
  i2,
  i3,
  i4 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_BODY(i1)                                                      \
  NS_IMPL_QUERY_BODY(i2)                                                      \
  NS_IMPL_QUERY_BODY(i3)                                                      \
  NS_IMPL_QUERY_BODY(i4)                                                      \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 552 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED5 (   Class,
  Super,
  i1,
  i2,
  i3,
  i4,
  i5 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_BODY(i1)                                                      \
  NS_IMPL_QUERY_BODY(i2)                                                      \
  NS_IMPL_QUERY_BODY(i3)                                                      \
  NS_IMPL_QUERY_BODY(i4)                                                      \
  NS_IMPL_QUERY_BODY(i5)                                                      \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 560 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_INTERFACE_INHERITED6 (   Class,
  Super,
  i1,
  i2,
  i3,
  i4,
  i5,
  i6 
)
Value:
NS_IMPL_QUERY_HEAD(Class)                                                   \
  NS_IMPL_QUERY_BODY(i1)                                                      \
  NS_IMPL_QUERY_BODY(i2)                                                      \
  NS_IMPL_QUERY_BODY(i3)                                                      \
  NS_IMPL_QUERY_BODY(i4)                                                      \
  NS_IMPL_QUERY_BODY(i5)                                                      \
  NS_IMPL_QUERY_BODY(i6)                                                      \
  NS_IMPL_QUERY_TAIL_INHERITING(Super)                                        \

Definition at line 569 of file nsISupportsImpl.h.

#define NS_IMPL_QUERY_TAIL (   _supports_interface)
Value:
NS_IMPL_QUERY_BODY_AMBIGUOUS(nsISupports, _supports_interface)              \
  NS_IMPL_QUERY_TAIL_GUTS

Definition at line 321 of file nsISupportsImpl.h.

Value:
foundInterface = 0;                                                       \
  nsresult status;                                                            \
  if ( !foundInterface )                                                      \
    status = NS_NOINTERFACE;                                                  \
  else                                                                        \
    {                                                                         \
      NS_ADDREF(foundInterface);                                              \
      status = NS_OK;                                                         \
    }                                                                         \
  *aInstancePtr = foundInterface;                                             \
  return status;                                                              \
}

Definition at line 278 of file nsISupportsImpl.h.

Value:
foundInterface = 0;                                                       \
  nsresult status;                                                            \
  if ( !foundInterface )                                                      \
    status = _baseclass::QueryInterface(aIID, (void**)&foundInterface);       \
  else                                                                        \
    {                                                                         \
      NS_ADDREF(foundInterface);                                              \
      status = NS_OK;                                                         \
    }                                                                         \
  *aInstancePtr = foundInterface;                                             \
  return status;                                                              \
}

Definition at line 292 of file nsISupportsImpl.h.

Value:
foundInterface = 0;                                                       \
  nsresult status;                                                            \
  if ( !foundInterface ) {                                                    \
    NS_ASSERTION(_aggregator, "null aggregator");                             \
    status = _aggregator->QueryInterface(aIID, (void**)&foundInterface);      \
  } else                                                                      \
    {                                                                         \
      NS_ADDREF(foundInterface);                                              \
      status = NS_OK;                                                         \
    }                                                                         \
  *aInstancePtr = foundInterface;                                             \
  return status;                                                              \
}

Definition at line 306 of file nsISupportsImpl.h.

Use this macro to implement the Release method for a given _class

Parameters:
_classThe name of the class implementing the method

A note on the 'stabilization' of the refcnt to one. At that point, the object's refcount will have gone to zero. The object's destructor may trigger code that attempts to QueryInterface() and Release() 'this' again. Doing so will temporarily increment and decrement the refcount. (Only a logic error would make one try to keep a permanent hold on 'this'.) To prevent re-entering the destructor, we make sure that no balanced refcounting can return the refcount to |0|.

Definition at line 214 of file nsISupportsImpl.h.

#define NS_IMPL_RELEASE_INHERITED (   Class,
  Super 
)
Value:
NS_IMETHODIMP_(nsrefcnt) Class::Release(void)                                 \
{                                                                             \
  return Super::Release();                                                    \
}                                                                             \

Definition at line 524 of file nsISupportsImpl.h.

#define NS_IMPL_RELEASE_USING_AGGREGATOR (   _class,
  _aggregator 
)
Value:
NS_IMETHODIMP_(nsrefcnt) _class::Release(void)                                \
{                                                                             \
  NS_PRECONDITION(_aggregator, "null aggregator");                            \
  return (_aggregator)->Release();                                            \
}

Use this macro to implement the Release method for a given _class implemented as a wholly owned aggregated object intended to implement interface(s) for its owner.

Parameters:
_classThe name of the class implementing the method
_aggregatorthe owning/containing object

Definition at line 224 of file nsISupportsImpl.h.

#define NS_IMPL_RELEASE_WITH_DESTROY (   _class,
  _destroy 
)
Value:
NS_IMETHODIMP_(nsrefcnt) _class::Release(void)                                \
{                                                                             \
  NS_PRECONDITION(0 != mRefCnt, "dup release");                               \
  NS_ASSERT_OWNINGTHREAD(_class);                                             \
  --mRefCnt;                                                                  \
  NS_LOG_RELEASE(this, mRefCnt, #_class);                                     \
  if (mRefCnt == 0) {                                                         \
    mRefCnt = 1; /* stabilize */                                              \
    _destroy;                                                                 \
    return 0;                                                                 \
  }                                                                           \
  return mRefCnt;                                                             \
}

Use this macro to implement the Release method for a given _class.

Parameters:
_classThe name of the class implementing the method
_destroyA statement that is executed when the object's refcount drops to zero.

For example,

NS_IMPL_RELEASE_WITH_DESTROY(Foo, Destroy(this))

will cause

Destroy(this);

to be invoked when the object's refcount drops to zero. This allows for arbitrary teardown activity to occur (e.g., deallocation of object allocated with placement new).

Definition at line 186 of file nsISupportsImpl.h.

Value:
NS_IMETHODIMP_(nsrefcnt) _class::AddRef(void)                                 \
{                                                                             \
  NS_PRECONDITION(PRInt32(mRefCnt) >= 0, "illegal refcnt");                   \
  nsrefcnt count;                                                             \
  count = PR_AtomicIncrement((PRInt32*)&mRefCnt);                             \
  NS_LOG_ADDREF(this, count, #_class, sizeof(*this));                         \
  return count;                                                               \
}

Threadsafe implementations of the ISupports convenience macros.

Note:
These are not available when linking against the standalone glue, because the implementation requires PR_ symbols. Use this macro to implement the AddRef method for a given _class
Parameters:
_classThe name of the class implementing the method

Definition at line 703 of file nsISupportsImpl.h.

Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE0(_class)

Definition at line 745 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS1 (   _class,
  _interface 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE1(_class, _interface)

Definition at line 750 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS10 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE10(_class, _i1, _i2, _i3, _i4, _i5, _i6,  \
                                       _i7, _i8, _i9, _i10)

Definition at line 801 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS11 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9,
  _i10,
  _i11 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE11(_class, _i1, _i2, _i3, _i4, _i5, _i6,  \
                                       _i7, _i8, _i9, _i10, _i11)

Definition at line 808 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS2 (   _class,
  _i1,
  _i2 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE2(_class, _i1, _i2)

Definition at line 755 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS3 (   _class,
  _i1,
  _i2,
  _i3 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE3(_class, _i1, _i2, _i3)

Definition at line 760 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS4 (   _class,
  _i1,
  _i2,
  _i3,
  _i4 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE4(_class, _i1, _i2, _i3, _i4)

Definition at line 765 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS5 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE5(_class, _i1, _i2, _i3, _i4, _i5)

Definition at line 770 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS6 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE6(_class, _i1, _i2, _i3, _i4, _i5, _i6)

Definition at line 775 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS7 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE7(_class, _i1, _i2, _i3, _i4, _i5, _i6,   \
                                      _i7)

Definition at line 780 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS8 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE8(_class, _i1, _i2, _i3, _i4, _i5, _i6,   \
                                      _i7, _i8)

Definition at line 787 of file nsISupportsImpl.h.

#define NS_IMPL_THREADSAFE_ISUPPORTS9 (   _class,
  _i1,
  _i2,
  _i3,
  _i4,
  _i5,
  _i6,
  _i7,
  _i8,
  _i9 
)
Value:
NS_IMPL_THREADSAFE_ADDREF(_class)                                           \
  NS_IMPL_THREADSAFE_RELEASE(_class)                                          \
  NS_IMPL_THREADSAFE_QUERY_INTERFACE9(_class, _i1, _i2, _i3, _i4, _i5, _i6,   \
                                      _i7, _i8, _i9)

Definition at line 794 of file nsISupportsImpl.h.

Definition at line 478 of file nsISupportsImpl.h.

Definition at line 479 of file nsISupportsImpl.h.

Definition at line 488 of file nsISupportsImpl.h.

Definition at line 489 of file nsISupportsImpl.h.

Definition at line 480 of file nsISupportsImpl.h.

Definition at line 481 of file nsISupportsImpl.h.

Definition at line 482 of file nsISupportsImpl.h.

Definition at line 483 of file nsISupportsImpl.h.

Definition at line 484 of file nsISupportsImpl.h.

Definition at line 485 of file nsISupportsImpl.h.

Definition at line 486 of file nsISupportsImpl.h.

Definition at line 487 of file nsISupportsImpl.h.

Value:
NS_IMETHODIMP_(nsrefcnt) _class::Release(void)                                \
{                                                                             \
  nsrefcnt count;                                                             \
  NS_PRECONDITION(0 != mRefCnt, "dup release");                               \
  count = PR_AtomicDecrement((PRInt32 *)&mRefCnt);                            \
  NS_LOG_RELEASE(this, count, #_class);                                       \
  if (0 == count) {                                                           \
    mRefCnt = 1; /* stabilize */                                              \
    /* enable this to find non-threadsafe destructors: */                     \
    /* NS_ASSERT_OWNINGTHREAD(_class); */                                     \
    NS_DELETEXPCOM(this);                                                     \
    return 0;                                                                 \
  }                                                                           \
  return count;                                                               \
}

Use this macro to implement the Release method for a given _class

Parameters:
_classThe name of the class implementing the method

Definition at line 718 of file nsISupportsImpl.h.

#define NS_INIT_ISUPPORTS ( )    ((void)0)

Previously used to initialize the reference count, but no longer needed.

DEPRECATED.

Definition at line 137 of file nsISupportsImpl.h.

#define NS_INTERFACE_MAP_BEGIN (   _implClass)    NS_IMPL_QUERY_HEAD(_implClass)

Definition at line 332 of file nsISupportsImpl.h.

Definition at line 339 of file nsISupportsImpl.h.

Definition at line 344 of file nsISupportsImpl.h.

Definition at line 342 of file nsISupportsImpl.h.

Definition at line 1181 of file nsISupportsImpl.h.

#define NS_INTERFACE_MAP_ENTRY (   _interface)    NS_IMPL_QUERY_BODY(_interface)

Definition at line 333 of file nsISupportsImpl.h.

#define NS_INTERFACE_MAP_ENTRY_AGGREGATED (   _interface,
  _aggregate 
)    NS_IMPL_QUERY_BODY_AGGREGATED(_interface,_aggregate)

Definition at line 336 of file nsISupportsImpl.h.

#define NS_INTERFACE_MAP_ENTRY_AMBIGUOUS (   _interface,
  _implClass 
)    NS_IMPL_QUERY_BODY_AMBIGUOUS(_interface, _implClass)

Definition at line 340 of file nsISupportsImpl.h.

#define NS_INTERFACE_MAP_ENTRY_CONDITIONAL (   _interface,
  condition 
)    NS_IMPL_QUERY_BODY_CONDITIONAL(_interface, condition)

Definition at line 334 of file nsISupportsImpl.h.