/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM /tmp/comm-release/mailnews/base/search/public/nsIMsgFilter.idl
 */

#ifndef __gen_nsIMsgFilter_h__
#define __gen_nsIMsgFilter_h__


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

#ifndef __gen_nsMsgFilterCore_h__
#include "nsMsgFilterCore.h"
#endif

#ifndef __gen_nsIMsgSearchScopeTerm_h__
#include "nsIMsgSearchScopeTerm.h"
#endif

#ifndef __gen_nsIMsgSearchValue_h__
#include "nsIMsgSearchValue.h"
#endif

#ifndef __gen_nsIMsgSearchTerm_h__
#include "nsIMsgSearchTerm.h"
#endif

#ifndef __gen_nsISupportsArray_h__
#include "nsISupportsArray.h"
#endif

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

class nsIMsgFilterCustomAction; /* forward declaration */


/* starting interface:    nsIMsgRuleAction */
#define NS_IMSGRULEACTION_IID_STR "190a2a18-d245-473a-a402-9f0814598c7f"

#define NS_IMSGRULEACTION_IID \
  {0x190a2a18, 0xd245, 0x473a, \
    { 0xa4, 0x02, 0x9f, 0x08, 0x14, 0x59, 0x8c, 0x7f }}

class NS_NO_VTABLE NS_SCRIPTABLE nsIMsgRuleAction : public nsISupports {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGRULEACTION_IID)

  /* attribute nsMsgRuleActionType type; */
  NS_SCRIPTABLE NS_IMETHOD GetType(nsMsgRuleActionType *aType) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetType(nsMsgRuleActionType aType) = 0;

  /* attribute nsMsgPriorityValue priority; */
  NS_SCRIPTABLE NS_IMETHOD GetPriority(nsMsgPriorityValue *aPriority) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetPriority(nsMsgPriorityValue aPriority) = 0;

  /* attribute ACString targetFolderUri; */
  NS_SCRIPTABLE NS_IMETHOD GetTargetFolderUri(nsACString & aTargetFolderUri) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetTargetFolderUri(const nsACString & aTargetFolderUri) = 0;

  /* attribute nsMsgLabelValue label; */
  NS_SCRIPTABLE NS_IMETHOD GetLabel(nsMsgLabelValue *aLabel) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetLabel(nsMsgLabelValue aLabel) = 0;

  /* attribute long junkScore; */
  NS_SCRIPTABLE NS_IMETHOD GetJunkScore(PRInt32 *aJunkScore) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetJunkScore(PRInt32 aJunkScore) = 0;

  /* attribute AUTF8String strValue; */
  NS_SCRIPTABLE NS_IMETHOD GetStrValue(nsACString & aStrValue) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetStrValue(const nsACString & aStrValue) = 0;

  /* attribute ACString customId; */
  NS_SCRIPTABLE NS_IMETHOD GetCustomId(nsACString & aCustomId) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetCustomId(const nsACString & aCustomId) = 0;

  /* readonly attribute nsIMsgFilterCustomAction customAction; */
  NS_SCRIPTABLE NS_IMETHOD GetCustomAction(nsIMsgFilterCustomAction * *aCustomAction) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgRuleAction, NS_IMSGRULEACTION_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGRULEACTION \
  NS_SCRIPTABLE NS_IMETHOD GetType(nsMsgRuleActionType *aType); \
  NS_SCRIPTABLE NS_IMETHOD SetType(nsMsgRuleActionType aType); \
  NS_SCRIPTABLE NS_IMETHOD GetPriority(nsMsgPriorityValue *aPriority); \
  NS_SCRIPTABLE NS_IMETHOD SetPriority(nsMsgPriorityValue aPriority); \
  NS_SCRIPTABLE NS_IMETHOD GetTargetFolderUri(nsACString & aTargetFolderUri); \
  NS_SCRIPTABLE NS_IMETHOD SetTargetFolderUri(const nsACString & aTargetFolderUri); \
  NS_SCRIPTABLE NS_IMETHOD GetLabel(nsMsgLabelValue *aLabel); \
  NS_SCRIPTABLE NS_IMETHOD SetLabel(nsMsgLabelValue aLabel); \
  NS_SCRIPTABLE NS_IMETHOD GetJunkScore(PRInt32 *aJunkScore); \
  NS_SCRIPTABLE NS_IMETHOD SetJunkScore(PRInt32 aJunkScore); \
  NS_SCRIPTABLE NS_IMETHOD GetStrValue(nsACString & aStrValue); \
  NS_SCRIPTABLE NS_IMETHOD SetStrValue(const nsACString & aStrValue); \
  NS_SCRIPTABLE NS_IMETHOD GetCustomId(nsACString & aCustomId); \
  NS_SCRIPTABLE NS_IMETHOD SetCustomId(const nsACString & aCustomId); \
  NS_SCRIPTABLE NS_IMETHOD GetCustomAction(nsIMsgFilterCustomAction * *aCustomAction); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGRULEACTION(_to) \
  NS_SCRIPTABLE NS_IMETHOD GetType(nsMsgRuleActionType *aType) { return _to GetType(aType); } \
  NS_SCRIPTABLE NS_IMETHOD SetType(nsMsgRuleActionType aType) { return _to SetType(aType); } \
  NS_SCRIPTABLE NS_IMETHOD GetPriority(nsMsgPriorityValue *aPriority) { return _to GetPriority(aPriority); } \
  NS_SCRIPTABLE NS_IMETHOD SetPriority(nsMsgPriorityValue aPriority) { return _to SetPriority(aPriority); } \
  NS_SCRIPTABLE NS_IMETHOD GetTargetFolderUri(nsACString & aTargetFolderUri) { return _to GetTargetFolderUri(aTargetFolderUri); } \
  NS_SCRIPTABLE NS_IMETHOD SetTargetFolderUri(const nsACString & aTargetFolderUri) { return _to SetTargetFolderUri(aTargetFolderUri); } \
  NS_SCRIPTABLE NS_IMETHOD GetLabel(nsMsgLabelValue *aLabel) { return _to GetLabel(aLabel); } \
  NS_SCRIPTABLE NS_IMETHOD SetLabel(nsMsgLabelValue aLabel) { return _to SetLabel(aLabel); } \
  NS_SCRIPTABLE NS_IMETHOD GetJunkScore(PRInt32 *aJunkScore) { return _to GetJunkScore(aJunkScore); } \
  NS_SCRIPTABLE NS_IMETHOD SetJunkScore(PRInt32 aJunkScore) { return _to SetJunkScore(aJunkScore); } \
  NS_SCRIPTABLE NS_IMETHOD GetStrValue(nsACString & aStrValue) { return _to GetStrValue(aStrValue); } \
  NS_SCRIPTABLE NS_IMETHOD SetStrValue(const nsACString & aStrValue) { return _to SetStrValue(aStrValue); } \
  NS_SCRIPTABLE NS_IMETHOD GetCustomId(nsACString & aCustomId) { return _to GetCustomId(aCustomId); } \
  NS_SCRIPTABLE NS_IMETHOD SetCustomId(const nsACString & aCustomId) { return _to SetCustomId(aCustomId); } \
  NS_SCRIPTABLE NS_IMETHOD GetCustomAction(nsIMsgFilterCustomAction * *aCustomAction) { return _to GetCustomAction(aCustomAction); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIMSGRULEACTION(_to) \
  NS_SCRIPTABLE NS_IMETHOD GetType(nsMsgRuleActionType *aType) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetType(aType); } \
  NS_SCRIPTABLE NS_IMETHOD SetType(nsMsgRuleActionType aType) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetType(aType); } \
  NS_SCRIPTABLE NS_IMETHOD GetPriority(nsMsgPriorityValue *aPriority) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPriority(aPriority); } \
  NS_SCRIPTABLE NS_IMETHOD SetPriority(nsMsgPriorityValue aPriority) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetPriority(aPriority); } \
  NS_SCRIPTABLE NS_IMETHOD GetTargetFolderUri(nsACString & aTargetFolderUri) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTargetFolderUri(aTargetFolderUri); } \
  NS_SCRIPTABLE NS_IMETHOD SetTargetFolderUri(const nsACString & aTargetFolderUri) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetTargetFolderUri(aTargetFolderUri); } \
  NS_SCRIPTABLE NS_IMETHOD GetLabel(nsMsgLabelValue *aLabel) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLabel(aLabel); } \
  NS_SCRIPTABLE NS_IMETHOD SetLabel(nsMsgLabelValue aLabel) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetLabel(aLabel); } \
  NS_SCRIPTABLE NS_IMETHOD GetJunkScore(PRInt32 *aJunkScore) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetJunkScore(aJunkScore); } \
  NS_SCRIPTABLE NS_IMETHOD SetJunkScore(PRInt32 aJunkScore) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetJunkScore(aJunkScore); } \
  NS_SCRIPTABLE NS_IMETHOD GetStrValue(nsACString & aStrValue) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetStrValue(aStrValue); } \
  NS_SCRIPTABLE NS_IMETHOD SetStrValue(const nsACString & aStrValue) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetStrValue(aStrValue); } \
  NS_SCRIPTABLE NS_IMETHOD GetCustomId(nsACString & aCustomId) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetCustomId(aCustomId); } \
  NS_SCRIPTABLE NS_IMETHOD SetCustomId(const nsACString & aCustomId) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetCustomId(aCustomId); } \
  NS_SCRIPTABLE NS_IMETHOD GetCustomAction(nsIMsgFilterCustomAction * *aCustomAction) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetCustomAction(aCustomAction); } 

