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

#ifndef __gen_nsIMsgHeaderParser_h__
#define __gen_nsIMsgHeaderParser_h__


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

#ifndef __gen_nsrootidl_h__
#include "nsrootidl.h"
#endif

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

#define NS_MAILNEWS_MIME_HEADER_PARSER_CONTRACTID \
  "@mozilla.org/messenger/headerparser;1"

/* starting interface:    nsIMsgHeaderParser */
#define NS_IMSGHEADERPARSER_IID_STR "10a88a11-729e-11d2-804a-006008128c4e"

#define NS_IMSGHEADERPARSER_IID \
  {0x10a88a11, 0x729e, 0x11d2, \
    { 0x80, 0x4a, 0x00, 0x60, 0x08, 0x12, 0x8c, 0x4e }}

class NS_NO_VTABLE nsIMsgHeaderParser : public nsISupports {
 public: 

  NS_DEFINE_STATIC_IID_ACCESSOR(NS_IMSGHEADERPARSER_IID)

  /* void parseHeadersWithArray (in wstring aLine, [array, size_is (count)] out wstring aEmailAddresses, [array, size_is (count)] out wstring aNames, [array, size_is (count)] out wstring aFullNames, [retval] out unsigned long count); */
  NS_IMETHOD ParseHeadersWithArray(const PRUnichar *aLine, PRUnichar ***aEmailAddresses, PRUnichar ***aNames, PRUnichar ***aFullNames, PRUint32 *count) = 0;

  /* [noscript] void parseHeaderAddresses (in string charset, in string line, out string names, out string addresses, out PRUint32 numAddresses); */
  NS_IMETHOD ParseHeaderAddresses(const char *charset, const char *line, char **names, char **addresses, PRUint32 *numAddresses) = 0;

  /* void extractHeaderAddressMailboxes (in string charset, in string line, out string mailboxes); */
  NS_IMETHOD ExtractHeaderAddressMailboxes(const char *charset, const char *line, char **mailboxes) = 0;

  /* [noscript] void extractHeaderAddressNames (in string charset, in string line, out string userNames); */
  NS_IMETHOD ExtractHeaderAddressNames(const char *charset, const char *line, char **userNames) = 0;

  /* [noscript] void extractHeaderAddressName (in string charset, in string line, out string name); */
  NS_IMETHOD ExtractHeaderAddressName(const char *charset, const char *line, char **name) = 0;

  /* [noscript] void reformatHeaderAddresses (in string charset, in string line, out string reformattedAddress); */
  NS_IMETHOD ReformatHeaderAddresses(const char *charset, const char *line, char **reformattedAddress) = 0;

  /* [noscript] void removeDuplicateAddresses (in string charset, in string addrs, in string other_addrs, in PRBool removeAliasesToMe, out string newAddress); */
  NS_IMETHOD RemoveDuplicateAddresses(const char *charset, const char *addrs, const char *other_addrs, PRBool removeAliasesToMe, char **newAddress) = 0;

  /* [noscript] string makeFullAddress (in string charset, in string name, in string addr); */
  NS_IMETHOD MakeFullAddress(const char *charset, const char *name, const char *addr, char **_retval) = 0;

  /* wstring makeFullAddressWString (in wstring name, in wstring addr); */
  NS_IMETHOD MakeFullAddressWString(const PRUnichar *name, const PRUnichar *addr, PRUnichar **_retval) = 0;

  /* [noscript] string unquotePhraseOrAddr (in string line, in boolean preserveIntegrity); */
  NS_IMETHOD UnquotePhraseOrAddr(const char *line, PRBool preserveIntegrity, char **_retval) = 0;

  /* wstring unquotePhraseOrAddrWString (in wstring line, in boolean preserveIntegrity); */
  NS_IMETHOD UnquotePhraseOrAddrWString(const PRUnichar *line, PRBool preserveIntegrity, PRUnichar **_retval) = 0;

