1 : /*
2 : * DO NOT EDIT. THIS FILE IS GENERATED FROM /builds/slave/m-beta-lnx-codecoverage/build/xpcom/io/nsIFile.idl
3 : */
4 :
5 : #ifndef __gen_nsIFile_h__
6 : #define __gen_nsIFile_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 : class nsISimpleEnumerator; /* forward declaration */
18 :
19 :
20 : /* starting interface: nsIFile */
21 : #define NS_IFILE_IID_STR "c8c0a080-0868-11d3-915f-d9d889d48e3c"
22 :
23 : #define NS_IFILE_IID \
24 : {0xc8c0a080, 0x0868, 0x11d3, \
25 : { 0x91, 0x5f, 0xd9, 0xd8, 0x89, 0xd4, 0x8e, 0x3c }}
26 :
27 797548 : class NS_NO_VTABLE NS_SCRIPTABLE nsIFile : public nsISupports {
28 : public:
29 :
30 : NS_DECLARE_STATIC_IID_ACCESSOR(NS_IFILE_IID)
31 :
32 : enum {
33 : NORMAL_FILE_TYPE = 0U,
34 : DIRECTORY_TYPE = 1U
35 : };
36 :
37 : /* void append (in AString node); */
38 : NS_SCRIPTABLE NS_IMETHOD Append(const nsAString & node) = 0;
39 :
40 : /* [noscript] void appendNative (in ACString node); */
41 : NS_IMETHOD AppendNative(const nsACString & node) = 0;
42 :
43 : /* void normalize (); */
44 : NS_SCRIPTABLE NS_IMETHOD Normalize(void) = 0;
45 :
46 : /* void create (in unsigned long type, in unsigned long permissions); */
47 : NS_SCRIPTABLE NS_IMETHOD Create(PRUint32 type, PRUint32 permissions) = 0;
48 :
49 : /* attribute AString leafName; */
50 : NS_SCRIPTABLE NS_IMETHOD GetLeafName(nsAString & aLeafName) = 0;
51 : NS_SCRIPTABLE NS_IMETHOD SetLeafName(const nsAString & aLeafName) = 0;
52 :
53 : /* [noscript] attribute ACString nativeLeafName; */
54 : NS_IMETHOD GetNativeLeafName(nsACString & aNativeLeafName) = 0;
55 : NS_IMETHOD SetNativeLeafName(const nsACString & aNativeLeafName) = 0;
56 :
57 : /* void copyTo (in nsIFile newParentDir, in AString newName); */
58 : NS_SCRIPTABLE NS_IMETHOD CopyTo(nsIFile *newParentDir, const nsAString & newName) = 0;
59 :
60 : /* [noscript] void CopyToNative (in nsIFile newParentDir, in ACString newName); */
61 : NS_IMETHOD CopyToNative(nsIFile *newParentDir, const nsACString & newName) = 0;
62 :
63 : /* void copyToFollowingLinks (in nsIFile newParentDir, in AString newName); */
64 : NS_SCRIPTABLE NS_IMETHOD CopyToFollowingLinks(nsIFile *newParentDir, const nsAString & newName) = 0;
65 :
66 : /* [noscript] void copyToFollowingLinksNative (in nsIFile newParentDir, in ACString newName); */
67 : NS_IMETHOD CopyToFollowingLinksNative(nsIFile *newParentDir, const nsACString & newName) = 0;
68 :
69 : /* void moveTo (in nsIFile newParentDir, in AString newName); */
70 : NS_SCRIPTABLE NS_IMETHOD MoveTo(nsIFile *newParentDir, const nsAString & newName) = 0;
71 :
72 : /* [noscript] void moveToNative (in nsIFile newParentDir, in ACString newName); */
73 : NS_IMETHOD MoveToNative(nsIFile *newParentDir, const nsACString & newName) = 0;
74 :
75 : /* void remove (in boolean recursive); */
76 : NS_SCRIPTABLE NS_IMETHOD Remove(bool recursive) = 0;
77 :
78 : /* attribute unsigned long permissions; */
79 : NS_SCRIPTABLE NS_IMETHOD GetPermissions(PRUint32 *aPermissions) = 0;
80 : NS_SCRIPTABLE NS_IMETHOD SetPermissions(PRUint32 aPermissions) = 0;
81 :
82 : /* attribute unsigned long permissionsOfLink; */
83 : NS_SCRIPTABLE NS_IMETHOD GetPermissionsOfLink(PRUint32 *aPermissionsOfLink) = 0;
84 : NS_SCRIPTABLE NS_IMETHOD SetPermissionsOfLink(PRUint32 aPermissionsOfLink) = 0;
85 :
86 : /* attribute PRInt64 lastModifiedTime; */
87 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTime(PRInt64 *aLastModifiedTime) = 0;
88 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTime(PRInt64 aLastModifiedTime) = 0;
89 :
90 : /* attribute PRInt64 lastModifiedTimeOfLink; */
91 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTimeOfLink(PRInt64 *aLastModifiedTimeOfLink) = 0;
92 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTimeOfLink(PRInt64 aLastModifiedTimeOfLink) = 0;
93 :
94 : /* attribute PRInt64 fileSize; */
95 : NS_SCRIPTABLE NS_IMETHOD GetFileSize(PRInt64 *aFileSize) = 0;
96 : NS_SCRIPTABLE NS_IMETHOD SetFileSize(PRInt64 aFileSize) = 0;
97 :
98 : /* readonly attribute PRInt64 fileSizeOfLink; */
99 : NS_SCRIPTABLE NS_IMETHOD GetFileSizeOfLink(PRInt64 *aFileSizeOfLink) = 0;
100 :
101 : /* readonly attribute AString target; */
102 : NS_SCRIPTABLE NS_IMETHOD GetTarget(nsAString & aTarget) = 0;
103 :
104 : /* [noscript] readonly attribute ACString nativeTarget; */
105 : NS_IMETHOD GetNativeTarget(nsACString & aNativeTarget) = 0;
106 :
107 : /* readonly attribute AString path; */
108 : NS_SCRIPTABLE NS_IMETHOD GetPath(nsAString & aPath) = 0;
109 :
110 : /* [noscript] readonly attribute ACString nativePath; */
111 : NS_IMETHOD GetNativePath(nsACString & aNativePath) = 0;
112 :
113 : /* boolean exists (); */
114 : NS_SCRIPTABLE NS_IMETHOD Exists(bool *_retval NS_OUTPARAM) = 0;
115 :
116 : /* boolean isWritable (); */
117 : NS_SCRIPTABLE NS_IMETHOD IsWritable(bool *_retval NS_OUTPARAM) = 0;
118 :
119 : /* boolean isReadable (); */
120 : NS_SCRIPTABLE NS_IMETHOD IsReadable(bool *_retval NS_OUTPARAM) = 0;
121 :
122 : /* boolean isExecutable (); */
123 : NS_SCRIPTABLE NS_IMETHOD IsExecutable(bool *_retval NS_OUTPARAM) = 0;
124 :
125 : /* boolean isHidden (); */
126 : NS_SCRIPTABLE NS_IMETHOD IsHidden(bool *_retval NS_OUTPARAM) = 0;
127 :
128 : /* boolean isDirectory (); */
129 : NS_SCRIPTABLE NS_IMETHOD IsDirectory(bool *_retval NS_OUTPARAM) = 0;
130 :
131 : /* boolean isFile (); */
132 : NS_SCRIPTABLE NS_IMETHOD IsFile(bool *_retval NS_OUTPARAM) = 0;
133 :
134 : /* boolean isSymlink (); */
135 : NS_SCRIPTABLE NS_IMETHOD IsSymlink(bool *_retval NS_OUTPARAM) = 0;
136 :
137 : /* boolean isSpecial (); */
138 : NS_SCRIPTABLE NS_IMETHOD IsSpecial(bool *_retval NS_OUTPARAM) = 0;
139 :
140 : /* void createUnique (in unsigned long type, in unsigned long permissions); */
141 : NS_SCRIPTABLE NS_IMETHOD CreateUnique(PRUint32 type, PRUint32 permissions) = 0;
142 :
143 : /* nsIFile clone (); */
144 : NS_SCRIPTABLE NS_IMETHOD Clone(nsIFile * *_retval NS_OUTPARAM) = 0;
145 :
146 : /* boolean equals (in nsIFile inFile); */
147 : NS_SCRIPTABLE NS_IMETHOD Equals(nsIFile *inFile, bool *_retval NS_OUTPARAM) = 0;
148 :
149 : /* boolean contains (in nsIFile inFile, in boolean recur); */
150 : NS_SCRIPTABLE NS_IMETHOD Contains(nsIFile *inFile, bool recur, bool *_retval NS_OUTPARAM) = 0;
151 :
152 : /* readonly attribute nsIFile parent; */
153 : NS_SCRIPTABLE NS_IMETHOD GetParent(nsIFile * *aParent) = 0;
154 :
155 : /* readonly attribute nsISimpleEnumerator directoryEntries; */
156 : NS_SCRIPTABLE NS_IMETHOD GetDirectoryEntries(nsISimpleEnumerator * *aDirectoryEntries) = 0;
157 :
158 : };
159 :
160 : NS_DEFINE_STATIC_IID_ACCESSOR(nsIFile, NS_IFILE_IID)
161 :
162 : /* Use this macro when declaring classes that implement this interface. */
163 : #define NS_DECL_NSIFILE \
164 : NS_SCRIPTABLE NS_IMETHOD Append(const nsAString & node); \
165 : NS_IMETHOD AppendNative(const nsACString & node); \
166 : NS_SCRIPTABLE NS_IMETHOD Normalize(void); \
167 : NS_SCRIPTABLE NS_IMETHOD Create(PRUint32 type, PRUint32 permissions); \
168 : NS_SCRIPTABLE NS_IMETHOD GetLeafName(nsAString & aLeafName); \
169 : NS_SCRIPTABLE NS_IMETHOD SetLeafName(const nsAString & aLeafName); \
170 : NS_IMETHOD GetNativeLeafName(nsACString & aNativeLeafName); \
171 : NS_IMETHOD SetNativeLeafName(const nsACString & aNativeLeafName); \
172 : NS_SCRIPTABLE NS_IMETHOD CopyTo(nsIFile *newParentDir, const nsAString & newName); \
173 : NS_IMETHOD CopyToNative(nsIFile *newParentDir, const nsACString & newName); \
174 : NS_SCRIPTABLE NS_IMETHOD CopyToFollowingLinks(nsIFile *newParentDir, const nsAString & newName); \
175 : NS_IMETHOD CopyToFollowingLinksNative(nsIFile *newParentDir, const nsACString & newName); \
176 : NS_SCRIPTABLE NS_IMETHOD MoveTo(nsIFile *newParentDir, const nsAString & newName); \
177 : NS_IMETHOD MoveToNative(nsIFile *newParentDir, const nsACString & newName); \
178 : NS_SCRIPTABLE NS_IMETHOD Remove(bool recursive); \
179 : NS_SCRIPTABLE NS_IMETHOD GetPermissions(PRUint32 *aPermissions); \
180 : NS_SCRIPTABLE NS_IMETHOD SetPermissions(PRUint32 aPermissions); \
181 : NS_SCRIPTABLE NS_IMETHOD GetPermissionsOfLink(PRUint32 *aPermissionsOfLink); \
182 : NS_SCRIPTABLE NS_IMETHOD SetPermissionsOfLink(PRUint32 aPermissionsOfLink); \
183 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTime(PRInt64 *aLastModifiedTime); \
184 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTime(PRInt64 aLastModifiedTime); \
185 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTimeOfLink(PRInt64 *aLastModifiedTimeOfLink); \
186 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTimeOfLink(PRInt64 aLastModifiedTimeOfLink); \
187 : NS_SCRIPTABLE NS_IMETHOD GetFileSize(PRInt64 *aFileSize); \
188 : NS_SCRIPTABLE NS_IMETHOD SetFileSize(PRInt64 aFileSize); \
189 : NS_SCRIPTABLE NS_IMETHOD GetFileSizeOfLink(PRInt64 *aFileSizeOfLink); \
190 : NS_SCRIPTABLE NS_IMETHOD GetTarget(nsAString & aTarget); \
191 : NS_IMETHOD GetNativeTarget(nsACString & aNativeTarget); \
192 : NS_SCRIPTABLE NS_IMETHOD GetPath(nsAString & aPath); \
193 : NS_IMETHOD GetNativePath(nsACString & aNativePath); \
194 : NS_SCRIPTABLE NS_IMETHOD Exists(bool *_retval NS_OUTPARAM); \
195 : NS_SCRIPTABLE NS_IMETHOD IsWritable(bool *_retval NS_OUTPARAM); \
196 : NS_SCRIPTABLE NS_IMETHOD IsReadable(bool *_retval NS_OUTPARAM); \
197 : NS_SCRIPTABLE NS_IMETHOD IsExecutable(bool *_retval NS_OUTPARAM); \
198 : NS_SCRIPTABLE NS_IMETHOD IsHidden(bool *_retval NS_OUTPARAM); \
199 : NS_SCRIPTABLE NS_IMETHOD IsDirectory(bool *_retval NS_OUTPARAM); \
200 : NS_SCRIPTABLE NS_IMETHOD IsFile(bool *_retval NS_OUTPARAM); \
201 : NS_SCRIPTABLE NS_IMETHOD IsSymlink(bool *_retval NS_OUTPARAM); \
202 : NS_SCRIPTABLE NS_IMETHOD IsSpecial(bool *_retval NS_OUTPARAM); \
203 : NS_SCRIPTABLE NS_IMETHOD CreateUnique(PRUint32 type, PRUint32 permissions); \
204 : NS_SCRIPTABLE NS_IMETHOD Clone(nsIFile * *_retval NS_OUTPARAM); \
205 : NS_SCRIPTABLE NS_IMETHOD Equals(nsIFile *inFile, bool *_retval NS_OUTPARAM); \
206 : NS_SCRIPTABLE NS_IMETHOD Contains(nsIFile *inFile, bool recur, bool *_retval NS_OUTPARAM); \
207 : NS_SCRIPTABLE NS_IMETHOD GetParent(nsIFile * *aParent); \
208 : NS_SCRIPTABLE NS_IMETHOD GetDirectoryEntries(nsISimpleEnumerator * *aDirectoryEntries);
209 :
210 : /* Use this macro to declare functions that forward the behavior of this interface to another object. */
211 : #define NS_FORWARD_NSIFILE(_to) \
212 : NS_SCRIPTABLE NS_IMETHOD Append(const nsAString & node) { return _to Append(node); } \
213 : NS_IMETHOD AppendNative(const nsACString & node) { return _to AppendNative(node); } \
214 : NS_SCRIPTABLE NS_IMETHOD Normalize(void) { return _to Normalize(); } \
215 : NS_SCRIPTABLE NS_IMETHOD Create(PRUint32 type, PRUint32 permissions) { return _to Create(type, permissions); } \
216 : NS_SCRIPTABLE NS_IMETHOD GetLeafName(nsAString & aLeafName) { return _to GetLeafName(aLeafName); } \
217 : NS_SCRIPTABLE NS_IMETHOD SetLeafName(const nsAString & aLeafName) { return _to SetLeafName(aLeafName); } \
218 : NS_IMETHOD GetNativeLeafName(nsACString & aNativeLeafName) { return _to GetNativeLeafName(aNativeLeafName); } \
219 : NS_IMETHOD SetNativeLeafName(const nsACString & aNativeLeafName) { return _to SetNativeLeafName(aNativeLeafName); } \
220 : NS_SCRIPTABLE NS_IMETHOD CopyTo(nsIFile *newParentDir, const nsAString & newName) { return _to CopyTo(newParentDir, newName); } \
221 : NS_IMETHOD CopyToNative(nsIFile *newParentDir, const nsACString & newName) { return _to CopyToNative(newParentDir, newName); } \
222 : NS_SCRIPTABLE NS_IMETHOD CopyToFollowingLinks(nsIFile *newParentDir, const nsAString & newName) { return _to CopyToFollowingLinks(newParentDir, newName); } \
223 : NS_IMETHOD CopyToFollowingLinksNative(nsIFile *newParentDir, const nsACString & newName) { return _to CopyToFollowingLinksNative(newParentDir, newName); } \
224 : NS_SCRIPTABLE NS_IMETHOD MoveTo(nsIFile *newParentDir, const nsAString & newName) { return _to MoveTo(newParentDir, newName); } \
225 : NS_IMETHOD MoveToNative(nsIFile *newParentDir, const nsACString & newName) { return _to MoveToNative(newParentDir, newName); } \
226 : NS_SCRIPTABLE NS_IMETHOD Remove(bool recursive) { return _to Remove(recursive); } \
227 : NS_SCRIPTABLE NS_IMETHOD GetPermissions(PRUint32 *aPermissions) { return _to GetPermissions(aPermissions); } \
228 : NS_SCRIPTABLE NS_IMETHOD SetPermissions(PRUint32 aPermissions) { return _to SetPermissions(aPermissions); } \
229 : NS_SCRIPTABLE NS_IMETHOD GetPermissionsOfLink(PRUint32 *aPermissionsOfLink) { return _to GetPermissionsOfLink(aPermissionsOfLink); } \
230 : NS_SCRIPTABLE NS_IMETHOD SetPermissionsOfLink(PRUint32 aPermissionsOfLink) { return _to SetPermissionsOfLink(aPermissionsOfLink); } \
231 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTime(PRInt64 *aLastModifiedTime) { return _to GetLastModifiedTime(aLastModifiedTime); } \
232 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTime(PRInt64 aLastModifiedTime) { return _to SetLastModifiedTime(aLastModifiedTime); } \
233 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTimeOfLink(PRInt64 *aLastModifiedTimeOfLink) { return _to GetLastModifiedTimeOfLink(aLastModifiedTimeOfLink); } \
234 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTimeOfLink(PRInt64 aLastModifiedTimeOfLink) { return _to SetLastModifiedTimeOfLink(aLastModifiedTimeOfLink); } \
235 : NS_SCRIPTABLE NS_IMETHOD GetFileSize(PRInt64 *aFileSize) { return _to GetFileSize(aFileSize); } \
236 : NS_SCRIPTABLE NS_IMETHOD SetFileSize(PRInt64 aFileSize) { return _to SetFileSize(aFileSize); } \
237 : NS_SCRIPTABLE NS_IMETHOD GetFileSizeOfLink(PRInt64 *aFileSizeOfLink) { return _to GetFileSizeOfLink(aFileSizeOfLink); } \
238 : NS_SCRIPTABLE NS_IMETHOD GetTarget(nsAString & aTarget) { return _to GetTarget(aTarget); } \
239 : NS_IMETHOD GetNativeTarget(nsACString & aNativeTarget) { return _to GetNativeTarget(aNativeTarget); } \
240 : NS_SCRIPTABLE NS_IMETHOD GetPath(nsAString & aPath) { return _to GetPath(aPath); } \
241 : NS_IMETHOD GetNativePath(nsACString & aNativePath) { return _to GetNativePath(aNativePath); } \
242 : NS_SCRIPTABLE NS_IMETHOD Exists(bool *_retval NS_OUTPARAM) { return _to Exists(_retval); } \
243 : NS_SCRIPTABLE NS_IMETHOD IsWritable(bool *_retval NS_OUTPARAM) { return _to IsWritable(_retval); } \
244 : NS_SCRIPTABLE NS_IMETHOD IsReadable(bool *_retval NS_OUTPARAM) { return _to IsReadable(_retval); } \
245 : NS_SCRIPTABLE NS_IMETHOD IsExecutable(bool *_retval NS_OUTPARAM) { return _to IsExecutable(_retval); } \
246 : NS_SCRIPTABLE NS_IMETHOD IsHidden(bool *_retval NS_OUTPARAM) { return _to IsHidden(_retval); } \
247 : NS_SCRIPTABLE NS_IMETHOD IsDirectory(bool *_retval NS_OUTPARAM) { return _to IsDirectory(_retval); } \
248 : NS_SCRIPTABLE NS_IMETHOD IsFile(bool *_retval NS_OUTPARAM) { return _to IsFile(_retval); } \
249 : NS_SCRIPTABLE NS_IMETHOD IsSymlink(bool *_retval NS_OUTPARAM) { return _to IsSymlink(_retval); } \
250 : NS_SCRIPTABLE NS_IMETHOD IsSpecial(bool *_retval NS_OUTPARAM) { return _to IsSpecial(_retval); } \
251 : NS_SCRIPTABLE NS_IMETHOD CreateUnique(PRUint32 type, PRUint32 permissions) { return _to CreateUnique(type, permissions); } \
252 : NS_SCRIPTABLE NS_IMETHOD Clone(nsIFile * *_retval NS_OUTPARAM) { return _to Clone(_retval); } \
253 : NS_SCRIPTABLE NS_IMETHOD Equals(nsIFile *inFile, bool *_retval NS_OUTPARAM) { return _to Equals(inFile, _retval); } \
254 : NS_SCRIPTABLE NS_IMETHOD Contains(nsIFile *inFile, bool recur, bool *_retval NS_OUTPARAM) { return _to Contains(inFile, recur, _retval); } \
255 : NS_SCRIPTABLE NS_IMETHOD GetParent(nsIFile * *aParent) { return _to GetParent(aParent); } \
256 : NS_SCRIPTABLE NS_IMETHOD GetDirectoryEntries(nsISimpleEnumerator * *aDirectoryEntries) { return _to GetDirectoryEntries(aDirectoryEntries); }
257 :
258 : /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
259 : #define NS_FORWARD_SAFE_NSIFILE(_to) \
260 : NS_SCRIPTABLE NS_IMETHOD Append(const nsAString & node) { return !_to ? NS_ERROR_NULL_POINTER : _to->Append(node); } \
261 : NS_IMETHOD AppendNative(const nsACString & node) { return !_to ? NS_ERROR_NULL_POINTER : _to->AppendNative(node); } \
262 : NS_SCRIPTABLE NS_IMETHOD Normalize(void) { return !_to ? NS_ERROR_NULL_POINTER : _to->Normalize(); } \
263 : NS_SCRIPTABLE NS_IMETHOD Create(PRUint32 type, PRUint32 permissions) { return !_to ? NS_ERROR_NULL_POINTER : _to->Create(type, permissions); } \
264 : NS_SCRIPTABLE NS_IMETHOD GetLeafName(nsAString & aLeafName) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLeafName(aLeafName); } \
265 : NS_SCRIPTABLE NS_IMETHOD SetLeafName(const nsAString & aLeafName) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetLeafName(aLeafName); } \
266 : NS_IMETHOD GetNativeLeafName(nsACString & aNativeLeafName) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetNativeLeafName(aNativeLeafName); } \
267 : NS_IMETHOD SetNativeLeafName(const nsACString & aNativeLeafName) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetNativeLeafName(aNativeLeafName); } \
268 : NS_SCRIPTABLE NS_IMETHOD CopyTo(nsIFile *newParentDir, const nsAString & newName) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyTo(newParentDir, newName); } \
269 : NS_IMETHOD CopyToNative(nsIFile *newParentDir, const nsACString & newName) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyToNative(newParentDir, newName); } \
270 : NS_SCRIPTABLE NS_IMETHOD CopyToFollowingLinks(nsIFile *newParentDir, const nsAString & newName) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyToFollowingLinks(newParentDir, newName); } \
271 : NS_IMETHOD CopyToFollowingLinksNative(nsIFile *newParentDir, const nsACString & newName) { return !_to ? NS_ERROR_NULL_POINTER : _to->CopyToFollowingLinksNative(newParentDir, newName); } \
272 : NS_SCRIPTABLE NS_IMETHOD MoveTo(nsIFile *newParentDir, const nsAString & newName) { return !_to ? NS_ERROR_NULL_POINTER : _to->MoveTo(newParentDir, newName); } \
273 : NS_IMETHOD MoveToNative(nsIFile *newParentDir, const nsACString & newName) { return !_to ? NS_ERROR_NULL_POINTER : _to->MoveToNative(newParentDir, newName); } \
274 : NS_SCRIPTABLE NS_IMETHOD Remove(bool recursive) { return !_to ? NS_ERROR_NULL_POINTER : _to->Remove(recursive); } \
275 : NS_SCRIPTABLE NS_IMETHOD GetPermissions(PRUint32 *aPermissions) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPermissions(aPermissions); } \
276 : NS_SCRIPTABLE NS_IMETHOD SetPermissions(PRUint32 aPermissions) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetPermissions(aPermissions); } \
277 : NS_SCRIPTABLE NS_IMETHOD GetPermissionsOfLink(PRUint32 *aPermissionsOfLink) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPermissionsOfLink(aPermissionsOfLink); } \
278 : NS_SCRIPTABLE NS_IMETHOD SetPermissionsOfLink(PRUint32 aPermissionsOfLink) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetPermissionsOfLink(aPermissionsOfLink); } \
279 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTime(PRInt64 *aLastModifiedTime) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastModifiedTime(aLastModifiedTime); } \
280 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTime(PRInt64 aLastModifiedTime) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetLastModifiedTime(aLastModifiedTime); } \
281 : NS_SCRIPTABLE NS_IMETHOD GetLastModifiedTimeOfLink(PRInt64 *aLastModifiedTimeOfLink) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastModifiedTimeOfLink(aLastModifiedTimeOfLink); } \
282 : NS_SCRIPTABLE NS_IMETHOD SetLastModifiedTimeOfLink(PRInt64 aLastModifiedTimeOfLink) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetLastModifiedTimeOfLink(aLastModifiedTimeOfLink); } \
283 : NS_SCRIPTABLE NS_IMETHOD GetFileSize(PRInt64 *aFileSize) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFileSize(aFileSize); } \
284 : NS_SCRIPTABLE NS_IMETHOD SetFileSize(PRInt64 aFileSize) { return !_to ? NS_ERROR_NULL_POINTER : _to->SetFileSize(aFileSize); } \
285 : NS_SCRIPTABLE NS_IMETHOD GetFileSizeOfLink(PRInt64 *aFileSizeOfLink) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFileSizeOfLink(aFileSizeOfLink); } \
286 : NS_SCRIPTABLE NS_IMETHOD GetTarget(nsAString & aTarget) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetTarget(aTarget); } \
287 : NS_IMETHOD GetNativeTarget(nsACString & aNativeTarget) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetNativeTarget(aNativeTarget); } \
288 : NS_SCRIPTABLE NS_IMETHOD GetPath(nsAString & aPath) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPath(aPath); } \
289 : NS_IMETHOD GetNativePath(nsACString & aNativePath) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetNativePath(aNativePath); } \
290 : NS_SCRIPTABLE NS_IMETHOD Exists(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Exists(_retval); } \
291 : NS_SCRIPTABLE NS_IMETHOD IsWritable(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsWritable(_retval); } \
292 : NS_SCRIPTABLE NS_IMETHOD IsReadable(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsReadable(_retval); } \
293 : NS_SCRIPTABLE NS_IMETHOD IsExecutable(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsExecutable(_retval); } \
294 : NS_SCRIPTABLE NS_IMETHOD IsHidden(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsHidden(_retval); } \
295 : NS_SCRIPTABLE NS_IMETHOD IsDirectory(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsDirectory(_retval); } \
296 : NS_SCRIPTABLE NS_IMETHOD IsFile(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsFile(_retval); } \
297 : NS_SCRIPTABLE NS_IMETHOD IsSymlink(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsSymlink(_retval); } \
298 : NS_SCRIPTABLE NS_IMETHOD IsSpecial(bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->IsSpecial(_retval); } \
299 : NS_SCRIPTABLE NS_IMETHOD CreateUnique(PRUint32 type, PRUint32 permissions) { return !_to ? NS_ERROR_NULL_POINTER : _to->CreateUnique(type, permissions); } \
300 : NS_SCRIPTABLE NS_IMETHOD Clone(nsIFile * *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Clone(_retval); } \
301 : NS_SCRIPTABLE NS_IMETHOD Equals(nsIFile *inFile, bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Equals(inFile, _retval); } \
302 : NS_SCRIPTABLE NS_IMETHOD Contains(nsIFile *inFile, bool recur, bool *_retval NS_OUTPARAM) { return !_to ? NS_ERROR_NULL_POINTER : _to->Contains(inFile, recur, _retval); } \
303 : NS_SCRIPTABLE NS_IMETHOD GetParent(nsIFile * *aParent) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetParent(aParent); } \
304 : NS_SCRIPTABLE NS_IMETHOD GetDirectoryEntries(nsISimpleEnumerator * *aDirectoryEntries) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDirectoryEntries(aDirectoryEntries); }
305 :
306 : #if 0
307 : /* Use the code below as a template for the implementation class for this interface. */
308 :
309 : /* Header file */
310 : class nsFile : public nsIFile
311 : {
312 : public:
313 : NS_DECL_ISUPPORTS
314 : NS_DECL_NSIFILE
315 :
316 : nsFile();
317 :
318 : private:
319 : ~nsFile();
320 :
321 : protected:
322 : /* additional members */
323 : };
324 :
325 : /* Implementation file */
326 : NS_IMPL_ISUPPORTS1(nsFile, nsIFile)
327 :
328 : nsFile::nsFile()
329 : {
330 : /* member initializers and constructor code */
331 : }
332 :
333 : nsFile::~nsFile()
334 : {
335 : /* destructor code */
336 : }
337 :
338 : /* void append (in AString node); */
339 : NS_IMETHODIMP nsFile::Append(const nsAString & node)
340 : {
341 : return NS_ERROR_NOT_IMPLEMENTED;
342 : }
343 :
344 : /* [noscript] void appendNative (in ACString node); */
345 : NS_IMETHODIMP nsFile::AppendNative(const nsACString & node)
346 : {
347 : return NS_ERROR_NOT_IMPLEMENTED;
348 : }
349 :
350 : /* void normalize (); */
351 : NS_IMETHODIMP nsFile::Normalize()
352 : {
353 : return NS_ERROR_NOT_IMPLEMENTED;
354 : }
355 :
356 : /* void create (in unsigned long type, in unsigned long permissions); */
357 : NS_IMETHODIMP nsFile::Create(PRUint32 type, PRUint32 permissions)
358 : {
359 : return NS_ERROR_NOT_IMPLEMENTED;
360 : }
361 :
362 : /* attribute AString leafName; */
363 : NS_IMETHODIMP nsFile::GetLeafName(nsAString & aLeafName)
364 : {
365 : return NS_ERROR_NOT_IMPLEMENTED;
366 : }
367 : NS_IMETHODIMP nsFile::SetLeafName(const nsAString & aLeafName)
368 : {
369 : return NS_ERROR_NOT_IMPLEMENTED;
370 : }
371 :
372 : /* [noscript] attribute ACString nativeLeafName; */
373 : NS_IMETHODIMP nsFile::GetNativeLeafName(nsACString & aNativeLeafName)
374 : {
375 : return NS_ERROR_NOT_IMPLEMENTED;
376 : }
377 : NS_IMETHODIMP nsFile::SetNativeLeafName(const nsACString & aNativeLeafName)
378 : {
379 : return NS_ERROR_NOT_IMPLEMENTED;
380 : }
381 :
382 : /* void copyTo (in nsIFile newParentDir, in AString newName); */
383 : NS_IMETHODIMP nsFile::CopyTo(nsIFile *newParentDir, const nsAString & newName)
384 : {
385 : return NS_ERROR_NOT_IMPLEMENTED;
386 : }
387 :
388 : /* [noscript] void CopyToNative (in nsIFile newParentDir, in ACString newName); */
389 : NS_IMETHODIMP nsFile::CopyToNative(nsIFile *newParentDir, const nsACString & newName)
390 : {
391 : return NS_ERROR_NOT_IMPLEMENTED;
392 : }
393 :
394 : /* void copyToFollowingLinks (in nsIFile newParentDir, in AString newName); */
395 : NS_IMETHODIMP nsFile::CopyToFollowingLinks(nsIFile *newParentDir, const nsAString & newName)
396 : {
397 : return NS_ERROR_NOT_IMPLEMENTED;
398 : }
399 :
400 : /* [noscript] void copyToFollowingLinksNative (in nsIFile newParentDir, in ACString newName); */
401 : NS_IMETHODIMP nsFile::CopyToFollowingLinksNative(nsIFile *newParentDir, const nsACString & newName)
402 : {
403 : return NS_ERROR_NOT_IMPLEMENTED;
404 : }
405 :
406 : /* void moveTo (in nsIFile newParentDir, in AString newName); */
407 : NS_IMETHODIMP nsFile::MoveTo(nsIFile *newParentDir, const nsAString & newName)
408 : {
409 : return NS_ERROR_NOT_IMPLEMENTED;
410 : }
411 :
412 : /* [noscript] void moveToNative (in nsIFile newParentDir, in ACString newName); */
413 : NS_IMETHODIMP nsFile::MoveToNative(nsIFile *newParentDir, const nsACString & newName)
414 : {
415 : return NS_ERROR_NOT_IMPLEMENTED;
416 : }
417 :
418 : /* void remove (in boolean recursive); */
419 : NS_IMETHODIMP nsFile::Remove(bool recursive)
420 : {
421 : return NS_ERROR_NOT_IMPLEMENTED;
422 : }
423 :
424 : /* attribute unsigned long permissions; */
425 : NS_IMETHODIMP nsFile::GetPermissions(PRUint32 *aPermissions)
426 : {
427 : return NS_ERROR_NOT_IMPLEMENTED;
428 : }
429 : NS_IMETHODIMP nsFile::SetPermissions(PRUint32 aPermissions)
430 : {
431 : return NS_ERROR_NOT_IMPLEMENTED;
432 : }
433 :
434 : /* attribute unsigned long permissionsOfLink; */
435 : NS_IMETHODIMP nsFile::GetPermissionsOfLink(PRUint32 *aPermissionsOfLink)
436 : {
437 : return NS_ERROR_NOT_IMPLEMENTED;
438 : }
439 : NS_IMETHODIMP nsFile::SetPermissionsOfLink(PRUint32 aPermissionsOfLink)
440 : {
441 : return NS_ERROR_NOT_IMPLEMENTED;
442 : }
443 :
444 : /* attribute PRInt64 lastModifiedTime; */
445 : NS_IMETHODIMP nsFile::GetLastModifiedTime(PRInt64 *aLastModifiedTime)
446 : {
447 : return NS_ERROR_NOT_IMPLEMENTED;
448 : }
449 : NS_IMETHODIMP nsFile::SetLastModifiedTime(PRInt64 aLastModifiedTime)
450 : {
451 : return NS_ERROR_NOT_IMPLEMENTED;
452 : }
453 :
454 : /* attribute PRInt64 lastModifiedTimeOfLink; */
455 : NS_IMETHODIMP nsFile::GetLastModifiedTimeOfLink(PRInt64 *aLastModifiedTimeOfLink)
456 : {
457 : return NS_ERROR_NOT_IMPLEMENTED;
458 : }
459 : NS_IMETHODIMP nsFile::SetLastModifiedTimeOfLink(PRInt64 aLastModifiedTimeOfLink)
460 : {
461 : return NS_ERROR_NOT_IMPLEMENTED;
462 : }
463 :
464 : /* attribute PRInt64 fileSize; */
465 : NS_IMETHODIMP nsFile::GetFileSize(PRInt64 *aFileSize)
466 : {
467 : return NS_ERROR_NOT_IMPLEMENTED;
468 : }
469 : NS_IMETHODIMP nsFile::SetFileSize(PRInt64 aFileSize)
470 : {
471 : return NS_ERROR_NOT_IMPLEMENTED;
472 : }
473 :
474 : /* readonly attribute PRInt64 fileSizeOfLink; */
475 : NS_IMETHODIMP nsFile::GetFileSizeOfLink(PRInt64 *aFileSizeOfLink)
476 : {
477 : return NS_ERROR_NOT_IMPLEMENTED;
478 : }
479 :
480 : /* readonly attribute AString target; */
481 : NS_IMETHODIMP nsFile::GetTarget(nsAString & aTarget)
482 : {
483 : return NS_ERROR_NOT_IMPLEMENTED;
484 : }
485 :
486 : /* [noscript] readonly attribute ACString nativeTarget; */
487 : NS_IMETHODIMP nsFile::GetNativeTarget(nsACString & aNativeTarget)
488 : {
489 : return NS_ERROR_NOT_IMPLEMENTED;
490 : }
491 :
492 : /* readonly attribute AString path; */
493 : NS_IMETHODIMP nsFile::GetPath(nsAString & aPath)
494 : {
495 : return NS_ERROR_NOT_IMPLEMENTED;
496 : }
497 :
498 : /* [noscript] readonly attribute ACString nativePath; */
499 : NS_IMETHODIMP nsFile::GetNativePath(nsACString & aNativePath)
500 : {
501 : return NS_ERROR_NOT_IMPLEMENTED;
502 : }
503 :
504 : /* boolean exists (); */
505 : NS_IMETHODIMP nsFile::Exists(bool *_retval NS_OUTPARAM)
506 : {
507 : return NS_ERROR_NOT_IMPLEMENTED;
508 : }
509 :
510 : /* boolean isWritable (); */
511 : NS_IMETHODIMP nsFile::IsWritable(bool *_retval NS_OUTPARAM)
512 : {
513 : return NS_ERROR_NOT_IMPLEMENTED;
514 : }
515 :
516 : /* boolean isReadable (); */
517 : NS_IMETHODIMP nsFile::IsReadable(bool *_retval NS_OUTPARAM)
518 : {
519 : return NS_ERROR_NOT_IMPLEMENTED;
520 : }
521 :
522 : /* boolean isExecutable (); */
523 : NS_IMETHODIMP nsFile::IsExecutable(bool *_retval NS_OUTPARAM)
524 : {
525 : return NS_ERROR_NOT_IMPLEMENTED;
526 : }
527 :
528 : /* boolean isHidden (); */
529 : NS_IMETHODIMP nsFile::IsHidden(bool *_retval NS_OUTPARAM)
530 : {
531 : return NS_ERROR_NOT_IMPLEMENTED;
532 : }
533 :
534 : /* boolean isDirectory (); */
535 : NS_IMETHODIMP nsFile::IsDirectory(bool *_retval NS_OUTPARAM)
536 : {
537 : return NS_ERROR_NOT_IMPLEMENTED;
538 : }
539 :
540 : /* boolean isFile (); */
541 : NS_IMETHODIMP nsFile::IsFile(bool *_retval NS_OUTPARAM)
542 : {
543 : return NS_ERROR_NOT_IMPLEMENTED;
544 : }
545 :
546 : /* boolean isSymlink (); */
547 : NS_IMETHODIMP nsFile::IsSymlink(bool *_retval NS_OUTPARAM)
548 : {
549 : return NS_ERROR_NOT_IMPLEMENTED;
550 : }
551 :
552 : /* boolean isSpecial (); */
553 : NS_IMETHODIMP nsFile::IsSpecial(bool *_retval NS_OUTPARAM)
554 : {
555 : return NS_ERROR_NOT_IMPLEMENTED;
556 : }
557 :
558 : /* void createUnique (in unsigned long type, in unsigned long permissions); */
559 : NS_IMETHODIMP nsFile::CreateUnique(PRUint32 type, PRUint32 permissions)
560 : {
561 : return NS_ERROR_NOT_IMPLEMENTED;
562 : }
563 :
564 : /* nsIFile clone (); */
565 : NS_IMETHODIMP nsFile::Clone(nsIFile * *_retval NS_OUTPARAM)
566 : {
567 : return NS_ERROR_NOT_IMPLEMENTED;
568 : }
569 :
570 : /* boolean equals (in nsIFile inFile); */
571 : NS_IMETHODIMP nsFile::Equals(nsIFile *inFile, bool *_retval NS_OUTPARAM)
572 : {
573 : return NS_ERROR_NOT_IMPLEMENTED;
574 : }
575 :
576 : /* boolean contains (in nsIFile inFile, in boolean recur); */
577 : NS_IMETHODIMP nsFile::Contains(nsIFile *inFile, bool recur, bool *_retval NS_OUTPARAM)
578 : {
579 : return NS_ERROR_NOT_IMPLEMENTED;
580 : }
581 :
582 : /* readonly attribute nsIFile parent; */
583 : NS_IMETHODIMP nsFile::GetParent(nsIFile * *aParent)
584 : {
585 : return NS_ERROR_NOT_IMPLEMENTED;
586 : }
587 :
588 : /* readonly attribute nsISimpleEnumerator directoryEntries; */
589 : NS_IMETHODIMP nsFile::GetDirectoryEntries(nsISimpleEnumerator * *aDirectoryEntries)
590 : {
591 : return NS_ERROR_NOT_IMPLEMENTED;
592 : }
593 :
594 : /* End of implementation class template. */
595 : #endif
596 :
597 : #ifdef MOZILLA_INTERNAL_API
598 : #include "nsDirectoryServiceUtils.h"
599 : #endif
600 :
601 : #endif /* __gen_nsIFile_h__ */
|