#if 0
/* Use the code below as a template for the implementation class for this interface. */

/* Header file */
class nsMsgRuleAction : public nsIMsgRuleAction
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSIMSGRULEACTION

  nsMsgRuleAction();

private:
  ~nsMsgRuleAction();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsMsgRuleAction, nsIMsgRuleAction)

nsMsgRuleAction::nsMsgRuleAction()
{
  /* member initializers and constructor code */
}

nsMsgRuleAction::~nsMsgRuleAction()
{
  /* destructor code */
}

/* attribute nsMsgRuleActionType type; */
NS_IMETHODIMP nsMsgRuleAction::GetType(nsMsgRuleActionType *aType)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetType(nsMsgRuleActionType aType)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute nsMsgPriorityValue priority; */
NS_IMETHODIMP nsMsgRuleAction::GetPriority(nsMsgPriorityValue *aPriority)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetPriority(nsMsgPriorityValue aPriority)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute ACString targetFolderUri; */
NS_IMETHODIMP nsMsgRuleAction::GetTargetFolderUri(nsACString & aTargetFolderUri)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetTargetFolderUri(const nsACString & aTargetFolderUri)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute nsMsgLabelValue label; */
NS_IMETHODIMP nsMsgRuleAction::GetLabel(nsMsgLabelValue *aLabel)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetLabel(nsMsgLabelValue aLabel)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute long junkScore; */
NS_IMETHODIMP nsMsgRuleAction::GetJunkScore(PRInt32 *aJunkScore)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetJunkScore(PRInt32 aJunkScore)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute AUTF8String strValue; */
NS_IMETHODIMP nsMsgRuleAction::GetStrValue(nsACString & aStrValue)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetStrValue(const nsACString & aStrValue)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute ACString customId; */
NS_IMETHODIMP nsMsgRuleAction::GetCustomId(nsACString & aCustomId)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgRuleAction::SetCustomId(const nsACString & aCustomId)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsIMsgFilterCustomAction customAction; */
NS_IMETHODIMP nsMsgRuleAction::GetCustomAction(nsIMsgFilterCustomAction * *aCustomAction)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* End of implementation class template. */
#endif


