DXR is a code search and navigation tool aimed at making sense of large projects. It supports full-text and regex searches as well as structural queries.

Untracked file

Line Code
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
/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM /home/jenkins/src/releases/comm-beta/mailnews/base/search/public/nsIMsgFilterPlugin.idl
 */

#ifndef __gen_nsIMsgFilterPlugin_h__
#define __gen_nsIMsgFilterPlugin_h__


#ifndef __gen_nsISupports_h__
#include "nsISupports.h"
#endif

#ifndef __gen_MailNewsTypes2_h__
#include "MailNewsTypes2.h"
#endif

#include "js/GCAnnotations.h"

/* For IDL files that don't want to include root IDL files. */
#ifndef NS_NO_VTABLE
#define NS_NO_VTABLE
#endif
class nsIMsgWindow; /* forward declaration */

class nsIFile; /* forward declaration */


/* starting interface:    nsIMsgFilterPlugin */
#define NS_IMSGFILTERPLUGIN_IID_STR "e2e56690-a676-11d6-80c9-00008646b737"

#define NS_IMSGFILTERPLUGIN_IID \
  {0xe2e56690, 0xa676, 0x11d6, \
    { 0x80, 0xc9, 0x00, 0x00, 0x86, 0x46, 0xb7, 0x37 }}

class NS_NO_VTABLE nsIMsgFilterPlugin : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGFILTERPLUGIN_IID)

  /* void shutdown (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD Shutdown(void) = 0;

  /* readonly attribute boolean shouldDownloadAllHeaders; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetShouldDownloadAllHeaders(bool *aShouldDownloadAllHeaders) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgFilterPlugin, NS_IMSGFILTERPLUGIN_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGFILTERPLUGIN \
  NS_IMETHOD Shutdown(void) override; \
  NS_IMETHOD GetShouldDownloadAllHeaders(bool *aShouldDownloadAllHeaders) 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_NSIMSGFILTERPLUGIN \
  nsresult Shutdown(void); \
  nsresult GetShouldDownloadAllHeaders(bool *aShouldDownloadAllHeaders); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGFILTERPLUGIN(_to) \
  NS_IMETHOD Shutdown(void) override { return _to Shutdown(); } \
  NS_IMETHOD GetShouldDownloadAllHeaders(bool *aShouldDownloadAllHeaders) override { return _to GetShouldDownloadAllHeaders(aShouldDownloadAllHeaders); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIMSGFILTERPLUGIN(_to) \
  NS_IMETHOD Shutdown(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->Shutdown(); } \
  NS_IMETHOD GetShouldDownloadAllHeaders(bool *aShouldDownloadAllHeaders) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetShouldDownloadAllHeaders(aShouldDownloadAllHeaders); } 


/* starting interface:    nsIJunkMailClassificationListener */
#define NS_IJUNKMAILCLASSIFICATIONLISTENER_IID_STR "b15a0f9c-df07-4af0-9ba8-80dca68ac35d"

#define NS_IJUNKMAILCLASSIFICATIONLISTENER_IID \
  {0xb15a0f9c, 0xdf07, 0x4af0, \
    { 0x9b, 0xa8, 0x80, 0xdc, 0xa6, 0x8a, 0xc3, 0x5d }}

class NS_NO_VTABLE nsIJunkMailClassificationListener : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IJUNKMAILCLASSIFICATIONLISTENER_IID)

  /* void onMessageClassified (in string aMsgURI, in nsMsgJunkStatus aClassification, in uint32_t aJunkPercent); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OnMessageClassified(const char * aMsgURI, nsMsgJunkStatus aClassification, uint32_t aJunkPercent) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIJunkMailClassificationListener, NS_IJUNKMAILCLASSIFICATIONLISTENER_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIJUNKMAILCLASSIFICATIONLISTENER \
  NS_IMETHOD OnMessageClassified(const char * aMsgURI, nsMsgJunkStatus aClassification, uint32_t aJunkPercent) 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_NSIJUNKMAILCLASSIFICATIONLISTENER \
  nsresult OnMessageClassified(const char * aMsgURI, nsMsgJunkStatus aClassification, uint32_t aJunkPercent); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIJUNKMAILCLASSIFICATIONLISTENER(_to) \
  NS_IMETHOD OnMessageClassified(const char * aMsgURI, nsMsgJunkStatus aClassification, uint32_t aJunkPercent) override { return _to OnMessageClassified(aMsgURI, aClassification, aJunkPercent); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIJUNKMAILCLASSIFICATIONLISTENER(_to) \
  NS_IMETHOD OnMessageClassified(const char * aMsgURI, nsMsgJunkStatus aClassification, uint32_t aJunkPercent) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OnMessageClassified(aMsgURI, aClassification, aJunkPercent); } 


/* starting interface:    nsIMsgTraitClassificationListener */
#define NS_IMSGTRAITCLASSIFICATIONLISTENER_IID_STR "af247d07-72f0-482d-9eab-5a786407aa4c"

