/usr/include/thunderbird/nsITimer.h is in thunderbird-dev 1:52.8.0-1~deb8u1.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 | /*
* DO NOT EDIT. THIS FILE IS GENERATED FROM ../../../dist/idl/nsITimer.idl
*/
#ifndef __gen_nsITimer_h__
#define __gen_nsITimer_h__
#ifndef __gen_nsISupports_h__
#include "nsISupports.h"
#endif
/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIObserver; /* forward declaration */
class nsIEventTarget; /* forward declaration */
#include "mozilla/MemoryReporting.h"
/**
* The signature of the timer callback function passed to initWithFuncCallback.
* This is the function that will get called when the timer expires if the
* timer is initialized via initWithFuncCallback.
*
* @param aTimer the timer which has expired
* @param aClosure opaque parameter passed to initWithFuncCallback
*/
class nsITimer;
typedef void (*nsTimerCallbackFunc) (nsITimer *aTimer, void *aClosure);
/**
* The signature of the timer name callback function passed to
* initWithNameableFuncCallback.
* This is the function that will get called when timer profiling is enabled
* via the "TimerFirings" log module.
*
* @param aTimer the timer which has expired
* @param aClosure opaque parameter passed to initWithFuncCallback
* @param aBuf a buffer in which to put the name
* @param aLen the length of the buffer
*/
typedef void (*nsTimerNameCallbackFunc) (nsITimer *aTimer, void *aClosure,
char *aBuf, size_t aLen);
class nsITimer; /* forward declaration */
/* starting interface: nsITimerCallback */
#define NS_ITIMERCALLBACK_IID_STR "a796816d-7d47-4348-9ab8-c7aeb3216a7d"
#define NS_ITIMERCALLBACK_IID \
{0xa796816d, 0x7d47, 0x4348, \
{ 0x9a, 0xb8, 0xc7, 0xae, 0xb3, 0x21, 0x6a, 0x7d }}
class NS_NO_VTABLE nsITimerCallback : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_ITIMERCALLBACK_IID)
/* void notify (in nsITimer timer); */
NS_IMETHOD Notify(nsITimer *timer) = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsITimerCallback, NS_ITIMERCALLBACK_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSITIMERCALLBACK \
NS_IMETHOD Notify(nsITimer *timer) override;
/* Use this macro when declaring the members of this interface when the
class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_NSITIMERCALLBACK \
NS_METHOD Notify(nsITimer *timer);
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSITIMERCALLBACK(_to) \
NS_IMETHOD Notify(nsITimer *timer) override { return _to Notify(timer); }
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSITIMERCALLBACK(_to) \
NS_IMETHOD Notify(nsITimer *timer) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Notify(timer); }
#if 0
/* Use the code below as a template for the implementation class for this interface. */
/* Header file */
class nsTimerCallback : public nsITimerCallback
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSITIMERCALLBACK
nsTimerCallback();
private:
~nsTimerCallback();
protected:
/* additional members */
};
/* Implementation file */
NS_IMPL_ISUPPORTS(nsTimerCallback, nsITimerCallback)
nsTimerCallback::nsTimerCallback()
{
/* member initializers and constructor code */
}
nsTimerCallback::~nsTimerCallback()
{
/* destructor code */
}
/* void notify (in nsITimer timer); */
NS_IMETHODIMP nsTimerCallback::Notify(nsITimer *timer)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* End of implementation class template. */
#endif
// Two timer deadlines must differ by less than half the PRIntervalTime domain.
#define DELAY_INTERVAL_LIMIT PR_BIT(8 * sizeof(PRIntervalTime) - 1)
/* starting interface: nsITimer */
#define NS_ITIMER_IID_STR "3de4b105-363c-482c-a409-baac83a01bfc"
#define NS_ITIMER_IID \
{0x3de4b105, 0x363c, 0x482c, \
{ 0xa4, 0x09, 0xba, 0xac, 0x83, 0xa0, 0x1b, 0xfc }}
class nsITimer : public nsISupports {
public:
NS_DECLARE_STATIC_IID_ACCESSOR(NS_ITIMER_IID)
enum {
TYPE_ONE_SHOT = 0,
TYPE_REPEATING_SLACK = 1,
TYPE_REPEATING_PRECISE = 2,
TYPE_REPEATING_PRECISE_CAN_SKIP = 3
};
/* void init (in nsIObserver aObserver, in unsigned long aDelay, in unsigned long aType); */
NS_IMETHOD Init(nsIObserver *aObserver, uint32_t aDelay, uint32_t aType) = 0;
/* [noscript] void initWithFuncCallback (in nsTimerCallbackFunc aCallback, in voidPtr aClosure, in unsigned long aDelay, in unsigned long aType); */
NS_IMETHOD InitWithFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType) = 0;
/* void initWithCallback (in nsITimerCallback aCallback, in unsigned long aDelay, in unsigned long aType); */
NS_IMETHOD InitWithCallback(nsITimerCallback *aCallback, uint32_t aDelay, uint32_t aType) = 0;
/* void cancel (); */
NS_IMETHOD Cancel(void) = 0;
/* [noscript] void initWithNamedFuncCallback (in nsTimerCallbackFunc aCallback, in voidPtr aClosure, in unsigned long aDelay, in unsigned long aType, in string aName); */
NS_IMETHOD InitWithNamedFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, const char * aName) = 0;
/* [noscript] void initWithNameableFuncCallback (in nsTimerCallbackFunc aCallback, in voidPtr aClosure, in unsigned long aDelay, in unsigned long aType, in nsTimerNameCallbackFunc aNameCallback); */
NS_IMETHOD InitWithNameableFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, nsTimerNameCallbackFunc aNameCallback) = 0;
/* attribute unsigned long delay; */
NS_IMETHOD GetDelay(uint32_t *aDelay) = 0;
NS_IMETHOD SetDelay(uint32_t aDelay) = 0;
/* attribute unsigned long type; */
NS_IMETHOD GetType(uint32_t *aType) = 0;
NS_IMETHOD SetType(uint32_t aType) = 0;
/* [noscript] readonly attribute voidPtr closure; */
NS_IMETHOD GetClosure(void **aClosure) = 0;
/* readonly attribute nsITimerCallback callback; */
NS_IMETHOD GetCallback(nsITimerCallback * *aCallback) = 0;
/* attribute nsIEventTarget target; */
NS_IMETHOD GetTarget(nsIEventTarget * *aTarget) = 0;
NS_IMETHOD SetTarget(nsIEventTarget *aTarget) = 0;
virtual size_t SizeOfIncludingThis(mozilla::MallocSizeOf aMallocSizeOf) const = 0;
};
NS_DEFINE_STATIC_IID_ACCESSOR(nsITimer, NS_ITIMER_IID)
/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSITIMER \
NS_IMETHOD Init(nsIObserver *aObserver, uint32_t aDelay, uint32_t aType) override; \
NS_IMETHOD InitWithFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType) override; \
NS_IMETHOD InitWithCallback(nsITimerCallback *aCallback, uint32_t aDelay, uint32_t aType) override; \
NS_IMETHOD Cancel(void) override; \
NS_IMETHOD InitWithNamedFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, const char * aName) override; \
NS_IMETHOD InitWithNameableFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, nsTimerNameCallbackFunc aNameCallback) override; \
NS_IMETHOD GetDelay(uint32_t *aDelay) override; \
NS_IMETHOD SetDelay(uint32_t aDelay) override; \
NS_IMETHOD GetType(uint32_t *aType) override; \
NS_IMETHOD SetType(uint32_t aType) override; \
NS_IMETHOD GetClosure(void **aClosure) override; \
NS_IMETHOD GetCallback(nsITimerCallback * *aCallback) override; \
NS_IMETHOD GetTarget(nsIEventTarget * *aTarget) override; \
NS_IMETHOD SetTarget(nsIEventTarget *aTarget) override; \
/* Use this macro when declaring the members of this interface when the
class doesn't implement the interface. This is useful for forwarding. */
#define NS_DECL_NON_VIRTUAL_NSITIMER \
NS_METHOD Init(nsIObserver *aObserver, uint32_t aDelay, uint32_t aType); \
NS_METHOD InitWithFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType); \
NS_METHOD InitWithCallback(nsITimerCallback *aCallback, uint32_t aDelay, uint32_t aType); \
NS_METHOD Cancel(void); \
NS_METHOD InitWithNamedFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, const char * aName); \
NS_METHOD InitWithNameableFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, nsTimerNameCallbackFunc aNameCallback); \
NS_METHOD GetDelay(uint32_t *aDelay); \
NS_METHOD SetDelay(uint32_t aDelay); \
NS_METHOD GetType(uint32_t *aType); \
NS_METHOD SetType(uint32_t aType); \
NS_METHOD GetClosure(void **aClosure); \
NS_METHOD GetCallback(nsITimerCallback * *aCallback); \
NS_METHOD GetTarget(nsIEventTarget * *aTarget); \
NS_METHOD SetTarget(nsIEventTarget *aTarget); \
/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSITIMER(_to) \
NS_IMETHOD Init(nsIObserver *aObserver, uint32_t aDelay, uint32_t aType) override { return _to Init(aObserver, aDelay, aType); } \
NS_IMETHOD InitWithFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType) override { return _to InitWithFuncCallback(aCallback, aClosure, aDelay, aType); } \
NS_IMETHOD InitWithCallback(nsITimerCallback *aCallback, uint32_t aDelay, uint32_t aType) override { return _to InitWithCallback(aCallback, aDelay, aType); } \
NS_IMETHOD Cancel(void) override { return _to Cancel(); } \
NS_IMETHOD InitWithNamedFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, const char * aName) override { return _to InitWithNamedFuncCallback(aCallback, aClosure, aDelay, aType, aName); } \
NS_IMETHOD InitWithNameableFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, nsTimerNameCallbackFunc aNameCallback) override { return _to InitWithNameableFuncCallback(aCallback, aClosure, aDelay, aType, aNameCallback); } \
NS_IMETHOD GetDelay(uint32_t *aDelay) override { return _to GetDelay(aDelay); } \
NS_IMETHOD SetDelay(uint32_t aDelay) override { return _to SetDelay(aDelay); } \
NS_IMETHOD GetType(uint32_t *aType) override { return _to GetType(aType); } \
NS_IMETHOD SetType(uint32_t aType) override { return _to SetType(aType); } \
NS_IMETHOD GetClosure(void **aClosure) override { return _to GetClosure(aClosure); } \
NS_IMETHOD GetCallback(nsITimerCallback * *aCallback) override { return _to GetCallback(aCallback); } \
NS_IMETHOD GetTarget(nsIEventTarget * *aTarget) override { return _to GetTarget(aTarget); } \
NS_IMETHOD SetTarget(nsIEventTarget *aTarget) override { return _to SetTarget(aTarget); } \
/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSITIMER(_to) \
NS_IMETHOD Init(nsIObserver *aObserver, uint32_t aDelay, uint32_t aType) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Init(aObserver, aDelay, aType); } \
NS_IMETHOD InitWithFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType) override { return !_to ? NS_ERROR_NULL_POINTER : _to->InitWithFuncCallback(aCallback, aClosure, aDelay, aType); } \
NS_IMETHOD InitWithCallback(nsITimerCallback *aCallback, uint32_t aDelay, uint32_t aType) override { return !_to ? NS_ERROR_NULL_POINTER : _to->InitWithCallback(aCallback, aDelay, aType); } \
NS_IMETHOD Cancel(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Cancel(); } \
NS_IMETHOD InitWithNamedFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, const char * aName) override { return !_to ? NS_ERROR_NULL_POINTER : _to->InitWithNamedFuncCallback(aCallback, aClosure, aDelay, aType, aName); } \
NS_IMETHOD InitWithNameableFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, nsTimerNameCallbackFunc aNameCallback) override { return !_to ? NS_ERROR_NULL_POINTER : _to->InitWithNameableFuncCallback(aCallback, aClosure, aDelay, aType, aNameCallback); } \
NS_IMETHOD GetDelay(uint32_t *aDelay) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDelay(aDelay); } \
NS_IMETHOD SetDelay(uint32_t aDelay) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetDelay(aDelay); } \
NS_IMETHOD GetType(uint32_t *aType) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetType(aType); } \
NS_IMETHOD SetType(uint32_t aType) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetType(aType); } \
NS_IMETHOD GetClosure(void **aClosure) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetClosure(aClosure); } \
NS_IMETHOD GetCallback(nsITimerCallback * *aCallback) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetCallback(aCallback); } \
NS_IMETHOD GetTarget(nsIEventTarget * *aTarget) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTarget(aTarget); } \
NS_IMETHOD SetTarget(nsIEventTarget *aTarget) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetTarget(aTarget); } \
#if 0
/* Use the code below as a template for the implementation class for this interface. */
/* Header file */
class nsTimer : public nsITimer
{
public:
NS_DECL_ISUPPORTS
NS_DECL_NSITIMER
nsTimer();
private:
~nsTimer();
protected:
/* additional members */
};
/* Implementation file */
NS_IMPL_ISUPPORTS(nsTimer, nsITimer)
nsTimer::nsTimer()
{
/* member initializers and constructor code */
}
nsTimer::~nsTimer()
{
/* destructor code */
}
/* void init (in nsIObserver aObserver, in unsigned long aDelay, in unsigned long aType); */
NS_IMETHODIMP nsTimer::Init(nsIObserver *aObserver, uint32_t aDelay, uint32_t aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* [noscript] void initWithFuncCallback (in nsTimerCallbackFunc aCallback, in voidPtr aClosure, in unsigned long aDelay, in unsigned long aType); */
NS_IMETHODIMP nsTimer::InitWithFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* void initWithCallback (in nsITimerCallback aCallback, in unsigned long aDelay, in unsigned long aType); */
NS_IMETHODIMP nsTimer::InitWithCallback(nsITimerCallback *aCallback, uint32_t aDelay, uint32_t aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* void cancel (); */
NS_IMETHODIMP nsTimer::Cancel()
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* [noscript] void initWithNamedFuncCallback (in nsTimerCallbackFunc aCallback, in voidPtr aClosure, in unsigned long aDelay, in unsigned long aType, in string aName); */
NS_IMETHODIMP nsTimer::InitWithNamedFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, const char * aName)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* [noscript] void initWithNameableFuncCallback (in nsTimerCallbackFunc aCallback, in voidPtr aClosure, in unsigned long aDelay, in unsigned long aType, in nsTimerNameCallbackFunc aNameCallback); */
NS_IMETHODIMP nsTimer::InitWithNameableFuncCallback(nsTimerCallbackFunc aCallback, void *aClosure, uint32_t aDelay, uint32_t aType, nsTimerNameCallbackFunc aNameCallback)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* attribute unsigned long delay; */
NS_IMETHODIMP nsTimer::GetDelay(uint32_t *aDelay)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsTimer::SetDelay(uint32_t aDelay)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* attribute unsigned long type; */
NS_IMETHODIMP nsTimer::GetType(uint32_t *aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsTimer::SetType(uint32_t aType)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* [noscript] readonly attribute voidPtr closure; */
NS_IMETHODIMP nsTimer::GetClosure(void **aClosure)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* readonly attribute nsITimerCallback callback; */
NS_IMETHODIMP nsTimer::GetCallback(nsITimerCallback * *aCallback)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* attribute nsIEventTarget target; */
NS_IMETHODIMP nsTimer::GetTarget(nsIEventTarget * *aTarget)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsTimer::SetTarget(nsIEventTarget *aTarget)
{
return NS_ERROR_NOT_IMPLEMENTED;
}
/* End of implementation class template. */
#endif
#define NS_TIMER_CONTRACTID "@mozilla.org/timer;1"
#define NS_TIMER_CALLBACK_TOPIC "timer-callback"
#endif /* __gen_nsITimer_h__ */
|