/* starting interface:    nsIMsgFilter */
#define NS_IMSGFILTER_IID_STR "346c8cc6-35ea-4f44-b348-94e84d7c03e0"

#define NS_IMSGFILTER_IID \
  {0x346c8cc6, 0x35ea, 0x4f44, \
    { 0xb3, 0x48, 0x94, 0xe8, 0x4d, 0x7c, 0x03, 0xe0 }}

class NS_NO_VTABLE NS_SCRIPTABLE nsIMsgFilter : public nsISupports {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGFILTER_IID)

  /* attribute nsMsgFilterTypeType filterType; */
  NS_SCRIPTABLE NS_IMETHOD GetFilterType(nsMsgFilterTypeType *aFilterType) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetFilterType(nsMsgFilterTypeType aFilterType) = 0;

  /* attribute boolean temporary; */
  NS_SCRIPTABLE NS_IMETHOD GetTemporary(bool *aTemporary) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetTemporary(bool aTemporary) = 0;

  /* attribute boolean enabled; */
  NS_SCRIPTABLE NS_IMETHOD GetEnabled(bool *aEnabled) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetEnabled(bool aEnabled) = 0;

  /* attribute AString filterName; */
  NS_SCRIPTABLE NS_IMETHOD GetFilterName(nsAString & aFilterName) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetFilterName(const nsAString & aFilterName) = 0;

  /* attribute ACString filterDesc; */
  NS_SCRIPTABLE NS_IMETHOD GetFilterDesc(nsACString & aFilterDesc) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetFilterDesc(const nsACString & aFilterDesc) = 0;

  /* attribute ACString unparsedBuffer; */
  NS_SCRIPTABLE NS_IMETHOD GetUnparsedBuffer(nsACString & aUnparsedBuffer) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetUnparsedBuffer(const nsACString & aUnparsedBuffer) = 0;

  /* attribute boolean unparseable; */
  NS_SCRIPTABLE NS_IMETHOD GetUnparseable(bool *aUnparseable) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetUnparseable(bool aUnparseable) = 0;

  /* readonly attribute nsIMsgFilterList filterList; */
  NS_SCRIPTABLE NS_IMETHOD GetFilterList(nsIMsgFilterList * *aFilterList) = 0;

  /* void AddTerm (in nsMsgSearchAttribValue attrib, in nsMsgSearchOpValue op, in nsIMsgSearchValue value, in boolean BooleanAND, in ACString arbitraryHeader); */
  NS_SCRIPTABLE NS_IMETHOD AddTerm(nsMsgSearchAttribValue attrib, nsMsgSearchOpValue op, nsIMsgSearchValue *value, bool BooleanAND, const nsACString & arbitraryHeader) = 0;

  /* void GetTerm (in long termIndex, out nsMsgSearchAttribValue attrib, out nsMsgSearchOpValue op, out nsIMsgSearchValue value, out boolean BooleanAND, out ACString arbitraryHeader); */
  NS_SCRIPTABLE NS_IMETHOD GetTerm(PRInt32 termIndex, nsMsgSearchAttribValue *attrib NS_OUTPARAM, nsMsgSearchOpValue *op NS_OUTPARAM, nsIMsgSearchValue * *value NS_OUTPARAM, bool *BooleanAND NS_OUTPARAM, nsACString & arbitraryHeader NS_OUTPARAM) = 0;

  /* void appendTerm (in nsIMsgSearchTerm term); */
  NS_SCRIPTABLE NS_IMETHOD AppendTerm(nsIMsgSearchTerm *term) = 0;

  /* nsIMsgSearchTerm createTerm (); */
  NS_SCRIPTABLE NS_IMETHOD CreateTerm(nsIMsgSearchTerm * *_retval NS_OUTPARAM) = 0;

  /* attribute nsISupportsArray searchTerms; */
  NS_SCRIPTABLE NS_IMETHOD GetSearchTerms(nsISupportsArray * *aSearchTerms) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetSearchTerms(nsISupportsArray *aSearchTerms) = 0;

  /* attribute nsIMsgSearchScopeTerm scope; */
  NS_SCRIPTABLE NS_IMETHOD GetScope(nsIMsgSearchScopeTerm * *aScope) = 0;
  NS_SCRIPTABLE NS_IMETHOD SetScope(nsIMsgSearchScopeTerm *aScope) = 0;

  /* [noscript] void MatchHdr (in nsIMsgDBHdr msgHdr, in nsIMsgFolder folder, in nsIMsgDatabase db, in string headers, in unsigned long headerSize, out boolean result); */
  NS_IMETHOD MatchHdr(nsIMsgDBHdr *msgHdr, nsIMsgFolder *folder, nsIMsgDatabase *db, const char * headers, PRUint32 headerSize, bool *result NS_OUTPARAM) = 0;

  /* void logRuleHit (in nsIMsgRuleAction aFilterAction, in nsIMsgDBHdr aHeader); */
  NS_SCRIPTABLE NS_IMETHOD LogRuleHit(nsIMsgRuleAction *aFilterAction, nsIMsgDBHdr *aHeader) = 0;

  /* nsIMsgRuleAction createAction (); */
  NS_SCRIPTABLE NS_IMETHOD CreateAction(nsIMsgRuleAction * *_retval NS_OUTPARAM) = 0;

  /* nsIMsgRuleAction getActionAt (in long aIndex); */
  NS_SCRIPTABLE NS_IMETHOD GetActionAt(PRInt32 aIndex, nsIMsgRuleAction * *_retval NS_OUTPARAM) = 0;

  /* void appendAction (in nsIMsgRuleAction action); */
  NS_SCRIPTABLE NS_IMETHOD AppendAction(nsIMsgRuleAction *action) = 0;

  /* void clearActionList (); */
  NS_SCRIPTABLE NS_IMETHOD ClearActionList(void) = 0;

  /* void getSortedActionList (in nsISupportsArray actionList); */
  NS_SCRIPTABLE NS_IMETHOD GetSortedActionList(nsISupportsArray *actionList) = 0;

  /* readonly attribute nsISupportsArray actionList; */
  NS_SCRIPTABLE NS_IMETHOD GetActionList(nsISupportsArray * *aActionList) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgFilter, NS_IMSGFILTER_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGFILTER \
  NS_SCRIPTABLE NS_IMETHOD GetFilterType(nsMsgFilterTypeType *aFilterType); \
  NS_SCRIPTABLE NS_IMETHOD SetFilterType(nsMsgFilterTypeType aFilterType); \
  NS_SCRIPTABLE NS_IMETHOD GetTemporary(bool *aTemporary); \
  NS_SCRIPTABLE NS_IMETHOD SetTemporary(bool aTemporary); \
  NS_SCRIPTABLE NS_IMETHOD GetEnabled(bool *aEnabled); \
  NS_SCRIPTABLE NS_IMETHOD SetEnabled(bool aEnabled); \
  NS_SCRIPTABLE NS_IMETHOD GetFilterName(nsAString & aFilterName); \
  NS_SCRIPTABLE NS_IMETHOD SetFilterName(const nsAString & aFilterName); \
  NS_SCRIPTABLE NS_IMETHOD GetFilterDesc(nsACString & aFilterDesc); \
  NS_SCRIPTABLE NS_IMETHOD SetFilterDesc(const nsACString & aFilterDesc); \
  NS_SCRIPTABLE NS_IMETHOD GetUnparsedBuffer(nsACString & aUnparsedBuffer); \
  NS_SCRIPTABLE NS_IMETHOD SetUnparsedBuffer(const nsACString & aUnparsedBuffer); \
  NS_SCRIPTABLE NS_IMETHOD GetUnparseable(bool *aUnparseable); \
  NS_SCRIPTABLE NS_IMETHOD SetUnparseable(bool aUnparseable); \
  NS_SCRIPTABLE NS_IMETHOD GetFilterList(nsIMsgFilterList * *aFilterList); \
  NS_SCRIPTABLE NS_IMETHOD AddTerm(nsMsgSearchAttribValue attrib, nsMsgSearchOpValue op, nsIMsgSearchValue *value, bool BooleanAND, const nsACString & arbitraryHeader); \
  NS_SCRIPTABLE NS_IMETHOD GetTerm(PRInt32 termIndex, nsMsgSearchAttribValue *attrib NS_OUTPARAM, nsMsgSearchOpValue *op NS_OUTPARAM, nsIMsgSearchValue * *value NS_OUTPARAM, bool *BooleanAND NS_OUTPARAM, nsACString & arbitraryHeader NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD AppendTerm(nsIMsgSearchTerm *term); \
  NS_SCRIPTABLE NS_IMETHOD CreateTerm(nsIMsgSearchTerm * *_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD GetSearchTerms(nsISupportsArray * *aSearchTerms); \
  NS_SCRIPTABLE NS_IMETHOD SetSearchTerms(nsISupportsArray *aSearchTerms); \
  NS_SCRIPTABLE NS_IMETHOD GetScope(nsIMsgSearchScopeTerm * *aScope); \
  NS_SCRIPTABLE NS_IMETHOD SetScope(nsIMsgSearchScopeTerm *aScope); \
  NS_IMETHOD MatchHdr(nsIMsgDBHdr *msgHdr, nsIMsgFolder *folder, nsIMsgDatabase *db, const char * headers, PRUint32 headerSize, bool *result NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD LogRuleHit(nsIMsgRuleAction *aFilterAction, nsIMsgDBHdr *aHeader); \
  NS_SCRIPTABLE NS_IMETHOD CreateAction(nsIMsgRuleAction * *_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD GetActionAt(PRInt32 aIndex, nsIMsgRuleAction * *_retval NS_OUTPARAM); \
  NS_SCRIPTABLE NS_IMETHOD AppendAction(nsIMsgRuleAction *action); \
  NS_SCRIPTABLE NS_IMETHOD ClearActionList(void); \
  NS_SCRIPTABLE NS_IMETHOD GetSortedActionList(nsISupportsArray *actionList); \
  NS_SCRIPTABLE NS_IMETHOD GetActionList(nsISupportsArray * *aActionList); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGFILTER(_to) \
  NS_SCRIPTABLE NS_IMETHOD GetFilterType(nsMsgFilterTypeType *aFilterType) { return _to GetFilterType(aFilterType); } \
  NS_SCRIPTABLE NS_IMETHOD SetFilterType(nsMsgFilterTypeType aFilterType) { return _to SetFilterType(aFilterType); } \
  NS_SCRIPTABLE NS_IMETHOD GetTemporary(bool *aTemporary) { return _to GetTemporary(aTemporary); } \
  NS_SCRIPTABLE NS_IMETHOD SetTemporary(bool aTemporary) { return _to SetTemporary(aTemporary); } \
  NS_SCRIPTABLE NS_IMETHOD GetEnabled(bool *aEnabled) { return _to GetEnabled(aEnabled); } \
  NS_SCRIPTABLE NS_IMETHOD SetEnabled(bool aEnabled) { return _to SetEnabled(aEnabled); } \
  NS_SCRIPTABLE NS_IMETHOD GetFilterName(nsAString & aFilterName) { return _to GetFilterName(aFilterName); } \
  NS_SCRIPTABLE NS_IMETHOD SetFilterName(const nsAString & aFilterName) { return _to SetFilterName(aFilterName); } \
  NS_SCRIPTABLE NS_IMETHOD GetFilterDesc(nsACString & aFilterDesc) { return _to GetFilterDesc(aFilterDesc); } \
  NS_SCRIPTABLE NS_IMETHOD SetFilterDesc(const nsACString & aFilterDesc) { return _to SetFilterDesc(aFilterDesc); } \
  NS_SCRIPTABLE NS_IMETHOD GetUnparsedBuffer(nsACString & aUnparsedBuffer) { return _to GetUnparsedBuffer(aUnparsedBuffer); } \
  NS_SCRIPTABLE NS_IMETHOD SetUnparsedBuffer(const nsACString & aUnparsedBuffer) { return _to SetUnparsedBuffer(aUnparsedBuffer); } \
  NS_SCRIPTABLE NS_IMETHOD GetUnparseable(bool *aUnparseable) { return _to GetUnparseable(aUnparseable); } \
  NS_SCRIPTABLE NS_IMETHOD SetUnparseable(bool aUnparseable) { return _to SetUnparseable(aUnparseable); } \
  NS_SCRIPTABLE NS_IMETHOD GetFilterList(nsIMsgFilterList * *aFilterList) { return _to GetFilterList(aFilterList); } \
  NS_SCRIPTABLE NS_IMETHOD AddTerm(nsMsgSearchAttribValue attrib, nsMsgSearchOpValue op, nsIMsgSearchValue *value, bool BooleanAND, const nsACString & arbitraryHeader) { return _to AddTerm(attrib, op, value, BooleanAND, arbitraryHeader); } \
  NS_SCRIPTABLE NS_IMETHOD GetTerm(PRInt32 termIndex, nsMsgSearchAttribValue *attrib NS_OUTPARAM, nsMsgSearchOpValue *op NS_OUTPARAM, nsIMsgSearchValue * *value NS_OUTPARAM, bool *BooleanAND NS_OUTPARAM, nsACString & arbitraryHeader NS_OUTPARAM) { return _to GetTerm(termIndex, attrib, op, value, BooleanAND, arbitraryHeader); } \
  NS_SCRIPTABLE NS_IMETHOD AppendTerm(nsIMsgSearchTerm *term) { return _to AppendTerm(term); } \
  NS_SCRIPTABLE NS_IMETHOD CreateTerm(nsIMsgSearchTerm * *_retval NS_OUTPARAM) { return _to CreateTerm(_retval); } \
  NS_SCRIPTABLE NS_IMETHOD GetSearchTerms(nsISupportsArray * *aSearchTerms) { return _to GetSearchTerms(aSearchTerms); } \
  NS_SCRIPTABLE NS_IMETHOD SetSearchTerms(nsISupportsArray *aSearchTerms) { return _to SetSearchTerms(aSearchTerms); } \
  NS_SCRIPTABLE NS_IMETHOD GetScope(nsIMsgSearchScopeTerm * *aScope) { return _to GetScope(aScope); } \
  NS_SCRIPTABLE NS_IMETHOD SetScope(nsIMsgSearchScopeTerm *aScope) { return _to SetScope(aScope); } \
  NS_IMETHOD MatchHdr(nsIMsgDBHdr *msgHdr, nsIMsgFolder *folder, nsIMsgDatabase *db, const char * headers, PRUint32 headerSize, bool *result NS_OUTPARAM) { return _to MatchHdr(msgHdr, folder, db, headers, headerSize, result); } \
  NS_SCRIPTABLE NS_IMETHOD LogRuleHit(nsIMsgRuleAction *aFilterAction, nsIMsgDBHdr *aHeader) { return _to LogRuleHit(aFilterAction, aHeader); } \
  NS_SCRIPTABLE NS_IMETHOD CreateAction(nsIMsgRuleAction * *_retval NS_OUTPARAM) { return _to CreateAction(_retval); } \
  NS_SCRIPTABLE NS_IMETHOD GetActionAt(PRInt32 aIndex, nsIMsgRuleAction * *_retval NS_OUTPARAM) { return _to GetActionAt(aIndex, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD AppendAction(nsIMsgRuleAction *action) { return _to AppendAction(action); } \
  NS_SCRIPTABLE NS_IMETHOD ClearActionList(void) { return _to ClearActionList(); } \
  NS_SCRIPTABLE NS_IMETHOD GetSortedActionList(nsISupportsArray *actionList) { return _to GetSortedActionList(actionList); } \
  NS_SCRIPTABLE NS_IMETHOD GetActionList(nsISupportsArray * *aActionList) { return _to GetActionList(aActionList); } 

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSIMSGFILTER(_to) \
  NS_SCRIPTABLE NS_IMETHOD GetFilterType(nsMsgFilterTypeType *aFilterType) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFilterType(aFilterType); } \
  NS_SCRIPTABLE NS_IMETHOD SetFilterType(nsMsgFilterTypeType aFilterType) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetFilterType(aFilterType); } \
  NS_SCRIPTABLE NS_IMETHOD GetTemporary(bool *aTemporary) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTemporary(aTemporary); } \
  NS_SCRIPTABLE NS_IMETHOD SetTemporary(bool aTemporary) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetTemporary(aTemporary); } \
  NS_SCRIPTABLE NS_IMETHOD GetEnabled(bool *aEnabled) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetEnabled(aEnabled); } \
  NS_SCRIPTABLE NS_IMETHOD SetEnabled(bool aEnabled) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetEnabled(aEnabled); } \
  NS_SCRIPTABLE NS_IMETHOD GetFilterName(nsAString & aFilterName) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFilterName(aFilterName); } \
  NS_SCRIPTABLE NS_IMETHOD SetFilterName(const nsAString & aFilterName) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetFilterName(aFilterName); } \
  NS_SCRIPTABLE NS_IMETHOD GetFilterDesc(nsACString & aFilterDesc) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFilterDesc(aFilterDesc); } \
  NS_SCRIPTABLE NS_IMETHOD SetFilterDesc(const nsACString & aFilterDesc) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetFilterDesc(aFilterDesc); } \
  NS_SCRIPTABLE NS_IMETHOD GetUnparsedBuffer(nsACString & aUnparsedBuffer) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetUnparsedBuffer(aUnparsedBuffer); } \
  NS_SCRIPTABLE NS_IMETHOD SetUnparsedBuffer(const nsACString & aUnparsedBuffer) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetUnparsedBuffer(aUnparsedBuffer); } \
  NS_SCRIPTABLE NS_IMETHOD GetUnparseable(bool *aUnparseable) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetUnparseable(aUnparseable); } \
  NS_SCRIPTABLE NS_IMETHOD SetUnparseable(bool aUnparseable) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetUnparseable(aUnparseable); } \
  NS_SCRIPTABLE NS_IMETHOD GetFilterList(nsIMsgFilterList * *aFilterList) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFilterList(aFilterList); } \
  NS_SCRIPTABLE NS_IMETHOD AddTerm(nsMsgSearchAttribValue attrib, nsMsgSearchOpValue op, nsIMsgSearchValue *value, bool BooleanAND, const nsACString & arbitraryHeader) { return !_to ? NS_ERROR_NULL_POINTER : _to->AddTerm(attrib, op, value, BooleanAND, arbitraryHeader); } \
  NS_SCRIPTABLE NS_IMETHOD GetTerm(PRInt32 termIndex, nsMsgSearchAttribValue *attrib NS_OUTPARAM, nsMsgSearchOpValue *op NS_OUTPARAM, nsIMsgSearchValue * *value NS_OUTPARAM, bool *BooleanAND NS_OUTPARAM, nsACString & arbitraryHeader NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTerm(termIndex, attrib, op, value, BooleanAND, arbitraryHeader); } \
  NS_SCRIPTABLE NS_IMETHOD AppendTerm(nsIMsgSearchTerm *term) { return !_to ? NS_ERROR_NULL_POINTER : _to->AppendTerm(term); } \
  NS_SCRIPTABLE NS_IMETHOD CreateTerm(nsIMsgSearchTerm * *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->CreateTerm(_retval); } \
  NS_SCRIPTABLE NS_IMETHOD GetSearchTerms(nsISupportsArray * *aSearchTerms) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetSearchTerms(aSearchTerms); } \
  NS_SCRIPTABLE NS_IMETHOD SetSearchTerms(nsISupportsArray *aSearchTerms) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetSearchTerms(aSearchTerms); } \
  NS_SCRIPTABLE NS_IMETHOD GetScope(nsIMsgSearchScopeTerm * *aScope) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetScope(aScope); } \
  NS_SCRIPTABLE NS_IMETHOD SetScope(nsIMsgSearchScopeTerm *aScope) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetScope(aScope); } \
  NS_IMETHOD MatchHdr(nsIMsgDBHdr *msgHdr, nsIMsgFolder *folder, nsIMsgDatabase *db, const char * headers, PRUint32 headerSize, bool *result NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->MatchHdr(msgHdr, folder, db, headers, headerSize, result); } \
  NS_SCRIPTABLE NS_IMETHOD LogRuleHit(nsIMsgRuleAction *aFilterAction, nsIMsgDBHdr *aHeader) { return !_to ? NS_ERROR_NULL_POINTER : _to->LogRuleHit(aFilterAction, aHeader); } \
  NS_SCRIPTABLE NS_IMETHOD CreateAction(nsIMsgRuleAction * *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->CreateAction(_retval); } \
  NS_SCRIPTABLE NS_IMETHOD GetActionAt(PRInt32 aIndex, nsIMsgRuleAction * *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetActionAt(aIndex, _retval); } \
  NS_SCRIPTABLE NS_IMETHOD AppendAction(nsIMsgRuleAction *action) { return !_to ? NS_ERROR_NULL_POINTER : _to->AppendAction(action); } \
  NS_SCRIPTABLE NS_IMETHOD ClearActionList(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->ClearActionList(); } \
  NS_SCRIPTABLE NS_IMETHOD GetSortedActionList(nsISupportsArray *actionList) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetSortedActionList(actionList); } \
  NS_SCRIPTABLE NS_IMETHOD GetActionList(nsISupportsArray * *aActionList) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetActionList(aActionList); } 

