001: /* ***** BEGIN LICENSE BLOCK *****
002: * Version: MPL 1.1
003: *
004: * The contents of this file are subject to the Mozilla Public License Version
005: * 1.1 (the "License"); you may not use this file except in compliance with
006: * the License. You may obtain a copy of the License at
007: * http://www.mozilla.org/MPL/
008: *
009: * Software distributed under the License is distributed on an "AS IS" basis,
010: * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
011: * for the specific language governing rights and limitations under the
012: * License.
013: *
014: * The Original Code is Mozilla Communicator client code, released March 31, 1998.
015: *
016: * The Initial Developer of the Original Code is
017: * Netscape Communications Corporation.
018: * Portions created by Netscape are Copyright (C) 1998-1999
019: * Netscape Communications Corporation. All Rights Reserved.
020: *
021: * Contributor(s):
022: *
023: * IBM
024: * - Binding to permit interfacing between Mozilla and SWT
025: * - Copyright (C) 2003, 2005 IBM Corp. All Rights Reserved.
026: *
027: * ***** END LICENSE BLOCK ***** */
028: package org.eclipse.swt.internal.mozilla;
029:
030: public class nsIFile extends nsISupports {
031:
032: static final int LAST_METHOD_ID = nsISupports.LAST_METHOD_ID + 45;
033:
034: public static final String NS_IFILE_IID_STR = "c8c0a080-0868-11d3-915f-d9d889d48e3c";
035:
036: public static final nsID NS_IFILE_IID = new nsID(NS_IFILE_IID_STR);
037:
038: public nsIFile(int /*long*/address) {
039: super (address);
040: }
041:
042: public static final int NORMAL_FILE_TYPE = 0;
043:
044: public static final int DIRECTORY_TYPE = 1;
045:
046: public int Append(int /*long*/node) {
047: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 1,
048: getAddress(), node);
049: }
050:
051: public int AppendNative(int /*long*/node) {
052: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 2,
053: getAddress(), node);
054: }
055:
056: public int Normalize() {
057: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 3,
058: getAddress());
059: }
060:
061: public int Create(int type, int permissions) {
062: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 4,
063: getAddress(), type, permissions);
064: }
065:
066: public int GetLeafName(int /*long*/aLeafName) {
067: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 5,
068: getAddress(), aLeafName);
069: }
070:
071: public int SetLeafName(int /*long*/aLeafName) {
072: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 6,
073: getAddress(), aLeafName);
074: }
075:
076: public int GetNativeLeafName(int /*long*/aNativeLeafName) {
077: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 7,
078: getAddress(), aNativeLeafName);
079: }
080:
081: public int SetNativeLeafName(int /*long*/aNativeLeafName) {
082: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 8,
083: getAddress(), aNativeLeafName);
084: }
085:
086: public int CopyTo(int /*long*/newParentDir, int /*long*/newName) {
087: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 9,
088: getAddress(), newParentDir, newName);
089: }
090:
091: public int CopyToNative(int /*long*/newParentDir,
092: int /*long*/newName) {
093: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 10,
094: getAddress(), newParentDir, newName);
095: }
096:
097: public int CopyToFollowingLinks(int /*long*/newParentDir,
098: int /*long*/newName) {
099: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 11,
100: getAddress(), newParentDir, newName);
101: }
102:
103: public int CopyToFollowingLinksNative(int /*long*/newParentDir,
104: int /*long*/newName) {
105: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 12,
106: getAddress(), newParentDir, newName);
107: }
108:
109: public int MoveTo(int /*long*/newParentDir, int /*long*/newName) {
110: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 13,
111: getAddress(), newParentDir, newName);
112: }
113:
114: public int MoveToNative(int /*long*/newParentDir,
115: int /*long*/newName) {
116: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 14,
117: getAddress(), newParentDir, newName);
118: }
119:
120: public int Remove(boolean recursive) {
121: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 15,
122: getAddress(), recursive);
123: }
124:
125: public int GetPermissions(int[] aPermissions) {
126: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 16,
127: getAddress(), aPermissions);
128: }
129:
130: public int SetPermissions(int aPermissions) {
131: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 17,
132: getAddress(), aPermissions);
133: }
134:
135: public int GetPermissionsOfLink(int[] aPermissionsOfLink) {
136: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 18,
137: getAddress(), aPermissionsOfLink);
138: }
139:
140: public int SetPermissionsOfLink(int aPermissionsOfLink) {
141: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 19,
142: getAddress(), aPermissionsOfLink);
143: }
144:
145: public int GetLastModifiedTime(long[] aLastModifiedTime) {
146: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 20,
147: getAddress(), aLastModifiedTime);
148: }
149:
150: public int SetLastModifiedTime(long aLastModifiedTime) {
151: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 21,
152: getAddress(), aLastModifiedTime);
153: }
154:
155: public int GetLastModifiedTimeOfLink(long[] aLastModifiedTimeOfLink) {
156: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 22,
157: getAddress(), aLastModifiedTimeOfLink);
158: }
159:
160: public int SetLastModifiedTimeOfLink(long aLastModifiedTimeOfLink) {
161: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 23,
162: getAddress(), aLastModifiedTimeOfLink);
163: }
164:
165: public int GetFileSize(long[] aFileSize) {
166: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 24,
167: getAddress(), aFileSize);
168: }
169:
170: public int SetFileSize(long aFileSize) {
171: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 25,
172: getAddress(), aFileSize);
173: }
174:
175: public int GetFileSizeOfLink(long[] aFileSizeOfLink) {
176: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 26,
177: getAddress(), aFileSizeOfLink);
178: }
179:
180: public int GetTarget(int /*long*/aTarget) {
181: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 27,
182: getAddress(), aTarget);
183: }
184:
185: public int GetNativeTarget(int /*long*/aNativeTarget) {
186: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 28,
187: getAddress(), aNativeTarget);
188: }
189:
190: public int GetPath(int /*long*/aPath) {
191: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 29,
192: getAddress(), aPath);
193: }
194:
195: public int GetNativePath(int /*long*/aNativePath) {
196: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 30,
197: getAddress(), aNativePath);
198: }
199:
200: public int Exists(boolean[] _retval) {
201: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 31,
202: getAddress(), _retval);
203: }
204:
205: public int IsWritable(boolean[] _retval) {
206: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 32,
207: getAddress(), _retval);
208: }
209:
210: public int IsReadable(boolean[] _retval) {
211: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 33,
212: getAddress(), _retval);
213: }
214:
215: public int IsExecutable(boolean[] _retval) {
216: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 34,
217: getAddress(), _retval);
218: }
219:
220: public int IsHidden(boolean[] _retval) {
221: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 35,
222: getAddress(), _retval);
223: }
224:
225: public int IsDirectory(boolean[] _retval) {
226: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 36,
227: getAddress(), _retval);
228: }
229:
230: public int IsFile(boolean[] _retval) {
231: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 37,
232: getAddress(), _retval);
233: }
234:
235: public int IsSymlink(boolean[] _retval) {
236: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 38,
237: getAddress(), _retval);
238: }
239:
240: public int IsSpecial(boolean[] _retval) {
241: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 39,
242: getAddress(), _retval);
243: }
244:
245: public int CreateUnique(int type, int permissions) {
246: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 40,
247: getAddress(), type, permissions);
248: }
249:
250: public int Clone(int /*long*/[] _retval) {
251: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 41,
252: getAddress(), _retval);
253: }
254:
255: public int Equals(int /*long*/inFile, boolean[] _retval) {
256: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 42,
257: getAddress(), inFile, _retval);
258: }
259:
260: public int Contains(int /*long*/inFile, boolean recur,
261: boolean[] _retval) {
262: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 43,
263: getAddress(), inFile, recur, _retval);
264: }
265:
266: public int GetParent(int /*long*/[] aParent) {
267: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 44,
268: getAddress(), aParent);
269: }
270:
271: public int GetDirectoryEntries(int /*long*/[] aDirectoryEntries) {
272: return XPCOM.VtblCall(nsISupports.LAST_METHOD_ID + 45,
273: getAddress(), aDirectoryEntries);
274: }
275: }
|