#define NS_IMSGTRAITCLASSIFICATIONLISTENER_IID \
  {0xaf247d07, 0x72f0, 0x482d, \
    { 0x9e, 0xab, 0x5a, 0x78, 0x64, 0x07, 0xaa, 0x4c }}

class NS_NO_VTABLE nsIMsgTraitClassificationListener : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGTRAITCLASSIFICATIONLISTENER_IID)

  /* void onMessageTraitsClassified (in string aMsgURI, in unsigned long aTraitCount, [array, size_is (aTraitCount)] in unsigned long aTraits, [array, size_is (aTraitCount)] in unsigned long aPercents); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OnMessageTraitsClassified(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aTraits, uint32_t *aPercents) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgTraitClassificationListener, NS_IMSGTRAITCLASSIFICATIONLISTENER_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGTRAITCLASSIFICATIONLISTENER \
  NS_IMETHOD OnMessageTraitsClassified(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aTraits, uint32_t *aPercents) 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_NSIMSGTRAITCLASSIFICATIONLISTENER \
  nsresult OnMessageTraitsClassified(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aTraits, uint32_t *aPercents); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGTRAITCLASSIFICATIONLISTENER(_to) \
  NS_IMETHOD OnMessageTraitsClassified(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aTraits, uint32_t *aPercents) override { return _to OnMessageTraitsClassified(aMsgURI, aTraitCount, aTraits, aPercents); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIMSGTRAITCLASSIFICATIONLISTENER(_to) \
  NS_IMETHOD OnMessageTraitsClassified(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aTraits, uint32_t *aPercents) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OnMessageTraitsClassified(aMsgURI, aTraitCount, aTraits, aPercents); } 


/* starting interface:    nsIMsgTraitDetailListener */
#define NS_IMSGTRAITDETAILLISTENER_IID_STR "12667532-88d1-44a7-ad48-f73719be5c92"

#define NS_IMSGTRAITDETAILLISTENER_IID \
  {0x12667532, 0x88d1, 0x44a7, \
    { 0xad, 0x48, 0xf7, 0x37, 0x19, 0xbe, 0x5c, 0x92 }}

class NS_NO_VTABLE nsIMsgTraitDetailListener : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGTRAITDETAILLISTENER_IID)

  /* void onMessageTraitDetails (in string aMsgUri, in unsigned long aProTrait, in unsigned long tokenCount, [array, size_is (tokenCount)] in wstring tokenStrings, [array, size_is (tokenCount)] in unsigned long tokenPercents, [array, size_is (tokenCount)] in unsigned long runningPercents); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD OnMessageTraitDetails(const char * aMsgUri, uint32_t aProTrait, uint32_t tokenCount, const char16_t * *tokenStrings, uint32_t *tokenPercents, uint32_t *runningPercents) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgTraitDetailListener, NS_IMSGTRAITDETAILLISTENER_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGTRAITDETAILLISTENER \
  NS_IMETHOD OnMessageTraitDetails(const char * aMsgUri, uint32_t aProTrait, uint32_t tokenCount, const char16_t * *tokenStrings, uint32_t *tokenPercents, uint32_t *runningPercents) 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_NSIMSGTRAITDETAILLISTENER \
  nsresult OnMessageTraitDetails(const char * aMsgUri, uint32_t aProTrait, uint32_t tokenCount, const char16_t * *tokenStrings, uint32_t *tokenPercents, uint32_t *runningPercents); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGTRAITDETAILLISTENER(_to) \
  NS_IMETHOD OnMessageTraitDetails(const char * aMsgUri, uint32_t aProTrait, uint32_t tokenCount, const char16_t * *tokenStrings, uint32_t *tokenPercents, uint32_t *runningPercents) override { return _to OnMessageTraitDetails(aMsgUri, aProTrait, tokenCount, tokenStrings, tokenPercents, runningPercents); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIMSGTRAITDETAILLISTENER(_to) \
  NS_IMETHOD OnMessageTraitDetails(const char * aMsgUri, uint32_t aProTrait, uint32_t tokenCount, const char16_t * *tokenStrings, uint32_t *tokenPercents, uint32_t *runningPercents) override { return !_to ? NS_ERROR_NULL_POINTER : _to->OnMessageTraitDetails(aMsgUri, aProTrait, tokenCount, tokenStrings, tokenPercents, runningPercents); } 


/* starting interface:    nsIJunkMailPlugin */
#define NS_IJUNKMAILPLUGIN_IID_STR "8ea5bbca-f735-4d43-8541-d203d8e2ff2f"