#if 0
/* Use the code below as a template for the implementation class for this interface. */

/* Header file */
class nsMsgFilter : public nsIMsgFilter
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSIMSGFILTER

  nsMsgFilter();

private:
  ~nsMsgFilter();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsMsgFilter, nsIMsgFilter)

nsMsgFilter::nsMsgFilter()
{
  /* member initializers and constructor code */
}

nsMsgFilter::~nsMsgFilter()
{
  /* destructor code */
}

/* attribute nsMsgFilterTypeType filterType; */
NS_IMETHODIMP nsMsgFilter::GetFilterType(nsMsgFilterTypeType *aFilterType)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetFilterType(nsMsgFilterTypeType aFilterType)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute boolean temporary; */
NS_IMETHODIMP nsMsgFilter::GetTemporary(bool *aTemporary)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetTemporary(bool aTemporary)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute boolean enabled; */
NS_IMETHODIMP nsMsgFilter::GetEnabled(bool *aEnabled)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetEnabled(bool aEnabled)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute AString filterName; */
NS_IMETHODIMP nsMsgFilter::GetFilterName(nsAString & aFilterName)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetFilterName(const nsAString & aFilterName)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute ACString filterDesc; */
NS_IMETHODIMP nsMsgFilter::GetFilterDesc(nsACString & aFilterDesc)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetFilterDesc(const nsACString & aFilterDesc)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute ACString unparsedBuffer; */
NS_IMETHODIMP nsMsgFilter::GetUnparsedBuffer(nsACString & aUnparsedBuffer)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetUnparsedBuffer(const nsACString & aUnparsedBuffer)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute boolean unparseable; */
NS_IMETHODIMP nsMsgFilter::GetUnparseable(bool *aUnparseable)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetUnparseable(bool aUnparseable)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsIMsgFilterList filterList; */
NS_IMETHODIMP nsMsgFilter::GetFilterList(nsIMsgFilterList * *aFilterList)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void AddTerm (in nsMsgSearchAttribValue attrib, in nsMsgSearchOpValue op, in nsIMsgSearchValue value, in boolean BooleanAND, in ACString arbitraryHeader); */
NS_IMETHODIMP nsMsgFilter::AddTerm(nsMsgSearchAttribValue attrib, nsMsgSearchOpValue op, nsIMsgSearchValue *value, bool BooleanAND, const nsACString & arbitraryHeader)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void GetTerm (in long termIndex, out nsMsgSearchAttribValue attrib, out nsMsgSearchOpValue op, out nsIMsgSearchValue value, out boolean BooleanAND, out ACString arbitraryHeader); */
NS_IMETHODIMP nsMsgFilter::GetTerm(PRInt32 termIndex, nsMsgSearchAttribValue *attrib NS_OUTPARAM, nsMsgSearchOpValue *op NS_OUTPARAM, nsIMsgSearchValue * *value NS_OUTPARAM, bool *BooleanAND NS_OUTPARAM, nsACString & arbitraryHeader NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void appendTerm (in nsIMsgSearchTerm term); */
NS_IMETHODIMP nsMsgFilter::AppendTerm(nsIMsgSearchTerm *term)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* nsIMsgSearchTerm createTerm (); */
NS_IMETHODIMP nsMsgFilter::CreateTerm(nsIMsgSearchTerm * *_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute nsISupportsArray searchTerms; */
NS_IMETHODIMP nsMsgFilter::GetSearchTerms(nsISupportsArray * *aSearchTerms)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetSearchTerms(nsISupportsArray *aSearchTerms)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* attribute nsIMsgSearchScopeTerm scope; */
NS_IMETHODIMP nsMsgFilter::GetScope(nsIMsgSearchScopeTerm * *aScope)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}
NS_IMETHODIMP nsMsgFilter::SetScope(nsIMsgSearchScopeTerm *aScope)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] void MatchHdr (in nsIMsgDBHdr msgHdr, in nsIMsgFolder folder, in nsIMsgDatabase db, in string headers, in unsigned long headerSize, out boolean result); */
NS_IMETHODIMP nsMsgFilter::MatchHdr(nsIMsgDBHdr *msgHdr, nsIMsgFolder *folder, nsIMsgDatabase *db, const char * headers, PRUint32 headerSize, bool *result NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void logRuleHit (in nsIMsgRuleAction aFilterAction, in nsIMsgDBHdr aHeader); */
NS_IMETHODIMP nsMsgFilter::LogRuleHit(nsIMsgRuleAction *aFilterAction, nsIMsgDBHdr *aHeader)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* nsIMsgRuleAction createAction (); */
NS_IMETHODIMP nsMsgFilter::CreateAction(nsIMsgRuleAction * *_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* nsIMsgRuleAction getActionAt (in long aIndex); */
NS_IMETHODIMP nsMsgFilter::GetActionAt(PRInt32 aIndex, nsIMsgRuleAction * *_retval NS_OUTPARAM)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void appendAction (in nsIMsgRuleAction action); */
NS_IMETHODIMP nsMsgFilter::AppendAction(nsIMsgRuleAction *action)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void clearActionList (); */
NS_IMETHODIMP nsMsgFilter::ClearActionList()
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void getSortedActionList (in nsISupportsArray actionList); */
NS_IMETHODIMP nsMsgFilter::GetSortedActionList(nsISupportsArray *actionList)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* readonly attribute nsISupportsArray actionList; */
NS_IMETHODIMP nsMsgFilter::GetActionList(nsISupportsArray * *aActionList)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* End of implementation class template. */
#endif


#endif /* __gen_nsIMsgFilter_h__ */
