2 * DO NOT EDIT. THIS FILE IS GENERATED FROM IDNSSDService.idl
5 #ifndef __gen_IDNSSDService_h__
6 #define __gen_IDNSSDService_h__
9 #ifndef __gen_nsISupports_h__
10 #include "nsISupports.h"
13 /* For IDL files that don't want to include root IDL files. */
17 class IDNSSDService
; /* forward declaration */
20 /* starting interface: IDNSSDBrowseListener */
21 #define IDNSSDBROWSELISTENER_IID_STR "27346495-a1ed-458a-a5bc-587df9a26b4f"
23 #define IDNSSDBROWSELISTENER_IID \
24 {0x27346495, 0xa1ed, 0x458a, \
25 { 0xa5, 0xbc, 0x58, 0x7d, 0xf9, 0xa2, 0x6b, 0x4f }}
27 class NS_NO_VTABLE NS_SCRIPTABLE IDNSSDBrowseListener
: public nsISupports
{
30 NS_DECLARE_STATIC_IID_ACCESSOR(IDNSSDBROWSELISTENER_IID
)
32 /* void onBrowse (in IDNSSDService service, in boolean add, in long interfaceIndex, in long error, in AString serviceName, in AString regtype, in AString domain); */
33 NS_SCRIPTABLE NS_IMETHOD
OnBrowse(IDNSSDService
*service
, PRBool add
, PRInt32 interfaceIndex
, PRInt32 error
, const nsAString
& serviceName
, const nsAString
& regtype
, const nsAString
& domain
) = 0;
37 NS_DEFINE_STATIC_IID_ACCESSOR(IDNSSDBrowseListener
, IDNSSDBROWSELISTENER_IID
)
39 /* Use this macro when declaring classes that implement this interface. */
40 #define NS_DECL_IDNSSDBROWSELISTENER \
41 NS_SCRIPTABLE NS_IMETHOD OnBrowse(IDNSSDService *service, PRBool add, PRInt32 interfaceIndex, PRInt32 error, const nsAString &serviceName, const nsAString ®type, const nsAString &domain);
43 /* Use this macro to declare functions that forward the behavior of this interface to another object. */
44 #define NS_FORWARD_IDNSSDBROWSELISTENER(_to) \
45 NS_SCRIPTABLE NS_IMETHOD OnBrowse(IDNSSDService *service, PRBool add, PRInt32 interfaceIndex, PRInt32 error, const nsAString &serviceName, const nsAString ®type, const nsAString &domain) { return _to OnBrowse(service, add, interfaceIndex, error, serviceName, regtype, domain); }
47 /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
48 #define NS_FORWARD_SAFE_IDNSSDBROWSELISTENER(_to) \
49 NS_SCRIPTABLE NS_IMETHOD OnBrowse(IDNSSDService *service, PRBool add, PRInt32 interfaceIndex, PRInt32 error, const nsAString &serviceName, const nsAString ®type, const nsAString &domain) { return !_to ? NS_ERROR_NULL_POINTER : _to->OnBrowse(service, add, interfaceIndex, error, serviceName, regtype, domain); }
52 /* Use the code below as a template for the implementation class for this interface. */
55 class _MYCLASS_
: public IDNSSDBrowseListener
59 NS_DECL_IDNSSDBROWSELISTENER
67 /* additional members */
70 /* Implementation file */
71 NS_IMPL_ISUPPORTS1(_MYCLASS_
, IDNSSDBrowseListener
)
73 _MYCLASS_::_MYCLASS_()
75 /* member initializers and constructor code */
78 _MYCLASS_::~_MYCLASS_()
83 /* void onBrowse (in IDNSSDService service, in boolean add, in long interfaceIndex, in long error, in AString serviceName, in AString regtype, in AString domain); */
84 NS_IMETHODIMP
_MYCLASS_::OnBrowse(IDNSSDService
*service
, PRBool add
, PRInt32 interfaceIndex
, PRInt32 error
, const nsAString
& serviceName
, const nsAString
& regtype
, const nsAString
& domain
)
86 return NS_ERROR_NOT_IMPLEMENTED
;
89 /* End of implementation class template. */
93 /* starting interface: IDNSSDResolveListener */
94 #define IDNSSDRESOLVELISTENER_IID_STR "6620e18f-47f3-47c6-941f-126a5fd4fcf7"
96 #define IDNSSDRESOLVELISTENER_IID \
97 {0x6620e18f, 0x47f3, 0x47c6, \
98 { 0x94, 0x1f, 0x12, 0x6a, 0x5f, 0xd4, 0xfc, 0xf7 }}
100 class NS_NO_VTABLE NS_SCRIPTABLE IDNSSDResolveListener
: public nsISupports
{
103 NS_DECLARE_STATIC_IID_ACCESSOR(IDNSSDRESOLVELISTENER_IID
)
105 /* void onResolve (in IDNSSDService service, in long interfaceIndex, in long error, in AString fullname, in AString host, in short port, in AString path); */
106 NS_SCRIPTABLE NS_IMETHOD
OnResolve(IDNSSDService
*service
, PRInt32 interfaceIndex
, PRInt32 error
, const nsAString
& fullname
, const nsAString
& host
, PRInt16 port
, const nsAString
& path
) = 0;
110 NS_DEFINE_STATIC_IID_ACCESSOR(IDNSSDResolveListener
, IDNSSDRESOLVELISTENER_IID
)
112 /* Use this macro when declaring classes that implement this interface. */
113 #define NS_DECL_IDNSSDRESOLVELISTENER \
114 NS_SCRIPTABLE NS_IMETHOD OnResolve(IDNSSDService *service, PRInt32 interfaceIndex, PRInt32 error, const nsAString &fullname, const nsAString &host, PRInt16 port, const nsAString &path);
116 /* Use this macro to declare functions that forward the behavior of this interface to another object. */
117 #define NS_FORWARD_IDNSSDRESOLVELISTENER(_to) \
118 NS_SCRIPTABLE NS_IMETHOD OnResolve(IDNSSDService *service, PRInt32 interfaceIndex, PRInt32 error, const nsAString &fullname, const nsAString &host, PRInt16 port, const nsAString &path) { return _to OnResolve(service, interfaceIndex, error, fullname, host, port, path); }
120 /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
121 #define NS_FORWARD_SAFE_IDNSSDRESOLVELISTENER(_to) \
122 NS_SCRIPTABLE NS_IMETHOD OnResolve(IDNSSDService *service, PRInt32 interfaceIndex, PRInt32 error, const nsAString &fullname, const nsAString &host, PRInt16 port, const nsAString &path) { return !_to ? NS_ERROR_NULL_POINTER : _to->OnResolve(service, interfaceIndex, error, fullname, host, port, path); }
125 /* Use the code below as a template for the implementation class for this interface. */
128 class _MYCLASS_
: public IDNSSDResolveListener
132 NS_DECL_IDNSSDRESOLVELISTENER
140 /* additional members */
143 /* Implementation file */
144 NS_IMPL_ISUPPORTS1(_MYCLASS_
, IDNSSDResolveListener
)
146 _MYCLASS_::_MYCLASS_()
148 /* member initializers and constructor code */
151 _MYCLASS_::~_MYCLASS_()
153 /* destructor code */
156 /* void onResolve (in IDNSSDService service, in long interfaceIndex, in long error, in AString fullname, in AString host, in short port, in AString path); */
157 NS_IMETHODIMP
_MYCLASS_::OnResolve(IDNSSDService
*service
, PRInt32 interfaceIndex
, PRInt32 error
, const nsAString
& fullname
, const nsAString
& host
, PRInt16 port
, const nsAString
& path
)
159 return NS_ERROR_NOT_IMPLEMENTED
;
162 /* End of implementation class template. */
166 /* starting interface: IDNSSDService */
167 #define IDNSSDSERVICE_IID_STR "3a3539ff-f8d8-40b4-8d02-5ea73c51fa12"
169 #define IDNSSDSERVICE_IID \
170 {0x3a3539ff, 0xf8d8, 0x40b4, \
171 { 0x8d, 0x02, 0x5e, 0xa7, 0x3c, 0x51, 0xfa, 0x12 }}
173 class NS_NO_VTABLE NS_SCRIPTABLE IDNSSDService
: public nsISupports
{
176 NS_DECLARE_STATIC_IID_ACCESSOR(IDNSSDSERVICE_IID
)
178 /* IDNSSDService browse (in long interfaceIndex, in AString regtype, in AString domain, in IDNSSDBrowseListener listener); */
179 NS_SCRIPTABLE NS_IMETHOD
Browse(PRInt32 interfaceIndex
, const nsAString
& regtype
, const nsAString
& domain
, IDNSSDBrowseListener
*listener
, IDNSSDService
**_retval NS_OUTPARAM
) = 0;
181 /* IDNSSDService resolve (in long interfaceIndex, in AString name, in AString regtype, in AString domain, in IDNSSDResolveListener listener); */
182 NS_SCRIPTABLE NS_IMETHOD
Resolve(PRInt32 interfaceIndex
, const nsAString
& name
, const nsAString
& regtype
, const nsAString
& domain
, IDNSSDResolveListener
*listener
, IDNSSDService
**_retval NS_OUTPARAM
) = 0;
185 NS_SCRIPTABLE NS_IMETHOD
Stop(void) = 0;
189 NS_DEFINE_STATIC_IID_ACCESSOR(IDNSSDService
, IDNSSDSERVICE_IID
)
191 /* Use this macro when declaring classes that implement this interface. */
192 #define NS_DECL_IDNSSDSERVICE \
193 NS_SCRIPTABLE NS_IMETHOD Browse(PRInt32 interfaceIndex, const nsAString ®type, const nsAString &domain, IDNSSDBrowseListener *listener, IDNSSDService **_retval NS_OUTPARAM); \
194 NS_SCRIPTABLE NS_IMETHOD Resolve(PRInt32 interfaceIndex, const nsAString &name, const nsAString ®type, const nsAString &domain, IDNSSDResolveListener *listener, IDNSSDService **_retval NS_OUTPARAM); \
195 NS_SCRIPTABLE NS_IMETHOD Stop(void);
197 /* Use this macro to declare functions that forward the behavior of this interface to another object. */
198 #define NS_FORWARD_IDNSSDSERVICE(_to) \
199 NS_SCRIPTABLE NS_IMETHOD Browse(PRInt32 interfaceIndex, const nsAString ®type, const nsAString &domain, IDNSSDBrowseListener *listener, IDNSSDService **_retval NS_OUTPARAM) { return _to Browse(interfaceIndex, regtype, domain, listener, _retval); } \
200 NS_SCRIPTABLE NS_IMETHOD Resolve(PRInt32 interfaceIndex, const nsAString &name, const nsAString ®type, const nsAString &domain, IDNSSDResolveListener *listener, IDNSSDService **_retval NS_OUTPARAM) { return _to Resolve(interfaceIndex, name, regtype, domain, listener, _retval); } \
201 NS_SCRIPTABLE NS_IMETHOD Stop(void) { return _to Stop(); }
203 /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
204 #define NS_FORWARD_SAFE_IDNSSDSERVICE(_to) \
205 NS_SCRIPTABLE NS_IMETHOD Browse(PRInt32 interfaceIndex, const nsAString ®type, const nsAString &domain, IDNSSDBrowseListener *listener, IDNSSDService **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Browse(interfaceIndex, regtype, domain, listener, _retval); } \
206 NS_SCRIPTABLE NS_IMETHOD Resolve(PRInt32 interfaceIndex, const nsAString &name, const nsAString ®type, const nsAString &domain, IDNSSDResolveListener *listener, IDNSSDService **_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Resolve(interfaceIndex, name, regtype, domain, listener, _retval); } \
207 NS_SCRIPTABLE NS_IMETHOD Stop(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->Stop(); }
210 /* Use the code below as a template for the implementation class for this interface. */
213 class _MYCLASS_
: public IDNSSDService
217 NS_DECL_IDNSSDSERVICE
225 /* additional members */
228 /* Implementation file */
229 NS_IMPL_ISUPPORTS1(_MYCLASS_
, IDNSSDService
)
231 _MYCLASS_::_MYCLASS_()
233 /* member initializers and constructor code */
236 _MYCLASS_::~_MYCLASS_()
238 /* destructor code */
241 /* IDNSSDService browse (in long interfaceIndex, in AString regtype, in AString domain, in IDNSSDBrowseListener listener); */
242 NS_IMETHODIMP
_MYCLASS_::Browse(PRInt32 interfaceIndex
, const nsAString
& regtype
, const nsAString
& domain
, IDNSSDBrowseListener
*listener
, IDNSSDService
**_retval NS_OUTPARAM
)
244 return NS_ERROR_NOT_IMPLEMENTED
;
247 /* IDNSSDService resolve (in long interfaceIndex, in AString name, in AString regtype, in AString domain, in IDNSSDResolveListener listener); */
248 NS_IMETHODIMP
_MYCLASS_::Resolve(PRInt32 interfaceIndex
, const nsAString
& name
, const nsAString
& regtype
, const nsAString
& domain
, IDNSSDResolveListener
*listener
, IDNSSDService
**_retval NS_OUTPARAM
)
250 return NS_ERROR_NOT_IMPLEMENTED
;
254 NS_IMETHODIMP
_MYCLASS_::Stop()
256 return NS_ERROR_NOT_IMPLEMENTED
;
259 /* End of implementation class template. */
263 #endif /* __gen_IDNSSDService_h__ */