  /* wstring reformatUnquotedAddresses (in wstring line); */
  NS_IMETHOD ReformatUnquotedAddresses(const PRUnichar *line, PRUnichar **_retval) = 0;

};

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGHEADERPARSER \
  NS_IMETHOD ParseHeadersWithArray(const PRUnichar *aLine, PRUnichar ***aEmailAddresses, PRUnichar ***aNames, PRUnichar ***aFullNames, PRUint32 *count); \
  NS_IMETHOD ParseHeaderAddresses(const char *charset, const char *line, char **names, char **addresses, PRUint32 *numAddresses); \
  NS_IMETHOD ExtractHeaderAddressMailboxes(const char *charset, const char *line, char **mailboxes); \
  NS_IMETHOD ExtractHeaderAddressNames(const char *charset, const char *line, char **userNames); \
  NS_IMETHOD ExtractHeaderAddressName(const char *charset, const char *line, char **name); \
  NS_IMETHOD ReformatHeaderAddresses(const char *charset, const char *line, char **reformattedAddress); \
  NS_IMETHOD RemoveDuplicateAddresses(const char *charset, const char *addrs, const char *other_addrs, PRBool removeAliasesToMe, char **newAddress); \
  NS_IMETHOD MakeFullAddress(const char *charset, const char *name, const char *addr, char **_retval); \
  NS_IMETHOD MakeFullAddressWString(const PRUnichar *name, const PRUnichar *addr, PRUnichar **_retval); \
  NS_IMETHOD UnquotePhraseOrAddr(const char *line, PRBool preserveIntegrity, char **_retval); \
  NS_IMETHOD UnquotePhraseOrAddrWString(const PRUnichar *line, PRBool preserveIntegrity, PRUnichar **_retval); \
  NS_IMETHOD ReformatUnquotedAddresses(const PRUnichar *line, PRUnichar **_retval); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGHEADERPARSER(_to) \
  NS_IMETHOD ParseHeadersWithArray(const PRUnichar *aLine, PRUnichar ***aEmailAddresses, PRUnichar ***aNames, PRUnichar ***aFullNames, PRUint32 *count) { return _to ParseHeadersWithArray(aLine, aEmailAddresses, aNames, aFullNames, count); } \
  NS_IMETHOD ParseHeaderAddresses(const char *charset, const char *line, char **names, char **addresses, PRUint32 *numAddresses) { return _to ParseHeaderAddresses(charset, line, names, addresses, numAddresses); } \
  NS_IMETHOD ExtractHeaderAddressMailboxes(const char *charset, const char *line, char **mailboxes) { return _to ExtractHeaderAddressMailboxes(charset, line, mailboxes); } \
  NS_IMETHOD ExtractHeaderAddressNames(const char *charset, const char *line, char **userNames) { return _to ExtractHeaderAddressNames(charset, line, userNames); } \
  NS_IMETHOD ExtractHeaderAddressName(const char *charset, const char *line, char **name) { return _to ExtractHeaderAddressName(charset, line, name); } \
  NS_IMETHOD ReformatHeaderAddresses(const char *charset, const char *line, char **reformattedAddress) { return _to ReformatHeaderAddresses(charset, line, reformattedAddress); } \
  NS_IMETHOD RemoveDuplicateAddresses(const char *charset, const char *addrs, const char *other_addrs, PRBool removeAliasesToMe, char **newAddress) { return _to RemoveDuplicateAddresses(charset, addrs, other_addrs, removeAliasesToMe, newAddress); } \
  NS_IMETHOD MakeFullAddress(const char *charset, const char *name, const char *addr, char **_retval) { return _to MakeFullAddress(charset, name, addr, _retval); } \
  NS_IMETHOD MakeFullAddressWString(const PRUnichar *name, const PRUnichar *addr, PRUnichar **_retval) { return _to MakeFullAddressWString(name, addr, _retval); } \
  NS_IMETHOD UnquotePhraseOrAddr(const char *line, PRBool preserveIntegrity, char **_retval) { return _to UnquotePhraseOrAddr(line, preserveIntegrity, _retval); } \
  NS_IMETHOD UnquotePhraseOrAddrWString(const PRUnichar *line, PRBool preserveIntegrity, PRUnichar **_retval) { return _to UnquotePhraseOrAddrWString(line, preserveIntegrity, _retval); } \
  NS_IMETHOD ReformatUnquotedAddresses(const PRUnichar *line, PRUnichar **_retval) { return _to ReformatUnquotedAddresses(line, _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_NSIMSGHEADERPARSER(_to) \
  NS_IMETHOD ParseHeadersWithArray(const PRUnichar *aLine, PRUnichar ***aEmailAddresses, PRUnichar ***aNames, PRUnichar ***aFullNames, PRUint32 *count) { return !_to ? NS_ERROR_NULL_POINTER : _to->ParseHeadersWithArray(aLine, aEmailAddresses, aNames, aFullNames, count); } \
  NS_IMETHOD ParseHeaderAddresses(const char *charset, const char *line, char **names, char **addresses, PRUint32 *numAddresses) { return !_to ? NS_ERROR_NULL_POINTER : _to->ParseHeaderAddresses(charset, line, names, addresses, numAddresses); } \
  NS_IMETHOD ExtractHeaderAddressMailboxes(const char *charset, const char *line, char **mailboxes) { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractHeaderAddressMailboxes(charset, line, mailboxes); } \
  NS_IMETHOD ExtractHeaderAddressNames(const char *charset, const char *line, char **userNames) { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractHeaderAddressNames(charset, line, userNames); } \
  NS_IMETHOD ExtractHeaderAddressName(const char *charset, const char *line, char **name) { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractHeaderAddressName(charset, line, name); } \
  NS_IMETHOD ReformatHeaderAddresses(const char *charset, const char *line, char **reformattedAddress) { return !_to ? NS_ERROR_NULL_POINTER : _to->ReformatHeaderAddresses(charset, line, reformattedAddress); } \
  NS_IMETHOD RemoveDuplicateAddresses(const char *charset, const char *addrs, const char *other_addrs, PRBool removeAliasesToMe, char **newAddress) { return !_to ? NS_ERROR_NULL_POINTER : _to->RemoveDuplicateAddresses(charset, addrs, other_addrs, removeAliasesToMe, newAddress); } \
  NS_IMETHOD MakeFullAddress(const char *charset, const char *name, const char *addr, char **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeFullAddress(charset, name, addr, _retval); } \
  NS_IMETHOD MakeFullAddressWString(const PRUnichar *name, const PRUnichar *addr, PRUnichar **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeFullAddressWString(name, addr, _retval); } \
  NS_IMETHOD UnquotePhraseOrAddr(const char *line, PRBool preserveIntegrity, char **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->UnquotePhraseOrAddr(line, preserveIntegrity, _retval); } \
  NS_IMETHOD UnquotePhraseOrAddrWString(const PRUnichar *line, PRBool preserveIntegrity, PRUnichar **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->UnquotePhraseOrAddrWString(line, preserveIntegrity, _retval); } \
  NS_IMETHOD ReformatUnquotedAddresses(const PRUnichar *line, PRUnichar **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->ReformatUnquotedAddresses(line, _retval); } 

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

/* Header file */
class nsMsgHeaderParser : public nsIMsgHeaderParser
{
public:
  NS_DECL_ISUPPORTS
  NS_DECL_NSIMSGHEADERPARSER

  nsMsgHeaderParser();
  virtual ~nsMsgHeaderParser();
  /* additional members */
};

/* Implementation file */
NS_IMPL_ISUPPORTS1(nsMsgHeaderParser, nsIMsgHeaderParser)

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

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

/* void parseHeadersWithArray (in wstring aLine, [array, size_is (count)] out wstring aEmailAddresses, [array, size_is (count)] out wstring aNames, [array, size_is (count)] out wstring aFullNames, [retval] out unsigned long count); */
NS_IMETHODIMP nsMsgHeaderParser::ParseHeadersWithArray(const PRUnichar *aLine, PRUnichar ***aEmailAddresses, PRUnichar ***aNames, PRUnichar ***aFullNames, PRUint32 *count)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] void parseHeaderAddresses (in string charset, in string line, out string names, out string addresses, out PRUint32 numAddresses); */
NS_IMETHODIMP nsMsgHeaderParser::ParseHeaderAddresses(const char *charset, const char *line, char **names, char **addresses, PRUint32 *numAddresses)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* void extractHeaderAddressMailboxes (in string charset, in string line, out string mailboxes); */
NS_IMETHODIMP nsMsgHeaderParser::ExtractHeaderAddressMailboxes(const char *charset, const char *line, char **mailboxes)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] void extractHeaderAddressNames (in string charset, in string line, out string userNames); */
NS_IMETHODIMP nsMsgHeaderParser::ExtractHeaderAddressNames(const char *charset, const char *line, char **userNames)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] void extractHeaderAddressName (in string charset, in string line, out string name); */
NS_IMETHODIMP nsMsgHeaderParser::ExtractHeaderAddressName(const char *charset, const char *line, char **name)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] void reformatHeaderAddresses (in string charset, in string line, out string reformattedAddress); */
NS_IMETHODIMP nsMsgHeaderParser::ReformatHeaderAddresses(const char *charset, const char *line, char **reformattedAddress)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] void removeDuplicateAddresses (in string charset, in string addrs, in string other_addrs, in PRBool removeAliasesToMe, out string newAddress); */
NS_IMETHODIMP nsMsgHeaderParser::RemoveDuplicateAddresses(const char *charset, const char *addrs, const char *other_addrs, PRBool removeAliasesToMe, char **newAddress)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] string makeFullAddress (in string charset, in string name, in string addr); */
NS_IMETHODIMP nsMsgHeaderParser::MakeFullAddress(const char *charset, const char *name, const char *addr, char **_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* wstring makeFullAddressWString (in wstring name, in wstring addr); */
NS_IMETHODIMP nsMsgHeaderParser::MakeFullAddressWString(const PRUnichar *name, const PRUnichar *addr, PRUnichar **_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* [noscript] string unquotePhraseOrAddr (in string line, in boolean preserveIntegrity); */
NS_IMETHODIMP nsMsgHeaderParser::UnquotePhraseOrAddr(const char *line, PRBool preserveIntegrity, char **_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* wstring unquotePhraseOrAddrWString (in wstring line, in boolean preserveIntegrity); */
NS_IMETHODIMP nsMsgHeaderParser::UnquotePhraseOrAddrWString(const PRUnichar *line, PRBool preserveIntegrity, PRUnichar **_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

/* wstring reformatUnquotedAddresses (in wstring line); */
NS_IMETHODIMP nsMsgHeaderParser::ReformatUnquotedAddresses(const PRUnichar *line, PRUnichar **_retval)
{
    return NS_ERROR_NOT_IMPLEMENTED;
}

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


#endif /* __gen_nsIMsgHeaderParser_h__ */