#define NS_IJUNKMAILPLUGIN_IID \
  {0x8ea5bbca, 0xf735, 0x4d43, \
    { 0x85, 0x41, 0xd2, 0x03, 0xd8, 0xe2, 0xff, 0x2f }}

class NS_NO_VTABLE nsIJunkMailPlugin : public nsIMsgFilterPlugin {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IJUNKMAILPLUGIN_IID)

  enum {
    UNCLASSIFIED = 0U,
    GOOD = 1U,
    JUNK = 2U,
    IS_SPAM_SCORE = 100U,
    IS_HAM_SCORE = 0U,
    GOOD_TRAIT = 1U,
    JUNK_TRAIT = 2U
  };

  /* void classifyMessage (in string aMsgURI, in nsIMsgWindow aMsgWindow, in nsIJunkMailClassificationListener aListener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ClassifyMessage(const char * aMsgURI, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) = 0;

  /* void classifyMessages (in unsigned long aCount, [array, size_is (aCount)] in string aMsgURIs, in nsIMsgWindow aMsgWindow, in nsIJunkMailClassificationListener aListener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ClassifyMessages(uint32_t aCount, const char * *aMsgURIs, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) = 0;

  /* void classifyTraitsInMessage (in string aMsgURI, in unsigned long aTraitCount, [array, size_is (aTraitCount)] in unsigned long aProTraits, [array, size_is (aTraitCount)] in unsigned long aAntiTraits, in nsIMsgTraitClassificationListener aTraitListener, [optional] in nsIMsgWindow aMsgWindow, [optional] in nsIJunkMailClassificationListener aJunkListener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ClassifyTraitsInMessage(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) = 0;

  /* void classifyTraitsInMessages (in unsigned long aCount, [array, size_is (aCount)] in string aMsgURIs, in unsigned long aTraitCount, [array, size_is (aTraitCount)] in unsigned long aProTraits, [array, size_is (aTraitCount)] in unsigned long aAntiTraits, in nsIMsgTraitClassificationListener aTraitListener, [optional] in nsIMsgWindow aMsgWindow, [optional] in nsIJunkMailClassificationListener aJunkListener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ClassifyTraitsInMessages(uint32_t aCount, const char * *aMsgURIs, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) = 0;

  /* void setMessageClassification (in string aMsgURI, in nsMsgJunkStatus aOldUserClassification, in nsMsgJunkStatus aNewClassification, in nsIMsgWindow aMsgWindow, in nsIJunkMailClassificationListener aListener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetMessageClassification(const char * aMsgURI, nsMsgJunkStatus aOldUserClassification, nsMsgJunkStatus aNewClassification, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) = 0;

  /* void setMsgTraitClassification (in string aMsgURI, in unsigned long aOldCount, [array, size_is (aOldCount)] in unsigned long aOldTraits, in unsigned long aNewCount, [array, size_is (aNewCount)] in unsigned long aNewTraits, [optional] in nsIMsgTraitClassificationListener aTraitListener, [optional] in nsIMsgWindow aMsgWindow, [optional] in nsIJunkMailClassificationListener aJunkListener); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD SetMsgTraitClassification(const char * aMsgURI, uint32_t aOldCount, uint32_t *aOldTraits, uint32_t aNewCount, uint32_t *aNewTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) = 0;

  /* readonly attribute boolean userHasClassified; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetUserHasClassified(bool *aUserHasClassified) = 0;

  /* void resetTrainingData (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ResetTrainingData(void) = 0;

  /* void detailMessage (in string aMsgURI, in unsigned long aProTrait, in unsigned long aAntiTrait, in nsIMsgTraitDetailListener aListener, [optional] in nsIMsgWindow aMsgWindow); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD DetailMessage(const char * aMsgURI, uint32_t aProTrait, uint32_t aAntiTrait, nsIMsgTraitDetailListener *aListener, nsIMsgWindow *aMsgWindow) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIJunkMailPlugin, NS_IJUNKMAILPLUGIN_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIJUNKMAILPLUGIN \
  NS_IMETHOD ClassifyMessage(const char * aMsgURI, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override; \
  NS_IMETHOD ClassifyMessages(uint32_t aCount, const char * *aMsgURIs, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override; \
  NS_IMETHOD ClassifyTraitsInMessage(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override; \
  NS_IMETHOD ClassifyTraitsInMessages(uint32_t aCount, const char * *aMsgURIs, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override; \
  NS_IMETHOD SetMessageClassification(const char * aMsgURI, nsMsgJunkStatus aOldUserClassification, nsMsgJunkStatus aNewClassification, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override; \
  NS_IMETHOD SetMsgTraitClassification(const char * aMsgURI, uint32_t aOldCount, uint32_t *aOldTraits, uint32_t aNewCount, uint32_t *aNewTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override; \
  NS_IMETHOD GetUserHasClassified(bool *aUserHasClassified) override; \
  NS_IMETHOD ResetTrainingData(void) override; \
  NS_IMETHOD DetailMessage(const char * aMsgURI, uint32_t aProTrait, uint32_t aAntiTrait, nsIMsgTraitDetailListener *aListener, nsIMsgWindow *aMsgWindow) 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_NSIJUNKMAILPLUGIN \
  nsresult ClassifyMessage(const char * aMsgURI, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener); \
  nsresult ClassifyMessages(uint32_t aCount, const char * *aMsgURIs, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener); \
  nsresult ClassifyTraitsInMessage(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener); \
  nsresult ClassifyTraitsInMessages(uint32_t aCount, const char * *aMsgURIs, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener); \
  nsresult SetMessageClassification(const char * aMsgURI, nsMsgJunkStatus aOldUserClassification, nsMsgJunkStatus aNewClassification, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener); \
  nsresult SetMsgTraitClassification(const char * aMsgURI, uint32_t aOldCount, uint32_t *aOldTraits, uint32_t aNewCount, uint32_t *aNewTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener); \
  nsresult GetUserHasClassified(bool *aUserHasClassified); \
  nsresult ResetTrainingData(void); \
  nsresult DetailMessage(const char * aMsgURI, uint32_t aProTrait, uint32_t aAntiTrait, nsIMsgTraitDetailListener *aListener, nsIMsgWindow *aMsgWindow); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIJUNKMAILPLUGIN(_to) \
  NS_IMETHOD ClassifyMessage(const char * aMsgURI, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override { return _to ClassifyMessage(aMsgURI, aMsgWindow, aListener); } \
  NS_IMETHOD ClassifyMessages(uint32_t aCount, const char * *aMsgURIs, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override { return _to ClassifyMessages(aCount, aMsgURIs, aMsgWindow, aListener); } \
  NS_IMETHOD ClassifyTraitsInMessage(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override { return _to ClassifyTraitsInMessage(aMsgURI, aTraitCount, aProTraits, aAntiTraits, aTraitListener, aMsgWindow, aJunkListener); } \
  NS_IMETHOD ClassifyTraitsInMessages(uint32_t aCount, const char * *aMsgURIs, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override { return _to ClassifyTraitsInMessages(aCount, aMsgURIs, aTraitCount, aProTraits, aAntiTraits, aTraitListener, aMsgWindow, aJunkListener); } \
  NS_IMETHOD SetMessageClassification(const char * aMsgURI, nsMsgJunkStatus aOldUserClassification, nsMsgJunkStatus aNewClassification, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override { return _to SetMessageClassification(aMsgURI, aOldUserClassification, aNewClassification, aMsgWindow, aListener); } \
  NS_IMETHOD SetMsgTraitClassification(const char * aMsgURI, uint32_t aOldCount, uint32_t *aOldTraits, uint32_t aNewCount, uint32_t *aNewTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override { return _to SetMsgTraitClassification(aMsgURI, aOldCount, aOldTraits, aNewCount, aNewTraits, aTraitListener, aMsgWindow, aJunkListener); } \
  NS_IMETHOD GetUserHasClassified(bool *aUserHasClassified) override { return _to GetUserHasClassified(aUserHasClassified); } \
  NS_IMETHOD ResetTrainingData(void) override { return _to ResetTrainingData(); } \
  NS_IMETHOD DetailMessage(const char * aMsgURI, uint32_t aProTrait, uint32_t aAntiTrait, nsIMsgTraitDetailListener *aListener, nsIMsgWindow *aMsgWindow) override { return _to DetailMessage(aMsgURI, aProTrait, aAntiTrait, aListener, aMsgWindow); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIJUNKMAILPLUGIN(_to) \
  NS_IMETHOD ClassifyMessage(const char * aMsgURI, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ClassifyMessage(aMsgURI, aMsgWindow, aListener); } \
  NS_IMETHOD ClassifyMessages(uint32_t aCount, const char * *aMsgURIs, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ClassifyMessages(aCount, aMsgURIs, aMsgWindow, aListener); } \
  NS_IMETHOD ClassifyTraitsInMessage(const char * aMsgURI, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ClassifyTraitsInMessage(aMsgURI, aTraitCount, aProTraits, aAntiTraits, aTraitListener, aMsgWindow, aJunkListener); } \
  NS_IMETHOD ClassifyTraitsInMessages(uint32_t aCount, const char * *aMsgURIs, uint32_t aTraitCount, uint32_t *aProTraits, uint32_t *aAntiTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ClassifyTraitsInMessages(aCount, aMsgURIs, aTraitCount, aProTraits, aAntiTraits, aTraitListener, aMsgWindow, aJunkListener); } \
  NS_IMETHOD SetMessageClassification(const char * aMsgURI, nsMsgJunkStatus aOldUserClassification, nsMsgJunkStatus aNewClassification, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetMessageClassification(aMsgURI, aOldUserClassification, aNewClassification, aMsgWindow, aListener); } \
  NS_IMETHOD SetMsgTraitClassification(const char * aMsgURI, uint32_t aOldCount, uint32_t *aOldTraits, uint32_t aNewCount, uint32_t *aNewTraits, nsIMsgTraitClassificationListener *aTraitListener, nsIMsgWindow *aMsgWindow, nsIJunkMailClassificationListener *aJunkListener) override { return !_to ? NS_ERROR_NULL_POINTER : _to->SetMsgTraitClassification(aMsgURI, aOldCount, aOldTraits, aNewCount, aNewTraits, aTraitListener, aMsgWindow, aJunkListener); } \
  NS_IMETHOD GetUserHasClassified(bool *aUserHasClassified) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetUserHasClassified(aUserHasClassified); } \
  NS_IMETHOD ResetTrainingData(void) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ResetTrainingData(); } \
  NS_IMETHOD DetailMessage(const char * aMsgURI, uint32_t aProTrait, uint32_t aAntiTrait, nsIMsgTraitDetailListener *aListener, nsIMsgWindow *aMsgWindow) override { return !_to ? NS_ERROR_NULL_POINTER : _to->DetailMessage(aMsgURI, aProTrait, aAntiTrait, aListener, aMsgWindow); } 


/* starting interface:    nsIMsgCorpus */
#define NS_IMSGCORPUS_IID_STR "70bad26f-dfd4-41bd-8fab-4c09b9c1e845"

#define NS_IMSGCORPUS_IID \
  {0x70bad26f, 0xdfd4, 0x41bd, \
    { 0x8f, 0xab, 0x4c, 0x09, 0xb9, 0xc1, 0xe8, 0x45 }}

class NS_NO_VTABLE nsIMsgCorpus : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGCORPUS_IID)

  /* void clearTrait (in unsigned long aTrait); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ClearTrait(uint32_t aTrait) = 0;

  /* void updateData (in nsIFile aFile, in boolean aIsAdd, [optional] in unsigned long aRemapCount, [array, size_is (aRemapCount), optional] in unsigned long aFromTraits, [array, size_is (aRemapCount), optional] in unsigned long aToTraits); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD UpdateData(nsIFile *aFile, bool aIsAdd, uint32_t aRemapCount, uint32_t *aFromTraits, uint32_t *aToTraits) = 0;

  /* unsigned long getTokenCount (in AUTF8String aWord, in unsigned long aTrait); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetTokenCount(const nsACString& aWord, uint32_t aTrait, uint32_t *_retval) = 0;

  /* unsigned long corpusCounts (in unsigned long aTrait, out unsigned long aMessageCount); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD CorpusCounts(uint32_t aTrait, uint32_t *aMessageCount, uint32_t *_retval) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgCorpus, NS_IMSGCORPUS_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGCORPUS \
  NS_IMETHOD ClearTrait(uint32_t aTrait) override; \
  NS_IMETHOD UpdateData(nsIFile *aFile, bool aIsAdd, uint32_t aRemapCount, uint32_t *aFromTraits, uint32_t *aToTraits) override; \
  NS_IMETHOD GetTokenCount(const nsACString& aWord, uint32_t aTrait, uint32_t *_retval) override; \
  NS_IMETHOD CorpusCounts(uint32_t aTrait, uint32_t *aMessageCount, uint32_t *_retval) 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_NSIMSGCORPUS \
  nsresult ClearTrait(uint32_t aTrait); \
  nsresult UpdateData(nsIFile *aFile, bool aIsAdd, uint32_t aRemapCount, uint32_t *aFromTraits, uint32_t *aToTraits); \
  nsresult GetTokenCount(const nsACString& aWord, uint32_t aTrait, uint32_t *_retval); \
  nsresult CorpusCounts(uint32_t aTrait, uint32_t *aMessageCount, uint32_t *_retval); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGCORPUS(_to) \
  NS_IMETHOD ClearTrait(uint32_t aTrait) override { return _to ClearTrait(aTrait); } \
  NS_IMETHOD UpdateData(nsIFile *aFile, bool aIsAdd, uint32_t aRemapCount, uint32_t *aFromTraits, uint32_t *aToTraits) override { return _to UpdateData(aFile, aIsAdd, aRemapCount, aFromTraits, aToTraits); } \
  NS_IMETHOD GetTokenCount(const nsACString& aWord, uint32_t aTrait, uint32_t *_retval) override { return _to GetTokenCount(aWord, aTrait, _retval); } \
  NS_IMETHOD CorpusCounts(uint32_t aTrait, uint32_t *aMessageCount, uint32_t *_retval) override { return _to CorpusCounts(aTrait, aMessageCount, _retval); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIMSGCORPUS(_to) \
  NS_IMETHOD ClearTrait(uint32_t aTrait) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ClearTrait(aTrait); } \
  NS_IMETHOD UpdateData(nsIFile *aFile, bool aIsAdd, uint32_t aRemapCount, uint32_t *aFromTraits, uint32_t *aToTraits) override { return !_to ? NS_ERROR_NULL_POINTER : _to->UpdateData(aFile, aIsAdd, aRemapCount, aFromTraits, aToTraits); } \
  NS_IMETHOD GetTokenCount(const nsACString& aWord, uint32_t aTrait, uint32_t *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTokenCount(aWord, aTrait, _retval); } \
  NS_IMETHOD CorpusCounts(uint32_t aTrait, uint32_t *aMessageCount, uint32_t *_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->CorpusCounts(aTrait, aMessageCount, _retval); } 


#endif /* __gen_nsIMsgFilterPlugin_h__ */