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

#ifndef __gen_nsIMsgHeaderParser_h__
#define __gen_nsIMsgHeaderParser_h__


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

#include "js/Value.h"

#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
#define NS_MAILNEWS_MIME_HEADER_PARSER_CONTRACTID \
  "@mozilla.org/messenger/headerparser;1"

/* starting interface:    msgIAddressObject */
#define MSGIADDRESSOBJECT_IID_STR "b19f5636-ebc4-470e-b46c-98b5fc7e88c9"

#define MSGIADDRESSOBJECT_IID \
  {0xb19f5636, 0xebc4, 0x470e, \
    { 0xb4, 0x6c, 0x98, 0xb5, 0xfc, 0x7e, 0x88, 0xc9 }}

class NS_NO_VTABLE msgIAddressObject : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(MSGIADDRESSOBJECT_IID)

  /* readonly attribute AString name; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetName(nsAString& aName) = 0;

  /* readonly attribute AString email; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetEmail(nsAString& aEmail) = 0;

  /* readonly attribute jsval group; */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD GetGroup(JS::MutableHandleValue aGroup) = 0;

  /* AString toString (); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ToString(nsAString& _retval) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(msgIAddressObject, MSGIADDRESSOBJECT_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_MSGIADDRESSOBJECT \
  NS_IMETHOD GetName(nsAString& aName) override; \
  NS_IMETHOD GetEmail(nsAString& aEmail) override; \
  NS_IMETHOD GetGroup(JS::MutableHandleValue aGroup) override; \
  NS_IMETHOD ToString(nsAString& _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_MSGIADDRESSOBJECT \
  nsresult GetName(nsAString& aName); \
  nsresult GetEmail(nsAString& aEmail); \
  nsresult GetGroup(JS::MutableHandleValue aGroup); \
  nsresult ToString(nsAString& _retval); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_MSGIADDRESSOBJECT(_to) \
  NS_IMETHOD GetName(nsAString& aName) override { return _to GetName(aName); } \
  NS_IMETHOD GetEmail(nsAString& aEmail) override { return _to GetEmail(aEmail); } \
  NS_IMETHOD GetGroup(JS::MutableHandleValue aGroup) override { return _to GetGroup(aGroup); } \
  NS_IMETHOD ToString(nsAString& _retval) override { return _to ToString(_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_MSGIADDRESSOBJECT(_to) \
  NS_IMETHOD GetName(nsAString& aName) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetName(aName); } \
  NS_IMETHOD GetEmail(nsAString& aEmail) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetEmail(aEmail); } \
  NS_IMETHOD GetGroup(JS::MutableHandleValue aGroup) override { return !_to ? NS_ERROR_NULL_POINTER : _to->GetGroup(aGroup); } \
  NS_IMETHOD ToString(nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ToString(_retval); } 


/* starting interface:    nsIMsgHeaderParser */
#define NS_IMSGHEADERPARSER_IID_STR "af2f9dd1-0226-4835-b981-a4f88b5e97cc"

#define NS_IMSGHEADERPARSER_IID \
  {0xaf2f9dd1, 0x0226, 0x4835, \
    { 0xb9, 0x81, 0xa4, 0xf8, 0x8b, 0x5e, 0x97, 0xcc }}

class NS_NO_VTABLE nsIMsgHeaderParser : public nsISupports {
 public:

  NS_DECLARE_STATIC_IID_ACCESSOR(NS_IMSGHEADERPARSER_IID)

