forked from Floorp-Projects/Floorp
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug 1295570 - Entries API - part 7 - Split WebIDL files, r=smaug
- Loading branch information
Showing
14 changed files
with
114 additions
and
80 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. | ||
*/ | ||
|
||
[NoInterfaceObject] | ||
interface FileSystemDirectoryEntry : FileSystemEntry { | ||
FileSystemDirectoryReader createReader(); | ||
|
||
void getFile(DOMString? path, | ||
optional FileSystemFlags options, | ||
optional FileSystemEntryCallback successCallback, | ||
optional ErrorCallback errorCallback); | ||
|
||
void getDirectory(DOMString? path, | ||
optional FileSystemFlags options, | ||
optional FileSystemEntryCallback successCallback, | ||
optional ErrorCallback errorCallback); | ||
|
||
// This method is not implemented. ErrorCallback will be called | ||
// with NS_ERROR_DOM_NOT_SUPPORTED_ERR. | ||
void removeRecursively(VoidCallback successCallback, | ||
optional ErrorCallback errorCallback); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. | ||
*/ | ||
|
||
callback interface FileSystemEntriesCallback { | ||
void handleEvent(sequence<FileSystemEntry> entries); | ||
}; | ||
|
||
[NoInterfaceObject] | ||
interface FileSystemDirectoryReader { | ||
|
||
// readEntries can be called just once. The second time it returns no data. | ||
|
||
[Throws] | ||
void readEntries(FileSystemEntriesCallback successCallback, | ||
optional ErrorCallback errorCallback); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. | ||
*/ | ||
|
||
[NoInterfaceObject] | ||
interface FileSystemEntry { | ||
readonly attribute boolean isFile; | ||
readonly attribute boolean isDirectory; | ||
|
||
[GetterThrows] | ||
readonly attribute DOMString name; | ||
|
||
[GetterThrows] | ||
readonly attribute DOMString fullPath; | ||
|
||
readonly attribute FileSystem filesystem; | ||
|
||
/** Not implemented: | ||
* void getMetadata(MetadataCallback successCallback, | ||
* optional ErrorCallback errorCallback); | ||
* void moveTo(FileSystemDirectoryEntry parent, optional DOMString? name, | ||
* optional FileSystemEntryCallback successCallback, | ||
* optional ErrorCallback errorCallback); | ||
* void copyTo(FileSystemDirectoryEntry parent, optional DOMString? name, | ||
* optional FileSystemEntryCallback successCallback, | ||
* optional ErrorCallback errorCallback); | ||
* DOMString toURL(); | ||
* void remove(VoidCallback successCallback, | ||
* optional ErrorCallback errorCallback); | ||
* void getParent(optional FileSystemEntryCallback successCallback, | ||
* optional ErrorCallback errorCallback); | ||
*/ | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
/* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */ | ||
/* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this file, | ||
* You can obtain one at http://mozilla.org/MPL/2.0/. | ||
*/ | ||
|
||
callback interface BlobCallback { | ||
void handleEvent(Blob? blob); | ||
}; | ||
|
||
[NoInterfaceObject] | ||
interface FileSystemFileEntry : FileSystemEntry { | ||
// the successCallback should be a FileWriteCallback but this method is not | ||
// implemented. ErrorCallback will be called with | ||
// NS_ERROR_DOM_NOT_SUPPORTED_ERR. | ||
void createWriter (VoidCallback successCallback, | ||
optional ErrorCallback errorCallback); | ||
|
||
[BinaryName="GetFile"] | ||
void file (BlobCallback successCallback, | ||
optional ErrorCallback errorCallback); | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters