/*
 * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsMsgSearchCore.idl
 */

#ifndef __gen_nsMsgSearchCore_h__
#define __gen_nsMsgSearchCore_h__


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

#ifndef __gen_nsIMsgFolder_h__
#include "nsIMsgFolder.h"
#endif

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

#include "nsIMsgHeaderParser.h"
class nsIMsgDatabase; /* forward declaration */

class nsIMsgDBHdr; /* forward declaration */


/* starting interface:    nsMsgSearchScope */
#define NS_MSGSEARCHSCOPE_IID_STR "6e893e59-af98-4f62-a326-0f00f32147cd"

#define NS_MSGSEARCHSCOPE_IID \
  {0x6e893e59, 0xaf98, 0x4f62, \
    { 0xa3, 0x26, 0x0f, 0x00, 0xf3, 0x21, 0x47, 0xcd }}

class NS_NO_VTABLE NS_SCRIPTABLE nsMsgSearchScope {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_MSGSEARCHSCOPE_IID)

  enum {
    offlineMail = 0,
    offlineMailFilter = 1,
    onlineMail = 2,
    onlineMailFilter = 3,
    localNews = 4,
    news = 5,
    newsEx = 6,
    LDAP = 7,
    LocalAB = 8,
    allSearchableGroups = 9,
    newsFilter = 10,
    LocalABAnd = 11,
    LDAPAnd = 12,
    onlineManual = 13,
    localNewsJunk = 14,
    localNewsBody = 15,
    localNewsJunkBody = 16
  };

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsMsgSearchScope, NS_MSGSEARCHSCOPE_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSMSGSEARCHSCOPE \

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSMSGSEARCHSCOPE(_to) \

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSMSGSEARCHSCOPE(_to) \

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

/* Header file */
class _MYCLASS_ : public nsMsgSearchScope
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSMSGSEARCHSCOPE

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(_MYCLASS_, nsMsgSearchScope)

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

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

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

typedef PRInt32  nsMsgSearchAttribValue;


/* starting interface:    nsMsgSearchAttrib */
#define NS_MSGSEARCHATTRIB_IID_STR "a83ca7e8-4591-4111-8fb8-fd76ac73c866"

#define NS_MSGSEARCHATTRIB_IID \
  {0xa83ca7e8, 0x4591, 0x4111, \
    { 0x8f, 0xb8, 0xfd, 0x76, 0xac, 0x73, 0xc8, 0x66 }}

class NS_NO_VTABLE NS_SCRIPTABLE nsMsgSearchAttrib {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_MSGSEARCHATTRIB_IID)

  enum {
    Custom = -2,
    Default = -1,
    Subject = 0,
    Sender = 1,
    Body = 2,
    Date = 3,
    Priority = 4,
    MsgStatus = 5,
    To = 6,
    CC = 7,
    ToOrCC = 8,
    AllAddresses = 9,
    Location = 10,
    MessageKey = 11,
    AgeInDays = 12,
    FolderInfo = 13,
    Size = 14,
    AnyText = 15,
    Keywords = 16,
    Name = 17,
    DisplayName = 18,
    Nickname = 19,
    ScreenName = 20,
    Email = 21,
    AdditionalEmail = 22,
    PhoneNumber = 23,
    WorkPhone = 24,
    HomePhone = 25,
    Fax = 26,
    Pager = 27,
    Mobile = 28,
    City = 29,
    Street = 30,
    Title = 31,
    Organization = 32,
    Department = 33,
    HasAttachmentStatus = 44,
    JunkStatus = 45,
    JunkPercent = 46,
    JunkScoreOrigin = 47,
    Label = 48,
    HdrProperty = 49,
    FolderFlag = 50,
    Uint32HdrProperty = 51,
    OtherHeader = 52,
    kNumMsgSearchAttributes = 100
  };

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsMsgSearchAttrib, NS_MSGSEARCHATTRIB_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSMSGSEARCHATTRIB \

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSMSGSEARCHATTRIB(_to) \

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSMSGSEARCHATTRIB(_to) \

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

/* Header file */
class _MYCLASS_ : public nsMsgSearchAttrib
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSMSGSEARCHATTRIB

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(_MYCLASS_, nsMsgSearchAttrib)

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

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

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

typedef PRInt32  nsMsgSearchOpValue;


/* starting interface:    nsMsgSearchOp */
#define NS_MSGSEARCHOP_IID_STR "9160b196-6fcb-4eba-aaaf-6c806c4ee420"

#define NS_MSGSEARCHOP_IID \
  {0x9160b196, 0x6fcb, 0x4eba, \
    { 0xaa, 0xaf, 0x6c, 0x80, 0x6c, 0x4e, 0xe4, 0x20 }}

class NS_NO_VTABLE NS_SCRIPTABLE nsMsgSearchOp {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_MSGSEARCHOP_IID)

  enum {
    Contains = 0,
    DoesntContain = 1,
    Is = 2,
    Isnt = 3,
    IsEmpty = 4,
    IsBefore = 5,
    IsAfter = 6,
    IsHigherThan = 7,
    IsLowerThan = 8,
    BeginsWith = 9,
    EndsWith = 10,
    SoundsLike = 11,
    LdapDwim = 12,
    IsGreaterThan = 13,
    IsLessThan = 14,
    NameCompletion = 15,
    IsInAB = 16,
    IsntInAB = 17,
    IsntEmpty = 18,
    Matches = 19,
    DoesntMatch = 20,
    kNumMsgSearchOperators = 21
  };

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsMsgSearchOp, NS_MSGSEARCHOP_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSMSGSEARCHOP \

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSMSGSEARCHOP(_to) \

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSMSGSEARCHOP(_to) \

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

