OLD | NEW |
(Empty) | |
| 1 /* |
| 2 * DO NOT EDIT. THIS FILE IS GENERATED FROM c:/builds/tinderbox/XR-Mozilla1.8.0
-Release/WINNT_5.2_Depend/mozilla/xpcom/components/nsICategoryManager.idl |
| 3 */ |
| 4 |
| 5 #ifndef __gen_nsICategoryManager_h__ |
| 6 #define __gen_nsICategoryManager_h__ |
| 7 |
| 8 |
| 9 #ifndef __gen_nsISupports_h__ |
| 10 #include "nsISupports.h" |
| 11 #endif |
| 12 |
| 13 #ifndef __gen_nsISimpleEnumerator_h__ |
| 14 #include "nsISimpleEnumerator.h" |
| 15 #endif |
| 16 |
| 17 /* For IDL files that don't want to include root IDL files. */ |
| 18 #ifndef NS_NO_VTABLE |
| 19 #define NS_NO_VTABLE |
| 20 #endif |
| 21 |
| 22 /* starting interface: nsICategoryManager */ |
| 23 #define NS_ICATEGORYMANAGER_IID_STR "3275b2cd-af6d-429a-80d7-f0c5120342ac" |
| 24 |
| 25 #define NS_ICATEGORYMANAGER_IID \ |
| 26 {0x3275b2cd, 0xaf6d, 0x429a, \ |
| 27 { 0x80, 0xd7, 0xf0, 0xc5, 0x12, 0x03, 0x42, 0xac }} |
| 28 |
| 29 class NS_NO_VTABLE nsICategoryManager : public nsISupports { |
| 30 public: |
| 31 |
| 32 NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICATEGORYMANAGER_IID) |
| 33 |
| 34 /** |
| 35 * Get the value for the given category's entry. |
| 36 * @param aCategory The name of the category ("protocol") |
| 37 * @param aEntry The entry you're looking for ("http") |
| 38 * @return The value. |
| 39 */ |
| 40 /* string getCategoryEntry (in string aCategory, in string aEntry); */ |
| 41 NS_IMETHOD GetCategoryEntry(const char *aCategory, const char *aEntry, char **
_retval) = 0; |
| 42 |
| 43 /** |
| 44 * Add an entry to a category. |
| 45 * @param aCategory The name of the category ("protocol") |
| 46 * @param aEntry The entry to be added ("http") |
| 47 * @param aValue The value for the entry ("moz.httprulez.1") |
| 48 * @param aPersist Should this data persist between invocations? |
| 49 * @param aReplace Should we replace an existing entry? |
| 50 * @return Previous entry, if any |
| 51 */ |
| 52 /* string addCategoryEntry (in string aCategory, in string aEntry, in string a
Value, in boolean aPersist, in boolean aReplace); */ |
| 53 NS_IMETHOD AddCategoryEntry(const char *aCategory, const char *aEntry, const c
har *aValue, PRBool aPersist, PRBool aReplace, char **_retval) = 0; |
| 54 |
| 55 /** |
| 56 * Delete an entry from the category. |
| 57 * @param aCategory The name of the category ("protocol") |
| 58 * @param aEntry The entry to be added ("http") |
| 59 * @param aPersist Delete persistent data from registry, if present? |
| 60 */ |
| 61 /* void deleteCategoryEntry (in string aCategory, in string aEntry, in boolean
aPersist); */ |
| 62 NS_IMETHOD DeleteCategoryEntry(const char *aCategory, const char *aEntry, PRBo
ol aPersist) = 0; |
| 63 |
| 64 /** |
| 65 * Delete a category and all entries. |
| 66 * @param aCategory The category to be deleted. |
| 67 */ |
| 68 /* void deleteCategory (in string aCategory); */ |
| 69 NS_IMETHOD DeleteCategory(const char *aCategory) = 0; |
| 70 |
| 71 /** |
| 72 * Enumerate the entries in a category. |
| 73 * @param aCategory The category to be enumerated. |
| 74 * @return a simple enumerator, each result QIs to |
| 75 * nsISupportsCString. |
| 76 */ |
| 77 /* nsISimpleEnumerator enumerateCategory (in string aCategory); */ |
| 78 NS_IMETHOD EnumerateCategory(const char *aCategory, nsISimpleEnumerator **_ret
val) = 0; |
| 79 |
| 80 /** |
| 81 * Enumerate all existing categories |
| 82 * @param aCategory The category to be enumerated. |
| 83 * @return a simple enumerator, each result QIs to |
| 84 * nsISupportsCString. |
| 85 */ |
| 86 /* nsISimpleEnumerator enumerateCategories (); */ |
| 87 NS_IMETHOD EnumerateCategories(nsISimpleEnumerator **_retval) = 0; |
| 88 |
| 89 }; |
| 90 |
| 91 /* Use this macro when declaring classes that implement this interface. */ |
| 92 #define NS_DECL_NSICATEGORYMANAGER \ |
| 93 NS_IMETHOD GetCategoryEntry(const char *aCategory, const char *aEntry, char **
_retval); \ |
| 94 NS_IMETHOD AddCategoryEntry(const char *aCategory, const char *aEntry, const c
har *aValue, PRBool aPersist, PRBool aReplace, char **_retval); \ |
| 95 NS_IMETHOD DeleteCategoryEntry(const char *aCategory, const char *aEntry, PRBo
ol aPersist); \ |
| 96 NS_IMETHOD DeleteCategory(const char *aCategory); \ |
| 97 NS_IMETHOD EnumerateCategory(const char *aCategory, nsISimpleEnumerator **_ret
val); \ |
| 98 NS_IMETHOD EnumerateCategories(nsISimpleEnumerator **_retval); |
| 99 |
| 100 /* Use this macro to declare functions that forward the behavior of this interfa
ce to another object. */ |
| 101 #define NS_FORWARD_NSICATEGORYMANAGER(_to) \ |
| 102 NS_IMETHOD GetCategoryEntry(const char *aCategory, const char *aEntry, char **
_retval) { return _to GetCategoryEntry(aCategory, aEntry, _retval); } \ |
| 103 NS_IMETHOD AddCategoryEntry(const char *aCategory, const char *aEntry, const c
har *aValue, PRBool aPersist, PRBool aReplace, char **_retval) { return _to AddC
ategoryEntry(aCategory, aEntry, aValue, aPersist, aReplace, _retval); } \ |
| 104 NS_IMETHOD DeleteCategoryEntry(const char *aCategory, const char *aEntry, PRBo
ol aPersist) { return _to DeleteCategoryEntry(aCategory, aEntry, aPersist); } \ |
| 105 NS_IMETHOD DeleteCategory(const char *aCategory) { return _to DeleteCategory(a
Category); } \ |
| 106 NS_IMETHOD EnumerateCategory(const char *aCategory, nsISimpleEnumerator **_ret
val) { return _to EnumerateCategory(aCategory, _retval); } \ |
| 107 NS_IMETHOD EnumerateCategories(nsISimpleEnumerator **_retval) { return _to Enu
merateCategories(_retval); } |
| 108 |
| 109 /* Use this macro to declare functions that forward the behavior of this interfa
ce to another object in a safe way. */ |
| 110 #define NS_FORWARD_SAFE_NSICATEGORYMANAGER(_to) \ |
| 111 NS_IMETHOD GetCategoryEntry(const char *aCategory, const char *aEntry, char **
_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetCategoryEntry(aCategory
, aEntry, _retval); } \ |
| 112 NS_IMETHOD AddCategoryEntry(const char *aCategory, const char *aEntry, const c
har *aValue, PRBool aPersist, PRBool aReplace, char **_retval) { return !_to ? N
S_ERROR_NULL_POINTER : _to->AddCategoryEntry(aCategory, aEntry, aValue, aPersist
, aReplace, _retval); } \ |
| 113 NS_IMETHOD DeleteCategoryEntry(const char *aCategory, const char *aEntry, PRBo
ol aPersist) { return !_to ? NS_ERROR_NULL_POINTER : _to->DeleteCategoryEntry(aC
ategory, aEntry, aPersist); } \ |
| 114 NS_IMETHOD DeleteCategory(const char *aCategory) { return !_to ? NS_ERROR_NULL
_POINTER : _to->DeleteCategory(aCategory); } \ |
| 115 NS_IMETHOD EnumerateCategory(const char *aCategory, nsISimpleEnumerator **_ret
val) { return !_to ? NS_ERROR_NULL_POINTER : _to->EnumerateCategory(aCategory, _
retval); } \ |
| 116 NS_IMETHOD EnumerateCategories(nsISimpleEnumerator **_retval) { return !_to ?
NS_ERROR_NULL_POINTER : _to->EnumerateCategories(_retval); } |
| 117 |
| 118 #if 0 |
| 119 /* Use the code below as a template for the implementation class for this interf
ace. */ |
| 120 |
| 121 /* Header file */ |
| 122 class nsCategoryManager : public nsICategoryManager |
| 123 { |
| 124 public: |
| 125 NS_DECL_ISUPPORTS |
| 126 NS_DECL_NSICATEGORYMANAGER |
| 127 |
| 128 nsCategoryManager(); |
| 129 |
| 130 private: |
| 131 ~nsCategoryManager(); |
| 132 |
| 133 protected: |
| 134 /* additional members */ |
| 135 }; |
| 136 |
| 137 /* Implementation file */ |
| 138 NS_IMPL_ISUPPORTS1(nsCategoryManager, nsICategoryManager) |
| 139 |
| 140 nsCategoryManager::nsCategoryManager() |
| 141 { |
| 142 /* member initializers and constructor code */ |
| 143 } |
| 144 |
| 145 nsCategoryManager::~nsCategoryManager() |
| 146 { |
| 147 /* destructor code */ |
| 148 } |
| 149 |
| 150 /* string getCategoryEntry (in string aCategory, in string aEntry); */ |
| 151 NS_IMETHODIMP nsCategoryManager::GetCategoryEntry(const char *aCategory, const c
har *aEntry, char **_retval) |
| 152 { |
| 153 return NS_ERROR_NOT_IMPLEMENTED; |
| 154 } |
| 155 |
| 156 /* string addCategoryEntry (in string aCategory, in string aEntry, in string aVa
lue, in boolean aPersist, in boolean aReplace); */ |
| 157 NS_IMETHODIMP nsCategoryManager::AddCategoryEntry(const char *aCategory, const c
har *aEntry, const char *aValue, PRBool aPersist, PRBool aReplace, char **_retva
l) |
| 158 { |
| 159 return NS_ERROR_NOT_IMPLEMENTED; |
| 160 } |
| 161 |
| 162 /* void deleteCategoryEntry (in string aCategory, in string aEntry, in boolean a
Persist); */ |
| 163 NS_IMETHODIMP nsCategoryManager::DeleteCategoryEntry(const char *aCategory, cons
t char *aEntry, PRBool aPersist) |
| 164 { |
| 165 return NS_ERROR_NOT_IMPLEMENTED; |
| 166 } |
| 167 |
| 168 /* void deleteCategory (in string aCategory); */ |
| 169 NS_IMETHODIMP nsCategoryManager::DeleteCategory(const char *aCategory) |
| 170 { |
| 171 return NS_ERROR_NOT_IMPLEMENTED; |
| 172 } |
| 173 |
| 174 /* nsISimpleEnumerator enumerateCategory (in string aCategory); */ |
| 175 NS_IMETHODIMP nsCategoryManager::EnumerateCategory(const char *aCategory, nsISim
pleEnumerator **_retval) |
| 176 { |
| 177 return NS_ERROR_NOT_IMPLEMENTED; |
| 178 } |
| 179 |
| 180 /* nsISimpleEnumerator enumerateCategories (); */ |
| 181 NS_IMETHODIMP nsCategoryManager::EnumerateCategories(nsISimpleEnumerator **_retv
al) |
| 182 { |
| 183 return NS_ERROR_NOT_IMPLEMENTED; |
| 184 } |
| 185 |
| 186 /* End of implementation class template. */ |
| 187 #endif |
| 188 |
| 189 |
| 190 #endif /* __gen_nsICategoryManager_h__ */ |
OLD | NEW |