  /* void parseEncodedHeader (in ACString aEncodedHeader, in string aHeaderCharset, [optional] in bool aPreserveGroups, [optional] out unsigned long length, [array, size_is (length), retval] out msgIAddressObject addresses); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ParseEncodedHeader(const nsACString& aEncodedHeader, const char * aHeaderCharset, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) = 0;

  /* void parseDecodedHeader (in AString aDecodedHeader, [optional] in bool aPreserveGroups, [optional] out unsigned long length, [array, size_is (length), retval] out msgIAddressObject addresses); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ParseDecodedHeader(const nsAString& aDecodedHeader, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) = 0;

  /* AString makeMimeHeader ([array, size_is (aLength)] in msgIAddressObject aAddresses, in unsigned long aLength); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MakeMimeHeader(msgIAddressObject **aAddresses, uint32_t aLength, nsAString& _retval) = 0;

  /* AString extractFirstName (in AString aDecodedHeader); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ExtractFirstName(const nsAString& aDecodedHeader, nsAString& _retval) = 0;

  /* AUTF8String removeDuplicateAddresses (in AUTF8String aAddrs, [optional] in AUTF8String aOtherAddrs); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD RemoveDuplicateAddresses(const nsACString& aAddrs, const nsACString& aOtherAddrs, nsACString& _retval) = 0;

  /* msgIAddressObject makeMailboxObject (in AString aName, in AString aEmail); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MakeMailboxObject(const nsAString& aName, const nsAString& aEmail, msgIAddressObject **_retval) = 0;

  /* msgIAddressObject makeGroupObject (in AString aName, [array, size_is (aLength)] in msgIAddressObject aMembers, in unsigned long aLength); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MakeGroupObject(const nsAString& aName, msgIAddressObject **aMembers, uint32_t aLength, msgIAddressObject **_retval) = 0;

  /* void makeFromDisplayAddress (in AString aDisplayAddresses, [optional] out unsigned long count, [array, size_is (count), retval] out msgIAddressObject addresses); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MakeFromDisplayAddress(const nsAString& aDisplayAddresses, uint32_t *count, msgIAddressObject ***addresses) = 0;

  /* 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); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ParseHeadersWithArray(const char16_t * aLine, char16_t * **aEmailAddresses, char16_t * **aNames, char16_t * **aFullNames, uint32_t *count) = 0;

  /* ACString extractHeaderAddressMailboxes (in ACString aLine); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ExtractHeaderAddressMailboxes(const nsACString& aLine, nsACString& _retval) = 0;

  /* AUTF8String extractHeaderAddressNames (in AUTF8String aLine); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ExtractHeaderAddressNames(const nsACString& aLine, nsACString& _retval) = 0;

  /* AUTF8String extractHeaderAddressName (in AUTF8String aLine); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD ExtractHeaderAddressName(const nsACString& aLine, nsACString& _retval) = 0;

  /* AString makeMimeAddress (in AString aName, in AString aEmail); */
  JS_HAZ_CAN_RUN_SCRIPT NS_IMETHOD MakeMimeAddress(const nsAString& aName, const nsAString& aEmail, nsAString& _retval) = 0;

};

  NS_DEFINE_STATIC_IID_ACCESSOR(nsIMsgHeaderParser, NS_IMSGHEADERPARSER_IID)

