Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(103)

Side by Side Diff: gecko-sdk/include/nsIDirectoryService.h

Issue 20346: Version 1.8 of gecko-sdk. Downloaded from here:... (Closed) Base URL: svn://chrome-svn/chrome/trunk/deps/third_party/
Patch Set: Created 11 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « gecko-sdk/include/nsIDebug.h ('k') | gecko-sdk/include/nsIEmbeddingSiteWindow.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Added: svn:eol-style
+ LF
OLDNEW
(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/io/nsIDirectoryService.idl
3 */
4
5 #ifndef __gen_nsIDirectoryService_h__
6 #define __gen_nsIDirectoryService_h__
7
8
9 #ifndef __gen_nsISupports_h__
10 #include "nsISupports.h"
11 #endif
12
13 #ifndef __gen_nsIFile_h__
14 #include "nsIFile.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: nsIDirectoryServiceProvider */
23 #define NS_IDIRECTORYSERVICEPROVIDER_IID_STR "bbf8cab0-d43a-11d3-8cc2-0060979227 8c"
24
25 #define NS_IDIRECTORYSERVICEPROVIDER_IID \
26 {0xbbf8cab0, 0xd43a, 0x11d3, \
27 { 0x8c, 0xc2, 0x00, 0x60, 0x97, 0x92, 0x27, 0x8c }}
28
29 /**
30 * nsIDirectoryServiceProvider
31 *
32 * Used by Directory Service to get file locations.
33 *
34 * @status FROZEN
35 */
36 class NS_NO_VTABLE nsIDirectoryServiceProvider : public nsISupports {
37 public:
38
39 NS_DEFINE_STATIC_IID_ACCESSOR(NS_IDIRECTORYSERVICEPROVIDER_IID)
40
41 /**
42 * getFile
43 *
44 * Directory Service calls this when it gets the first request for
45 * a prop or on every request if the prop is not persistent.
46 *
47 * @param prop The symbolic name of the file.
48 * @param persistent TRUE - The returned file will be cached by Directory
49 * Service. Subsequent requests for this prop will
50 * bypass the provider and use the cache.
51 * FALSE - The provider will be asked for this prop
52 * each time it is requested.
53 *
54 * @return The file represented by the property.
55 *
56 */
57 /* nsIFile getFile (in string prop, out PRBool persistent); */
58 NS_IMETHOD GetFile(const char *prop, PRBool *persistent, nsIFile **_retval) = 0;
59
60 };
61
62 /* Use this macro when declaring classes that implement this interface. */
63 #define NS_DECL_NSIDIRECTORYSERVICEPROVIDER \
64 NS_IMETHOD GetFile(const char *prop, PRBool *persistent, nsIFile **_retval);
65
66 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object. */
67 #define NS_FORWARD_NSIDIRECTORYSERVICEPROVIDER(_to) \
68 NS_IMETHOD GetFile(const char *prop, PRBool *persistent, nsIFile **_retval) { return _to GetFile(prop, persistent, _retval); }
69
70 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object in a safe way. */
71 #define NS_FORWARD_SAFE_NSIDIRECTORYSERVICEPROVIDER(_to) \
72 NS_IMETHOD GetFile(const char *prop, PRBool *persistent, nsIFile **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFile(prop, persistent, _retval); }
73
74 #if 0
75 /* Use the code below as a template for the implementation class for this interf ace. */
76
77 /* Header file */
78 class nsDirectoryServiceProvider : public nsIDirectoryServiceProvider
79 {
80 public:
81 NS_DECL_ISUPPORTS
82 NS_DECL_NSIDIRECTORYSERVICEPROVIDER
83
84 nsDirectoryServiceProvider();
85
86 private:
87 ~nsDirectoryServiceProvider();
88
89 protected:
90 /* additional members */
91 };
92
93 /* Implementation file */
94 NS_IMPL_ISUPPORTS1(nsDirectoryServiceProvider, nsIDirectoryServiceProvider)
95
96 nsDirectoryServiceProvider::nsDirectoryServiceProvider()
97 {
98 /* member initializers and constructor code */
99 }
100
101 nsDirectoryServiceProvider::~nsDirectoryServiceProvider()
102 {
103 /* destructor code */
104 }
105
106 /* nsIFile getFile (in string prop, out PRBool persistent); */
107 NS_IMETHODIMP nsDirectoryServiceProvider::GetFile(const char *prop, PRBool *pers istent, nsIFile **_retval)
108 {
109 return NS_ERROR_NOT_IMPLEMENTED;
110 }
111
112 /* End of implementation class template. */
113 #endif
114
115
116 /* starting interface: nsIDirectoryServiceProvider2 */
117 #define NS_IDIRECTORYSERVICEPROVIDER2_IID_STR "2f977d4b-5485-11d4-87e2-0010a4e75 ef2"
118
119 #define NS_IDIRECTORYSERVICEPROVIDER2_IID \
120 {0x2f977d4b, 0x5485, 0x11d4, \
121 { 0x87, 0xe2, 0x00, 0x10, 0xa4, 0xe7, 0x5e, 0xf2 }}
122
123 /**
124 * nsIDirectoryServiceProvider2
125 *
126 * An extension of nsIDirectoryServiceProvider which allows
127 * multiple files to be returned for the given key.
128 *
129 * @status FROZEN
130 */
131 class NS_NO_VTABLE nsIDirectoryServiceProvider2 : public nsIDirectoryServiceProv ider {
132 public:
133
134 NS_DEFINE_STATIC_IID_ACCESSOR(NS_IDIRECTORYSERVICEPROVIDER2_IID)
135
136 /**
137 * getFiles
138 *
139 * Directory Service calls this when it gets a request for
140 * a prop and the requested type is nsISimpleEnumerator.
141 *
142 * @param prop The symbolic name of the file list.
143 *
144 * @return An enumerator for a list of file locations.
145 * The elements in the enumeration are nsIFile
146 * @returnCode NS_SUCCESS_AGGREGATE_RESULT if this result should be
147 * aggregated with other "lower" providers.
148 */
149 /* nsISimpleEnumerator getFiles (in string prop); */
150 NS_IMETHOD GetFiles(const char *prop, nsISimpleEnumerator **_retval) = 0;
151
152 };
153
154 /* Use this macro when declaring classes that implement this interface. */
155 #define NS_DECL_NSIDIRECTORYSERVICEPROVIDER2 \
156 NS_IMETHOD GetFiles(const char *prop, nsISimpleEnumerator **_retval);
157
158 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object. */
159 #define NS_FORWARD_NSIDIRECTORYSERVICEPROVIDER2(_to) \
160 NS_IMETHOD GetFiles(const char *prop, nsISimpleEnumerator **_retval) { return _to GetFiles(prop, _retval); }
161
162 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object in a safe way. */
163 #define NS_FORWARD_SAFE_NSIDIRECTORYSERVICEPROVIDER2(_to) \
164 NS_IMETHOD GetFiles(const char *prop, nsISimpleEnumerator **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFiles(prop, _retval); }
165
166 #if 0
167 /* Use the code below as a template for the implementation class for this interf ace. */
168
169 /* Header file */
170 class nsDirectoryServiceProvider2 : public nsIDirectoryServiceProvider2
171 {
172 public:
173 NS_DECL_ISUPPORTS
174 NS_DECL_NSIDIRECTORYSERVICEPROVIDER2
175
176 nsDirectoryServiceProvider2();
177
178 private:
179 ~nsDirectoryServiceProvider2();
180
181 protected:
182 /* additional members */
183 };
184
185 /* Implementation file */
186 NS_IMPL_ISUPPORTS1(nsDirectoryServiceProvider2, nsIDirectoryServiceProvider2)
187
188 nsDirectoryServiceProvider2::nsDirectoryServiceProvider2()
189 {
190 /* member initializers and constructor code */
191 }
192
193 nsDirectoryServiceProvider2::~nsDirectoryServiceProvider2()
194 {
195 /* destructor code */
196 }
197
198 /* nsISimpleEnumerator getFiles (in string prop); */
199 NS_IMETHODIMP nsDirectoryServiceProvider2::GetFiles(const char *prop, nsISimpleE numerator **_retval)
200 {
201 return NS_ERROR_NOT_IMPLEMENTED;
202 }
203
204 /* End of implementation class template. */
205 #endif
206
207
208 /* starting interface: nsIDirectoryService */
209 #define NS_IDIRECTORYSERVICE_IID_STR "57a66a60-d43a-11d3-8cc2-00609792278c"
210
211 #define NS_IDIRECTORYSERVICE_IID \
212 {0x57a66a60, 0xd43a, 0x11d3, \
213 { 0x8c, 0xc2, 0x00, 0x60, 0x97, 0x92, 0x27, 0x8c }}
214
215 /**
216 * nsIDirectoryService
217 *
218 * @status FROZEN
219 */
220 class NS_NO_VTABLE nsIDirectoryService : public nsISupports {
221 public:
222
223 NS_DEFINE_STATIC_IID_ACCESSOR(NS_IDIRECTORYSERVICE_IID)
224
225 /**
226 * init
227 *
228 * Must be called. Used internally by XPCOM initialization.
229 *
230 */
231 /* void init (); */
232 NS_IMETHOD Init(void) = 0;
233
234 /**
235 * registerProvider
236 *
237 * Register a provider with the service.
238 *
239 * @param prov The service will keep a strong reference
240 * to this object. It will be released when
241 * the service is released.
242 *
243 */
244 /* void registerProvider (in nsIDirectoryServiceProvider prov); */
245 NS_IMETHOD RegisterProvider(nsIDirectoryServiceProvider *prov) = 0;
246
247 /**
248 * unregisterProvider
249 *
250 * Unregister a provider with the service.
251 *
252 * @param prov
253 *
254 */
255 /* void unregisterProvider (in nsIDirectoryServiceProvider prov); */
256 NS_IMETHOD UnregisterProvider(nsIDirectoryServiceProvider *prov) = 0;
257
258 };
259
260 /* Use this macro when declaring classes that implement this interface. */
261 #define NS_DECL_NSIDIRECTORYSERVICE \
262 NS_IMETHOD Init(void); \
263 NS_IMETHOD RegisterProvider(nsIDirectoryServiceProvider *prov); \
264 NS_IMETHOD UnregisterProvider(nsIDirectoryServiceProvider *prov);
265
266 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object. */
267 #define NS_FORWARD_NSIDIRECTORYSERVICE(_to) \
268 NS_IMETHOD Init(void) { return _to Init(); } \
269 NS_IMETHOD RegisterProvider(nsIDirectoryServiceProvider *prov) { return _to Re gisterProvider(prov); } \
270 NS_IMETHOD UnregisterProvider(nsIDirectoryServiceProvider *prov) { return _to UnregisterProvider(prov); }
271
272 /* Use this macro to declare functions that forward the behavior of this interfa ce to another object in a safe way. */
273 #define NS_FORWARD_SAFE_NSIDIRECTORYSERVICE(_to) \
274 NS_IMETHOD Init(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->Init(); } \
275 NS_IMETHOD RegisterProvider(nsIDirectoryServiceProvider *prov) { return !_to ? NS_ERROR_NULL_POINTER : _to->RegisterProvider(prov); } \
276 NS_IMETHOD UnregisterProvider(nsIDirectoryServiceProvider *prov) { return !_to ? NS_ERROR_NULL_POINTER : _to->UnregisterProvider(prov); }
277
278 #if 0
279 /* Use the code below as a template for the implementation class for this interf ace. */
280
281 /* Header file */
282 class nsDirectoryService : public nsIDirectoryService
283 {
284 public:
285 NS_DECL_ISUPPORTS
286 NS_DECL_NSIDIRECTORYSERVICE
287
288 nsDirectoryService();
289
290 private:
291 ~nsDirectoryService();
292
293 protected:
294 /* additional members */
295 };
296
297 /* Implementation file */
298 NS_IMPL_ISUPPORTS1(nsDirectoryService, nsIDirectoryService)
299
300 nsDirectoryService::nsDirectoryService()
301 {
302 /* member initializers and constructor code */
303 }
304
305 nsDirectoryService::~nsDirectoryService()
306 {
307 /* destructor code */
308 }
309
310 /* void init (); */
311 NS_IMETHODIMP nsDirectoryService::Init()
312 {
313 return NS_ERROR_NOT_IMPLEMENTED;
314 }
315
316 /* void registerProvider (in nsIDirectoryServiceProvider prov); */
317 NS_IMETHODIMP nsDirectoryService::RegisterProvider(nsIDirectoryServiceProvider * prov)
318 {
319 return NS_ERROR_NOT_IMPLEMENTED;
320 }
321
322 /* void unregisterProvider (in nsIDirectoryServiceProvider prov); */
323 NS_IMETHODIMP nsDirectoryService::UnregisterProvider(nsIDirectoryServiceProvider *prov)
324 {
325 return NS_ERROR_NOT_IMPLEMENTED;
326 }
327
328 /* End of implementation class template. */
329 #endif
330
331
332 #endif /* __gen_nsIDirectoryService_h__ */
OLDNEW
« no previous file with comments | « gecko-sdk/include/nsIDebug.h ('k') | gecko-sdk/include/nsIEmbeddingSiteWindow.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698