/* Header file */
class _MYCLASS_ : public nsMsgSearchOp
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSMSGSEARCHOP

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(_MYCLASS_, nsMsgSearchOp)

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

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

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

typedef PRInt32  nsMsgSearchWidgetValue;


/* starting interface:    nsMsgSearchWidget */
#define NS_MSGSEARCHWIDGET_IID_STR "903dd2e8-304e-11d3-92e6-00a0c900d445"

#define NS_MSGSEARCHWIDGET_IID \
  {0x903dd2e8, 0x304e, 0x11d3, \
    { 0x92, 0xe6, 0x00, 0xa0, 0xc9, 0x00, 0xd4, 0x45 }}

class NS_NO_VTABLE NS_SCRIPTABLE nsMsgSearchWidget {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_MSGSEARCHWIDGET_IID)

  enum {
    Text = 0,
    Date = 1,
    Menu = 2,
    Int = 3,
    None = 4
  };

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsMsgSearchWidget, NS_MSGSEARCHWIDGET_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSMSGSEARCHWIDGET \

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSMSGSEARCHWIDGET(_to) \

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSMSGSEARCHWIDGET(_to) \

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

/* Header file */
class _MYCLASS_ : public nsMsgSearchWidget
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSMSGSEARCHWIDGET

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(_MYCLASS_, nsMsgSearchWidget)

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

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

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

typedef PRInt32  nsMsgSearchTypeValue;


/* starting interface:    nsMsgSearchType */
#define NS_MSGSEARCHTYPE_IID_STR "964b7f32-304e-11d3-ae13-00a0c900d445"

#define NS_MSGSEARCHTYPE_IID \
  {0x964b7f32, 0x304e, 0x11d3, \
    { 0xae, 0x13, 0x00, 0xa0, 0xc9, 0x00, 0xd4, 0x45 }}

class NS_NO_VTABLE NS_SCRIPTABLE nsMsgSearchType {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_MSGSEARCHTYPE_IID)

  enum {
    None = 0,
    RootDSE = 1,
    Normal = 2,
    LdapVLV = 3,
    NameCompletion = 4
  };

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsMsgSearchType, NS_MSGSEARCHTYPE_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSMSGSEARCHTYPE \

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSMSGSEARCHTYPE(_to) \

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSMSGSEARCHTYPE(_to) \

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

/* Header file */
class _MYCLASS_ : public nsMsgSearchType
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSMSGSEARCHTYPE

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(_MYCLASS_, nsMsgSearchType)

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

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

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

typedef PRInt32  nsMsgSearchBooleanOperator;


/* starting interface:    nsMsgSearchBooleanOp */
#define NS_MSGSEARCHBOOLEANOP_IID_STR "a37f3f4a-304e-11d3-8f94-00a0c900d445"

#define NS_MSGSEARCHBOOLEANOP_IID \
  {0xa37f3f4a, 0x304e, 0x11d3, \
    { 0x8f, 0x94, 0x00, 0xa0, 0xc9, 0x00, 0xd4, 0x45 }}

class NS_NO_VTABLE NS_SCRIPTABLE nsMsgSearchBooleanOp {
 public: 

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_MSGSEARCHBOOLEANOP_IID)

  enum {
    BooleanOR = 0,
    BooleanAND = 1
  };

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsMsgSearchBooleanOp, NS_MSGSEARCHBOOLEANOP_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSMSGSEARCHBOOLEANOP \

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSMSGSEARCHBOOLEANOP(_to) \

/* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
#define NS_FORWARD_SAFE_NSMSGSEARCHBOOLEANOP(_to) \

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

/* Header file */
class _MYCLASS_ : public nsMsgSearchBooleanOp
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSMSGSEARCHBOOLEANOP

  _MYCLASS_();

private:
  ~_MYCLASS_();

protected:
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(_MYCLASS_, nsMsgSearchBooleanOp)

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

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

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

typedef struct nsMsgSearchValue
{
    nsMsgSearchAttribValue attribute;
    union
    {
      nsMsgPriorityValue priority;
      PRTime date;
      PRUint32 msgStatus; /* see MSG_FLAG in msgcom.h */
      PRUint32 size;
      nsMsgKey key;
      PRInt32 age; /* in days */
      nsIMsgFolder *folder;
      nsMsgLabelValue label;
      PRUint32 junkStatus;
      PRUint32 junkPercent;
    } u;
    char *string;
} nsMsgSearchValue;
#define IS_STRING_ATTRIBUTE(_a) \
(!(_a == nsMsgSearchAttrib::Priority || _a == nsMsgSearchAttrib::Date || \
   _a == nsMsgSearchAttrib::MsgStatus || _a == nsMsgSearchAttrib::MessageKey || \
   _a == nsMsgSearchAttrib::Size || _a == nsMsgSearchAttrib::AgeInDays || \
   _a == nsMsgSearchAttrib::FolderInfo || _a == nsMsgSearchAttrib::Location || \
   _a == nsMsgSearchAttrib::Label || _a == nsMsgSearchAttrib::JunkStatus || \
   _a == nsMsgSearchAttrib::FolderFlag || _a == nsMsgSearchAttrib::Uint32HdrProperty || \
   _a == nsMsgSearchAttrib::JunkPercent || _a == nsMsgSearchAttrib::HasAttachmentStatus))

#endif /* __gen_nsMsgSearchCore_h__ */