/* Use this macro when declaring classes that implement this interface. */
#define NS_DECL_NSIMSGHEADERPARSER \
  NS_IMETHOD ParseEncodedHeader(const nsACString& aEncodedHeader, const char * aHeaderCharset, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) override; \
  NS_IMETHOD ParseDecodedHeader(const nsAString& aDecodedHeader, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) override; \
  NS_IMETHOD MakeMimeHeader(msgIAddressObject **aAddresses, uint32_t aLength, nsAString& _retval) override; \
  NS_IMETHOD ExtractFirstName(const nsAString& aDecodedHeader, nsAString& _retval) override; \
  NS_IMETHOD RemoveDuplicateAddresses(const nsACString& aAddrs, const nsACString& aOtherAddrs, nsACString& _retval) override; \
  NS_IMETHOD MakeMailboxObject(const nsAString& aName, const nsAString& aEmail, msgIAddressObject **_retval) override; \
  NS_IMETHOD MakeGroupObject(const nsAString& aName, msgIAddressObject **aMembers, uint32_t aLength, msgIAddressObject **_retval) override; \
  NS_IMETHOD MakeFromDisplayAddress(const nsAString& aDisplayAddresses, uint32_t *count, msgIAddressObject ***addresses) override; \
  NS_IMETHOD ParseHeadersWithArray(const char16_t * aLine, char16_t * **aEmailAddresses, char16_t * **aNames, char16_t * **aFullNames, uint32_t *count) override; \
  NS_IMETHOD ExtractHeaderAddressMailboxes(const nsACString& aLine, nsACString& _retval) override; \
  NS_IMETHOD ExtractHeaderAddressNames(const nsACString& aLine, nsACString& _retval) override; \
  NS_IMETHOD ExtractHeaderAddressName(const nsACString& aLine, nsACString& _retval) override; \
  NS_IMETHOD MakeMimeAddress(const nsAString& aName, const nsAString& aEmail, nsAString& _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_NSIMSGHEADERPARSER \
  nsresult ParseEncodedHeader(const nsACString& aEncodedHeader, const char * aHeaderCharset, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses); \
  nsresult ParseDecodedHeader(const nsAString& aDecodedHeader, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses); \
  nsresult MakeMimeHeader(msgIAddressObject **aAddresses, uint32_t aLength, nsAString& _retval); \
  nsresult ExtractFirstName(const nsAString& aDecodedHeader, nsAString& _retval); \
  nsresult RemoveDuplicateAddresses(const nsACString& aAddrs, const nsACString& aOtherAddrs, nsACString& _retval); \
  nsresult MakeMailboxObject(const nsAString& aName, const nsAString& aEmail, msgIAddressObject **_retval); \
  nsresult MakeGroupObject(const nsAString& aName, msgIAddressObject **aMembers, uint32_t aLength, msgIAddressObject **_retval); \
  nsresult MakeFromDisplayAddress(const nsAString& aDisplayAddresses, uint32_t *count, msgIAddressObject ***addresses); \
  nsresult ParseHeadersWithArray(const char16_t * aLine, char16_t * **aEmailAddresses, char16_t * **aNames, char16_t * **aFullNames, uint32_t *count); \
  nsresult ExtractHeaderAddressMailboxes(const nsACString& aLine, nsACString& _retval); \
  nsresult ExtractHeaderAddressNames(const nsACString& aLine, nsACString& _retval); \
  nsresult ExtractHeaderAddressName(const nsACString& aLine, nsACString& _retval); \
  nsresult MakeMimeAddress(const nsAString& aName, const nsAString& aEmail, nsAString& _retval); 

/* Use this macro to declare functions that forward the behavior of this interface to another object. */
#define NS_FORWARD_NSIMSGHEADERPARSER(_to) \
  NS_IMETHOD ParseEncodedHeader(const nsACString& aEncodedHeader, const char * aHeaderCharset, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) override { return _to ParseEncodedHeader(aEncodedHeader, aHeaderCharset, aPreserveGroups, length, addresses); } \
  NS_IMETHOD ParseDecodedHeader(const nsAString& aDecodedHeader, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) override { return _to ParseDecodedHeader(aDecodedHeader, aPreserveGroups, length, addresses); } \
  NS_IMETHOD MakeMimeHeader(msgIAddressObject **aAddresses, uint32_t aLength, nsAString& _retval) override { return _to MakeMimeHeader(aAddresses, aLength, _retval); } \
  NS_IMETHOD ExtractFirstName(const nsAString& aDecodedHeader, nsAString& _retval) override { return _to ExtractFirstName(aDecodedHeader, _retval); } \
  NS_IMETHOD RemoveDuplicateAddresses(const nsACString& aAddrs, const nsACString& aOtherAddrs, nsACString& _retval) override { return _to RemoveDuplicateAddresses(aAddrs, aOtherAddrs, _retval); } \
  NS_IMETHOD MakeMailboxObject(const nsAString& aName, const nsAString& aEmail, msgIAddressObject **_retval) override { return _to MakeMailboxObject(aName, aEmail, _retval); } \
  NS_IMETHOD MakeGroupObject(const nsAString& aName, msgIAddressObject **aMembers, uint32_t aLength, msgIAddressObject **_retval) override { return _to MakeGroupObject(aName, aMembers, aLength, _retval); } \
  NS_IMETHOD MakeFromDisplayAddress(const nsAString& aDisplayAddresses, uint32_t *count, msgIAddressObject ***addresses) override { return _to MakeFromDisplayAddress(aDisplayAddresses, count, addresses); } \
  NS_IMETHOD ParseHeadersWithArray(const char16_t * aLine, char16_t * **aEmailAddresses, char16_t * **aNames, char16_t * **aFullNames, uint32_t *count) override { return _to ParseHeadersWithArray(aLine, aEmailAddresses, aNames, aFullNames, count); } \
  NS_IMETHOD ExtractHeaderAddressMailboxes(const nsACString& aLine, nsACString& _retval) override { return _to ExtractHeaderAddressMailboxes(aLine, _retval); } \
  NS_IMETHOD ExtractHeaderAddressNames(const nsACString& aLine, nsACString& _retval) override { return _to ExtractHeaderAddressNames(aLine, _retval); } \
  NS_IMETHOD ExtractHeaderAddressName(const nsACString& aLine, nsACString& _retval) override { return _to ExtractHeaderAddressName(aLine, _retval); } \
  NS_IMETHOD MakeMimeAddress(const nsAString& aName, const nsAString& aEmail, nsAString& _retval) override { return _to MakeMimeAddress(aName, aEmail, _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 ParseEncodedHeader(const nsACString& aEncodedHeader, const char * aHeaderCharset, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ParseEncodedHeader(aEncodedHeader, aHeaderCharset, aPreserveGroups, length, addresses); } \
  NS_IMETHOD ParseDecodedHeader(const nsAString& aDecodedHeader, bool aPreserveGroups, uint32_t *length, msgIAddressObject ***addresses) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ParseDecodedHeader(aDecodedHeader, aPreserveGroups, length, addresses); } \
  NS_IMETHOD MakeMimeHeader(msgIAddressObject **aAddresses, uint32_t aLength, nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeMimeHeader(aAddresses, aLength, _retval); } \
  NS_IMETHOD ExtractFirstName(const nsAString& aDecodedHeader, nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractFirstName(aDecodedHeader, _retval); } \
  NS_IMETHOD RemoveDuplicateAddresses(const nsACString& aAddrs, const nsACString& aOtherAddrs, nsACString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->RemoveDuplicateAddresses(aAddrs, aOtherAddrs, _retval); } \
  NS_IMETHOD MakeMailboxObject(const nsAString& aName, const nsAString& aEmail, msgIAddressObject **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeMailboxObject(aName, aEmail, _retval); } \
  NS_IMETHOD MakeGroupObject(const nsAString& aName, msgIAddressObject **aMembers, uint32_t aLength, msgIAddressObject **_retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeGroupObject(aName, aMembers, aLength, _retval); } \
  NS_IMETHOD MakeFromDisplayAddress(const nsAString& aDisplayAddresses, uint32_t *count, msgIAddressObject ***addresses) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeFromDisplayAddress(aDisplayAddresses, count, addresses); } \
  NS_IMETHOD ParseHeadersWithArray(const char16_t * aLine, char16_t * **aEmailAddresses, char16_t * **aNames, char16_t * **aFullNames, uint32_t *count) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ParseHeadersWithArray(aLine, aEmailAddresses, aNames, aFullNames, count); } \
  NS_IMETHOD ExtractHeaderAddressMailboxes(const nsACString& aLine, nsACString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractHeaderAddressMailboxes(aLine, _retval); } \
  NS_IMETHOD ExtractHeaderAddressNames(const nsACString& aLine, nsACString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractHeaderAddressNames(aLine, _retval); } \
  NS_IMETHOD ExtractHeaderAddressName(const nsACString& aLine, nsACString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->ExtractHeaderAddressName(aLine, _retval); } \
  NS_IMETHOD MakeMimeAddress(const nsAString& aName, const nsAString& aEmail, nsAString& _retval) override { return !_to ? NS_ERROR_NULL_POINTER : _to->MakeMimeAddress(aName, aEmail, _retval); } 


#endif /* __gen_nsIMsgHeaderParser_h__ */