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/modules/libpref/public/nsIPrefBranch.idl |
| 3 */ |
| 4 |
| 5 #ifndef __gen_nsIPrefBranch_h__ |
| 6 #define __gen_nsIPrefBranch_h__ |
| 7 |
| 8 |
| 9 #ifndef __gen_nsISupports_h__ |
| 10 #include "nsISupports.h" |
| 11 #endif |
| 12 |
| 13 /* For IDL files that don't want to include root IDL files. */ |
| 14 #ifndef NS_NO_VTABLE |
| 15 #define NS_NO_VTABLE |
| 16 #endif |
| 17 |
| 18 /* starting interface: nsIPrefBranch */ |
| 19 #define NS_IPREFBRANCH_IID_STR "56c35506-f14b-11d3-99d3-ddbfac2ccf65" |
| 20 |
| 21 #define NS_IPREFBRANCH_IID \ |
| 22 {0x56c35506, 0xf14b, 0x11d3, \ |
| 23 { 0x99, 0xd3, 0xdd, 0xbf, 0xac, 0x2c, 0xcf, 0x65 }} |
| 24 |
| 25 /** |
| 26 * The nsIPrefBranch interface is used to manipulate the preferences data. This |
| 27 * object may be obtained from the preferences service (nsIPrefService) and |
| 28 * used to get and set default and/or user preferences across the application. |
| 29 * |
| 30 * This object is created with a "root" value which describes the base point in |
| 31 * the preferences "tree" from which this "branch" stems. Preferences are |
| 32 * accessed off of this root by using just the final portion of the preference. |
| 33 * For example, if this object is created with the root "browser.startup.", |
| 34 * the preferences "browser.startup.page", "browser.startup.homepage", |
| 35 * and "browser.startup.homepage_override" can be accessed by simply passing |
| 36 * "page", "homepage", or "homepage_override" to the various Get/Set methods. |
| 37 * |
| 38 * @see nsIPrefService |
| 39 * |
| 40 * @status FROZEN |
| 41 */ |
| 42 class NS_NO_VTABLE nsIPrefBranch : public nsISupports { |
| 43 public: |
| 44 |
| 45 NS_DEFINE_STATIC_IID_ACCESSOR(NS_IPREFBRANCH_IID) |
| 46 |
| 47 /** |
| 48 * Values describing the basic preference types. |
| 49 * |
| 50 * @see getPrefType |
| 51 */ |
| 52 enum { PREF_INVALID = 0 }; |
| 53 |
| 54 enum { PREF_STRING = 32 }; |
| 55 |
| 56 enum { PREF_INT = 64 }; |
| 57 |
| 58 enum { PREF_BOOL = 128 }; |
| 59 |
| 60 /** |
| 61 * Called to get the root on which this branch is based, such as |
| 62 * "browser.startup." |
| 63 */ |
| 64 /* readonly attribute string root; */ |
| 65 NS_IMETHOD GetRoot(char * *aRoot) = 0; |
| 66 |
| 67 /** |
| 68 * Called to determine the type of a specific preference. |
| 69 * |
| 70 * @param aPrefName The preference to get the type of. |
| 71 * |
| 72 * @return long A value representing the type of the preference. This |
| 73 * value will be PREF_STRING, PREF_INT, or PREF_BOOL. |
| 74 */ |
| 75 /* long getPrefType (in string aPrefName); */ |
| 76 NS_IMETHOD GetPrefType(const char *aPrefName, PRInt32 *_retval) = 0; |
| 77 |
| 78 /** |
| 79 * Called to get the state of an individual boolean preference. |
| 80 * |
| 81 * @param aPrefName The boolean preference to get the state of. |
| 82 * |
| 83 * @return boolean The value of the requested boolean preference. |
| 84 * |
| 85 * @see setBoolPref |
| 86 */ |
| 87 /* boolean getBoolPref (in string aPrefName); */ |
| 88 NS_IMETHOD GetBoolPref(const char *aPrefName, PRBool *_retval) = 0; |
| 89 |
| 90 /** |
| 91 * Called to set the state of an individual boolean preference. |
| 92 * |
| 93 * @param aPrefName The boolean preference to set the state of. |
| 94 * @param aValue The boolean value to set the preference to. |
| 95 * |
| 96 * @return NS_OK The value was successfully set. |
| 97 * @return Other The value was not set or is the wrong type. |
| 98 * |
| 99 * @see getBoolPref |
| 100 */ |
| 101 /* void setBoolPref (in string aPrefName, in long aValue); */ |
| 102 NS_IMETHOD SetBoolPref(const char *aPrefName, PRInt32 aValue) = 0; |
| 103 |
| 104 /** |
| 105 * Called to get the state of an individual string preference. |
| 106 * |
| 107 * @param aPrefName The string preference to retrieve. |
| 108 * |
| 109 * @return string The value of the requested string preference. |
| 110 * |
| 111 * @see setCharPref |
| 112 */ |
| 113 /* string getCharPref (in string aPrefName); */ |
| 114 NS_IMETHOD GetCharPref(const char *aPrefName, char **_retval) = 0; |
| 115 |
| 116 /** |
| 117 * Called to set the state of an individual string preference. |
| 118 * |
| 119 * @param aPrefName The string preference to set. |
| 120 * @param aValue The string value to set the preference to. |
| 121 * |
| 122 * @return NS_OK The value was successfully set. |
| 123 * @return Other The value was not set or is the wrong type. |
| 124 * |
| 125 * @see getCharPref |
| 126 */ |
| 127 /* void setCharPref (in string aPrefName, in string aValue); */ |
| 128 NS_IMETHOD SetCharPref(const char *aPrefName, const char *aValue) = 0; |
| 129 |
| 130 /** |
| 131 * Called to get the state of an individual integer preference. |
| 132 * |
| 133 * @param aPrefName The integer preference to get the value of. |
| 134 * |
| 135 * @return long The value of the requested integer preference. |
| 136 * |
| 137 * @see setIntPref |
| 138 */ |
| 139 /* long getIntPref (in string aPrefName); */ |
| 140 NS_IMETHOD GetIntPref(const char *aPrefName, PRInt32 *_retval) = 0; |
| 141 |
| 142 /** |
| 143 * Called to set the state of an individual integer preference. |
| 144 * |
| 145 * @param aPrefName The integer preference to set the value of. |
| 146 * @param aValue The integer value to set the preference to. |
| 147 * |
| 148 * @return NS_OK The value was successfully set. |
| 149 * @return Other The value was not set or is the wrong type. |
| 150 * |
| 151 * @see getIntPref |
| 152 */ |
| 153 /* void setIntPref (in string aPrefName, in long aValue); */ |
| 154 NS_IMETHOD SetIntPref(const char *aPrefName, PRInt32 aValue) = 0; |
| 155 |
| 156 /** |
| 157 * Called to get the state of an individual complex preference. A complex |
| 158 * preference is a preference which represents an XPCOM object that can not |
| 159 * be easily represented using a standard boolean, integer or string value. |
| 160 * |
| 161 * @param aPrefName The complex preference to get the value of. |
| 162 * @param aType The XPCOM interface that this complex preference |
| 163 * represents. Interfaces currently supported are: |
| 164 * - nsILocalFile |
| 165 * - nsISupportsString (UniChar) |
| 166 * - nsIPrefLocalizedString (Localized UniChar) |
| 167 * - nsIFileSpec (deprecated - to be removed eventually) |
| 168 * @param aValue The XPCOM object into which to the complex preference |
| 169 * value should be retrieved. |
| 170 * |
| 171 * @return NS_OK The value was successfully retrieved. |
| 172 * @return Other The value does not exist or is the wrong type. |
| 173 * |
| 174 * @see setComplexValue |
| 175 */ |
| 176 /* void getComplexValue (in string aPrefName, in nsIIDRef aType, [iid_is (aTyp
e), retval] out nsQIResult aValue); */ |
| 177 NS_IMETHOD GetComplexValue(const char *aPrefName, const nsIID & aType, void *
*aValue) = 0; |
| 178 |
| 179 /** |
| 180 * Called to set the state of an individual complex preference. A complex |
| 181 * preference is a preference which represents an XPCOM object that can not |
| 182 * be easily represented using a standard boolean, integer or string value. |
| 183 * |
| 184 * @param aPrefName The complex preference to set the value of. |
| 185 * @param aType The XPCOM interface that this complex preference |
| 186 * represents. Interfaces currently supported are: |
| 187 * - nsILocalFile |
| 188 * - nsISupportsString (UniChar) |
| 189 * - nsIPrefLocalizedString (Localized UniChar) |
| 190 * - nsIFileSpec (deprecated - to be removed eventually) |
| 191 * @param aValue The XPCOM object from which to set the complex preference |
| 192 * value. |
| 193 * |
| 194 * @return NS_OK The value was successfully set. |
| 195 * @return Other The value was not set or is the wrong type. |
| 196 * |
| 197 * @see getComplexValue |
| 198 */ |
| 199 /* void setComplexValue (in string aPrefName, in nsIIDRef aType, in nsISupport
s aValue); */ |
| 200 NS_IMETHOD SetComplexValue(const char *aPrefName, const nsIID & aType, nsISupp
orts *aValue) = 0; |
| 201 |
| 202 /** |
| 203 * Called to clear a user set value from a specific preference. This will, in |
| 204 * effect, reset the value to the default value. If no default value exists |
| 205 * the preference will cease to exist. |
| 206 * |
| 207 * @param aPrefName The preference to be cleared. |
| 208 * |
| 209 * @note |
| 210 * This method does nothing if this object is a default branch. |
| 211 * |
| 212 * @return NS_OK The user preference was successfully cleared. |
| 213 * @return Other The preference does not exist or have a user set value. |
| 214 */ |
| 215 /* void clearUserPref (in string aPrefName); */ |
| 216 NS_IMETHOD ClearUserPref(const char *aPrefName) = 0; |
| 217 |
| 218 /** |
| 219 * Called to lock a specific preference. Locking a preference will cause the |
| 220 * preference service to always return the default value regardless of |
| 221 * whether there is a user set value or not. |
| 222 * |
| 223 * @param aPrefName The preference to be locked. |
| 224 * |
| 225 * @note |
| 226 * This method can be called on either a default or user branch but, in |
| 227 * effect, always operates on the default branch. |
| 228 * |
| 229 * @return NS_OK The preference was successfully locked. |
| 230 * @return Other The preference does not exist or an error occurred. |
| 231 * |
| 232 * @see unlockPref |
| 233 */ |
| 234 /* void lockPref (in string aPrefName); */ |
| 235 NS_IMETHOD LockPref(const char *aPrefName) = 0; |
| 236 |
| 237 /** |
| 238 * Called to check if a specific preference has a user value associated to |
| 239 * it. |
| 240 * |
| 241 * @param aPrefName The preference to be tested. |
| 242 * |
| 243 * @note |
| 244 * This method can be called on either a default or user branch but, in |
| 245 * effect, always operates on the user branch. |
| 246 * |
| 247 * @return boolean true The preference has a user set value. |
| 248 * false The preference only has a default value. |
| 249 */ |
| 250 /* boolean prefHasUserValue (in string aPrefName); */ |
| 251 NS_IMETHOD PrefHasUserValue(const char *aPrefName, PRBool *_retval) = 0; |
| 252 |
| 253 /** |
| 254 * Called to check if a specific preference is locked. If a preference is |
| 255 * locked calling its Get method will always return the default value. |
| 256 * |
| 257 * @param aPrefName The preference to be tested. |
| 258 * |
| 259 * @note |
| 260 * This method can be called on either a default or user branch but, in |
| 261 * effect, always operates on the default branch. |
| 262 * |
| 263 * @return boolean true The preference is locked. |
| 264 * false The preference is not locked. |
| 265 * |
| 266 * @see lockPref |
| 267 * @see unlockPref |
| 268 */ |
| 269 /* boolean prefIsLocked (in string aPrefName); */ |
| 270 NS_IMETHOD PrefIsLocked(const char *aPrefName, PRBool *_retval) = 0; |
| 271 |
| 272 /** |
| 273 * Called to unlock a specific preference. Unlocking a previously locked |
| 274 * preference allows the preference service to once again return the user set |
| 275 * value of the preference. |
| 276 * |
| 277 * @param aPrefName The preference to be unlocked. |
| 278 * |
| 279 * @note |
| 280 * This method can be called on either a default or user branch but, in |
| 281 * effect, always operates on the default branch. |
| 282 * |
| 283 * @return NS_OK The preference was successfully unlocked. |
| 284 * @return Other The preference does not exist or an error occurred. |
| 285 * |
| 286 * @see lockPref |
| 287 */ |
| 288 /* void unlockPref (in string aPrefName); */ |
| 289 NS_IMETHOD UnlockPref(const char *aPrefName) = 0; |
| 290 |
| 291 /** |
| 292 * Called to remove all of the preferences referenced by this branch. |
| 293 * |
| 294 * @param aStartingAt The point on the branch at which to start the deleting |
| 295 * preferences. Pass in "" to remove all preferences |
| 296 * referenced by this branch. |
| 297 * |
| 298 * @note |
| 299 * This method can be called on either a default or user branch but, in |
| 300 * effect, always operates on both. |
| 301 * |
| 302 * @return NS_OK The preference(s) were successfully removed. |
| 303 * @return Other The preference(s) do not exist or an error occurred. |
| 304 */ |
| 305 /* void deleteBranch (in string aStartingAt); */ |
| 306 NS_IMETHOD DeleteBranch(const char *aStartingAt) = 0; |
| 307 |
| 308 /** |
| 309 * Returns an array of strings representing the child preferences of the |
| 310 * root of this branch. |
| 311 * |
| 312 * @param aStartingAt The point on the branch at which to start enumerating |
| 313 * the child preferences. Pass in "" to enumerate all |
| 314 * preferences referenced by this branch. |
| 315 * @param aCount Receives the number of elements in the array. |
| 316 * @param aChildArray Receives the array of child preferences. |
| 317 * |
| 318 * @note |
| 319 * This method can be called on either a default or user branch but, in |
| 320 * effect, always operates on both. |
| 321 * |
| 322 * @return NS_OK The preference list was successfully retrieved. |
| 323 * @return Other The preference(s) do not exist or an error occurred. |
| 324 */ |
| 325 /* void getChildList (in string aStartingAt, out unsigned long aCount, [array,
size_is (aCount), retval] out string aChildArray); */ |
| 326 NS_IMETHOD GetChildList(const char *aStartingAt, PRUint32 *aCount, char ***aCh
ildArray) = 0; |
| 327 |
| 328 /** |
| 329 * Called to reset all of the preferences referenced by this branch to their |
| 330 * default values. |
| 331 * |
| 332 * @param aStartingAt The point on the branch at which to start the resetting |
| 333 * preferences to their default values. Pass in "" to |
| 334 * reset all preferences referenced by this branch. |
| 335 * |
| 336 * @note |
| 337 * This method can be called on either a default or user branch but, in |
| 338 * effect, always operates on the user branch. |
| 339 * |
| 340 * @return NS_OK The preference(s) were successfully reset. |
| 341 * @return Other The preference(s) do not exist or an error occurred. |
| 342 */ |
| 343 /* void resetBranch (in string aStartingAt); */ |
| 344 NS_IMETHOD ResetBranch(const char *aStartingAt) = 0; |
| 345 |
| 346 }; |
| 347 |
| 348 /* Use this macro when declaring classes that implement this interface. */ |
| 349 #define NS_DECL_NSIPREFBRANCH \ |
| 350 NS_IMETHOD GetRoot(char * *aRoot); \ |
| 351 NS_IMETHOD GetPrefType(const char *aPrefName, PRInt32 *_retval); \ |
| 352 NS_IMETHOD GetBoolPref(const char *aPrefName, PRBool *_retval); \ |
| 353 NS_IMETHOD SetBoolPref(const char *aPrefName, PRInt32 aValue); \ |
| 354 NS_IMETHOD GetCharPref(const char *aPrefName, char **_retval); \ |
| 355 NS_IMETHOD SetCharPref(const char *aPrefName, const char *aValue); \ |
| 356 NS_IMETHOD GetIntPref(const char *aPrefName, PRInt32 *_retval); \ |
| 357 NS_IMETHOD SetIntPref(const char *aPrefName, PRInt32 aValue); \ |
| 358 NS_IMETHOD GetComplexValue(const char *aPrefName, const nsIID & aType, void *
*aValue); \ |
| 359 NS_IMETHOD SetComplexValue(const char *aPrefName, const nsIID & aType, nsISupp
orts *aValue); \ |
| 360 NS_IMETHOD ClearUserPref(const char *aPrefName); \ |
| 361 NS_IMETHOD LockPref(const char *aPrefName); \ |
| 362 NS_IMETHOD PrefHasUserValue(const char *aPrefName, PRBool *_retval); \ |
| 363 NS_IMETHOD PrefIsLocked(const char *aPrefName, PRBool *_retval); \ |
| 364 NS_IMETHOD UnlockPref(const char *aPrefName); \ |
| 365 NS_IMETHOD DeleteBranch(const char *aStartingAt); \ |
| 366 NS_IMETHOD GetChildList(const char *aStartingAt, PRUint32 *aCount, char ***aCh
ildArray); \ |
| 367 NS_IMETHOD ResetBranch(const char *aStartingAt); |
| 368 |
| 369 /* Use this macro to declare functions that forward the behavior of this interfa
ce to another object. */ |
| 370 #define NS_FORWARD_NSIPREFBRANCH(_to) \ |
| 371 NS_IMETHOD GetRoot(char * *aRoot) { return _to GetRoot(aRoot); } \ |
| 372 NS_IMETHOD GetPrefType(const char *aPrefName, PRInt32 *_retval) { return _to G
etPrefType(aPrefName, _retval); } \ |
| 373 NS_IMETHOD GetBoolPref(const char *aPrefName, PRBool *_retval) { return _to Ge
tBoolPref(aPrefName, _retval); } \ |
| 374 NS_IMETHOD SetBoolPref(const char *aPrefName, PRInt32 aValue) { return _to Set
BoolPref(aPrefName, aValue); } \ |
| 375 NS_IMETHOD GetCharPref(const char *aPrefName, char **_retval) { return _to Get
CharPref(aPrefName, _retval); } \ |
| 376 NS_IMETHOD SetCharPref(const char *aPrefName, const char *aValue) { return _to
SetCharPref(aPrefName, aValue); } \ |
| 377 NS_IMETHOD GetIntPref(const char *aPrefName, PRInt32 *_retval) { return _to Ge
tIntPref(aPrefName, _retval); } \ |
| 378 NS_IMETHOD SetIntPref(const char *aPrefName, PRInt32 aValue) { return _to SetI
ntPref(aPrefName, aValue); } \ |
| 379 NS_IMETHOD GetComplexValue(const char *aPrefName, const nsIID & aType, void *
*aValue) { return _to GetComplexValue(aPrefName, aType, aValue); } \ |
| 380 NS_IMETHOD SetComplexValue(const char *aPrefName, const nsIID & aType, nsISupp
orts *aValue) { return _to SetComplexValue(aPrefName, aType, aValue); } \ |
| 381 NS_IMETHOD ClearUserPref(const char *aPrefName) { return _to ClearUserPref(aPr
efName); } \ |
| 382 NS_IMETHOD LockPref(const char *aPrefName) { return _to LockPref(aPrefName); }
\ |
| 383 NS_IMETHOD PrefHasUserValue(const char *aPrefName, PRBool *_retval) { return _
to PrefHasUserValue(aPrefName, _retval); } \ |
| 384 NS_IMETHOD PrefIsLocked(const char *aPrefName, PRBool *_retval) { return _to P
refIsLocked(aPrefName, _retval); } \ |
| 385 NS_IMETHOD UnlockPref(const char *aPrefName) { return _to UnlockPref(aPrefName
); } \ |
| 386 NS_IMETHOD DeleteBranch(const char *aStartingAt) { return _to DeleteBranch(aSt
artingAt); } \ |
| 387 NS_IMETHOD GetChildList(const char *aStartingAt, PRUint32 *aCount, char ***aCh
ildArray) { return _to GetChildList(aStartingAt, aCount, aChildArray); } \ |
| 388 NS_IMETHOD ResetBranch(const char *aStartingAt) { return _to ResetBranch(aStar
tingAt); } |
| 389 |
| 390 /* Use this macro to declare functions that forward the behavior of this interfa
ce to another object in a safe way. */ |
| 391 #define NS_FORWARD_SAFE_NSIPREFBRANCH(_to) \ |
| 392 NS_IMETHOD GetRoot(char * *aRoot) { return !_to ? NS_ERROR_NULL_POINTER : _to-
>GetRoot(aRoot); } \ |
| 393 NS_IMETHOD GetPrefType(const char *aPrefName, PRInt32 *_retval) { return !_to
? NS_ERROR_NULL_POINTER : _to->GetPrefType(aPrefName, _retval); } \ |
| 394 NS_IMETHOD GetBoolPref(const char *aPrefName, PRBool *_retval) { return !_to ?
NS_ERROR_NULL_POINTER : _to->GetBoolPref(aPrefName, _retval); } \ |
| 395 NS_IMETHOD SetBoolPref(const char *aPrefName, PRInt32 aValue) { return !_to ?
NS_ERROR_NULL_POINTER : _to->SetBoolPref(aPrefName, aValue); } \ |
| 396 NS_IMETHOD GetCharPref(const char *aPrefName, char **_retval) { return !_to ?
NS_ERROR_NULL_POINTER : _to->GetCharPref(aPrefName, _retval); } \ |
| 397 NS_IMETHOD SetCharPref(const char *aPrefName, const char *aValue) { return !_t
o ? NS_ERROR_NULL_POINTER : _to->SetCharPref(aPrefName, aValue); } \ |
| 398 NS_IMETHOD GetIntPref(const char *aPrefName, PRInt32 *_retval) { return !_to ?
NS_ERROR_NULL_POINTER : _to->GetIntPref(aPrefName, _retval); } \ |
| 399 NS_IMETHOD SetIntPref(const char *aPrefName, PRInt32 aValue) { return !_to ? N
S_ERROR_NULL_POINTER : _to->SetIntPref(aPrefName, aValue); } \ |
| 400 NS_IMETHOD GetComplexValue(const char *aPrefName, const nsIID & aType, void *
*aValue) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetComplexValue(aPrefName,
aType, aValue); } \ |
| 401 NS_IMETHOD SetComplexValue(const char *aPrefName, const nsIID & aType, nsISupp
orts *aValue) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetComplexValue(aPref
Name, aType, aValue); } \ |
| 402 NS_IMETHOD ClearUserPref(const char *aPrefName) { return !_to ? NS_ERROR_NULL_
POINTER : _to->ClearUserPref(aPrefName); } \ |
| 403 NS_IMETHOD LockPref(const char *aPrefName) { return !_to ? NS_ERROR_NULL_POINT
ER : _to->LockPref(aPrefName); } \ |
| 404 NS_IMETHOD PrefHasUserValue(const char *aPrefName, PRBool *_retval) { return !
_to ? NS_ERROR_NULL_POINTER : _to->PrefHasUserValue(aPrefName, _retval); } \ |
| 405 NS_IMETHOD PrefIsLocked(const char *aPrefName, PRBool *_retval) { return !_to
? NS_ERROR_NULL_POINTER : _to->PrefIsLocked(aPrefName, _retval); } \ |
| 406 NS_IMETHOD UnlockPref(const char *aPrefName) { return !_to ? NS_ERROR_NULL_POI
NTER : _to->UnlockPref(aPrefName); } \ |
| 407 NS_IMETHOD DeleteBranch(const char *aStartingAt) { return !_to ? NS_ERROR_NULL
_POINTER : _to->DeleteBranch(aStartingAt); } \ |
| 408 NS_IMETHOD GetChildList(const char *aStartingAt, PRUint32 *aCount, char ***aCh
ildArray) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetChildList(aStartingAt,
aCount, aChildArray); } \ |
| 409 NS_IMETHOD ResetBranch(const char *aStartingAt) { return !_to ? NS_ERROR_NULL_
POINTER : _to->ResetBranch(aStartingAt); } |
| 410 |
| 411 #if 0 |
| 412 /* Use the code below as a template for the implementation class for this interf
ace. */ |
| 413 |
| 414 /* Header file */ |
| 415 class nsPrefBranch : public nsIPrefBranch |
| 416 { |
| 417 public: |
| 418 NS_DECL_ISUPPORTS |
| 419 NS_DECL_NSIPREFBRANCH |
| 420 |
| 421 nsPrefBranch(); |
| 422 |
| 423 private: |
| 424 ~nsPrefBranch(); |
| 425 |
| 426 protected: |
| 427 /* additional members */ |
| 428 }; |
| 429 |
| 430 /* Implementation file */ |
| 431 NS_IMPL_ISUPPORTS1(nsPrefBranch, nsIPrefBranch) |
| 432 |
| 433 nsPrefBranch::nsPrefBranch() |
| 434 { |
| 435 /* member initializers and constructor code */ |
| 436 } |
| 437 |
| 438 nsPrefBranch::~nsPrefBranch() |
| 439 { |
| 440 /* destructor code */ |
| 441 } |
| 442 |
| 443 /* readonly attribute string root; */ |
| 444 NS_IMETHODIMP nsPrefBranch::GetRoot(char * *aRoot) |
| 445 { |
| 446 return NS_ERROR_NOT_IMPLEMENTED; |
| 447 } |
| 448 |
| 449 /* long getPrefType (in string aPrefName); */ |
| 450 NS_IMETHODIMP nsPrefBranch::GetPrefType(const char *aPrefName, PRInt32 *_retval) |
| 451 { |
| 452 return NS_ERROR_NOT_IMPLEMENTED; |
| 453 } |
| 454 |
| 455 /* boolean getBoolPref (in string aPrefName); */ |
| 456 NS_IMETHODIMP nsPrefBranch::GetBoolPref(const char *aPrefName, PRBool *_retval) |
| 457 { |
| 458 return NS_ERROR_NOT_IMPLEMENTED; |
| 459 } |
| 460 |
| 461 /* void setBoolPref (in string aPrefName, in long aValue); */ |
| 462 NS_IMETHODIMP nsPrefBranch::SetBoolPref(const char *aPrefName, PRInt32 aValue) |
| 463 { |
| 464 return NS_ERROR_NOT_IMPLEMENTED; |
| 465 } |
| 466 |
| 467 /* string getCharPref (in string aPrefName); */ |
| 468 NS_IMETHODIMP nsPrefBranch::GetCharPref(const char *aPrefName, char **_retval) |
| 469 { |
| 470 return NS_ERROR_NOT_IMPLEMENTED; |
| 471 } |
| 472 |
| 473 /* void setCharPref (in string aPrefName, in string aValue); */ |
| 474 NS_IMETHODIMP nsPrefBranch::SetCharPref(const char *aPrefName, const char *aValu
e) |
| 475 { |
| 476 return NS_ERROR_NOT_IMPLEMENTED; |
| 477 } |
| 478 |
| 479 /* long getIntPref (in string aPrefName); */ |
| 480 NS_IMETHODIMP nsPrefBranch::GetIntPref(const char *aPrefName, PRInt32 *_retval) |
| 481 { |
| 482 return NS_ERROR_NOT_IMPLEMENTED; |
| 483 } |
| 484 |
| 485 /* void setIntPref (in string aPrefName, in long aValue); */ |
| 486 NS_IMETHODIMP nsPrefBranch::SetIntPref(const char *aPrefName, PRInt32 aValue) |
| 487 { |
| 488 return NS_ERROR_NOT_IMPLEMENTED; |
| 489 } |
| 490 |
| 491 /* void getComplexValue (in string aPrefName, in nsIIDRef aType, [iid_is (aType)
, retval] out nsQIResult aValue); */ |
| 492 NS_IMETHODIMP nsPrefBranch::GetComplexValue(const char *aPrefName, const nsIID &
aType, void * *aValue) |
| 493 { |
| 494 return NS_ERROR_NOT_IMPLEMENTED; |
| 495 } |
| 496 |
| 497 /* void setComplexValue (in string aPrefName, in nsIIDRef aType, in nsISupports
aValue); */ |
| 498 NS_IMETHODIMP nsPrefBranch::SetComplexValue(const char *aPrefName, const nsIID &
aType, nsISupports *aValue) |
| 499 { |
| 500 return NS_ERROR_NOT_IMPLEMENTED; |
| 501 } |
| 502 |
| 503 /* void clearUserPref (in string aPrefName); */ |
| 504 NS_IMETHODIMP nsPrefBranch::ClearUserPref(const char *aPrefName) |
| 505 { |
| 506 return NS_ERROR_NOT_IMPLEMENTED; |
| 507 } |
| 508 |
| 509 /* void lockPref (in string aPrefName); */ |
| 510 NS_IMETHODIMP nsPrefBranch::LockPref(const char *aPrefName) |
| 511 { |
| 512 return NS_ERROR_NOT_IMPLEMENTED; |
| 513 } |
| 514 |
| 515 /* boolean prefHasUserValue (in string aPrefName); */ |
| 516 NS_IMETHODIMP nsPrefBranch::PrefHasUserValue(const char *aPrefName, PRBool *_ret
val) |
| 517 { |
| 518 return NS_ERROR_NOT_IMPLEMENTED; |
| 519 } |
| 520 |
| 521 /* boolean prefIsLocked (in string aPrefName); */ |
| 522 NS_IMETHODIMP nsPrefBranch::PrefIsLocked(const char *aPrefName, PRBool *_retval) |
| 523 { |
| 524 return NS_ERROR_NOT_IMPLEMENTED; |
| 525 } |
| 526 |
| 527 /* void unlockPref (in string aPrefName); */ |
| 528 NS_IMETHODIMP nsPrefBranch::UnlockPref(const char *aPrefName) |
| 529 { |
| 530 return NS_ERROR_NOT_IMPLEMENTED; |
| 531 } |
| 532 |
| 533 /* void deleteBranch (in string aStartingAt); */ |
| 534 NS_IMETHODIMP nsPrefBranch::DeleteBranch(const char *aStartingAt) |
| 535 { |
| 536 return NS_ERROR_NOT_IMPLEMENTED; |
| 537 } |
| 538 |
| 539 /* void getChildList (in string aStartingAt, out unsigned long aCount, [array, s
ize_is (aCount), retval] out string aChildArray); */ |
| 540 NS_IMETHODIMP nsPrefBranch::GetChildList(const char *aStartingAt, PRUint32 *aCou
nt, char ***aChildArray) |
| 541 { |
| 542 return NS_ERROR_NOT_IMPLEMENTED; |
| 543 } |
| 544 |
| 545 /* void resetBranch (in string aStartingAt); */ |
| 546 NS_IMETHODIMP nsPrefBranch::ResetBranch(const char *aStartingAt) |
| 547 { |
| 548 return NS_ERROR_NOT_IMPLEMENTED; |
| 549 } |
| 550 |
| 551 /* End of implementation class template. */ |
| 552 #endif |
| 553 |
| 554 #define NS_PREFBRANCH_CONTRACTID "@mozilla.org/preferencesbranch;1" |
| 555 #define NS_PREFBRANCH_CLASSNAME "Preferences Branch" |
| 556 |
| 557 #endif /* __gen_nsIPrefBranch_h__ */ |
OLD | NEW |