Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // SSSSSSSSSSSSSSS TTTTTTTTTTTTTTTTTTTTTTT OOOOOOOOO PPPPPPPPPPPPPPPP P | 1 // SSSSSSSSSSSSSSS TTTTTTTTTTTTTTTTTTTTTTT OOOOOOOOO PPPPPPPPPPPPPPPP P |
| 2 // SS:::::::::::::::ST:::::::::::::::::::::T OO:::::::::OO P::::::::::::::: :P | 2 // SS:::::::::::::::ST:::::::::::::::::::::T OO:::::::::OO P::::::::::::::: :P |
| 3 // S:::::SSSSSS::::::ST:::::::::::::::::::::T OO:::::::::::::OO P::::::PPPPPP::: ::P | 3 // S:::::SSSSSS::::::ST:::::::::::::::::::::T OO:::::::::::::OO P::::::PPPPPP::: ::P |
| 4 // S:::::S SSSSSSST:::::TT:::::::TT:::::TO:::::::OOO:::::::OPP:::::P P:: :::P | 4 // S:::::S SSSSSSST:::::TT:::::::TT:::::TO:::::::OOO:::::::OPP:::::P P:: :::P |
| 5 // S:::::S TTTTTT T:::::T TTTTTTO::::::O O::::::O P::::P P:: :::P | 5 // S:::::S TTTTTT T:::::T TTTTTTO::::::O O::::::O P::::P P:: :::P |
| 6 // S:::::S T:::::T O:::::O O:::::O P::::P P:: :::P | 6 // S:::::S T:::::T O:::::O O:::::O P::::P P:: :::P |
| 7 // S::::SSSS P::::PPPPPP::: ::P | 7 // S::::SSSS P::::PPPPPP::: ::P |
| 8 // SS::::::SSSSS This file is generated. To update it, P::::::::::::: PP | 8 // SS::::::SSSSS This file is generated. To update it, P::::::::::::: PP |
| 9 // SSS::::::::SS run roll_closure_compiler. P::::PPPPPPPPP | 9 // SSS::::::::SS run roll_closure_compiler. P::::PPPPPPPPP |
| 10 // SSSSSS::::S P::::P | 10 // SSSSSS::::S P::::P |
| (...skipping 10622 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 10633 /** @return {boolean} */ | 10633 /** @return {boolean} */ |
| 10634 chrome.downloads.DeterminingFilenameEvent.prototype.hasListeners = | 10634 chrome.downloads.DeterminingFilenameEvent.prototype.hasListeners = |
| 10635 function() {}; | 10635 function() {}; |
| 10636 | 10636 |
| 10637 | 10637 |
| 10638 /** | 10638 /** |
| 10639 * @type {!chrome.downloads.DeterminingFilenameEvent} | 10639 * @type {!chrome.downloads.DeterminingFilenameEvent} |
| 10640 * https://developer.chrome.com/extensions/downloads#event-onDeterminingFilename | 10640 * https://developer.chrome.com/extensions/downloads#event-onDeterminingFilename |
| 10641 */ | 10641 */ |
| 10642 chrome.downloads.onDeterminingFilename; | 10642 chrome.downloads.onDeterminingFilename; |
| 10643 | |
| 10644 | |
| 10645 /** | |
| 10646 * @const | |
| 10647 */ | |
| 10648 chrome.fileSystemProvider = {}; | |
|
fukino
2017/01/18 03:01:37
Adding chrome.fileSystemPrivider API needs to be d
| |
| 10649 | |
| 10650 /** | |
| 10651 * @enum {string} | |
| 10652 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-Provider Error | |
| 10653 */ | |
| 10654 chrome.fileSystemProvider.ProviderError = { | |
| 10655 OK: 'OK', | |
| 10656 FAILED: 'FAILED', | |
| 10657 IN_USE: 'IN_USE', | |
| 10658 EXISTS: 'EXISTS', | |
| 10659 NOT_FOUND: 'NOT_FOUND', | |
| 10660 ACCESS_DENIED: 'ACCESS_DENIED', | |
| 10661 TOO_MANY_OPENED: 'TOO_MANY_OPENED', | |
| 10662 NO_MEMORY: 'NO_MEMORY', | |
| 10663 NO_SPACE: 'NO_SPACE', | |
| 10664 NOT_A_DIRECTORY: 'NOT_A_DIRECTORY', | |
| 10665 INVALID_OPERATION: 'INVALID_OPERATION', | |
| 10666 SECURITY: 'SECURITY', | |
| 10667 ABORT: 'ABORT', | |
| 10668 NOT_A_FILE: 'NOT_A_FILE', | |
| 10669 NOT_EMPTY: 'NOT_EMPTY', | |
| 10670 INVALID_URL: 'INVALID_URL', | |
| 10671 IO: 'IO', | |
| 10672 }; | |
| 10673 | |
| 10674 /** | |
| 10675 * @enum {string} | |
| 10676 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-OpenFile Mode | |
| 10677 */ | |
| 10678 chrome.fileSystemProvider.OpenFileMode = { | |
| 10679 READ: 'READ', | |
| 10680 WRITE: 'WRITE', | |
| 10681 }; | |
| 10682 | |
| 10683 /** | |
| 10684 * @enum {string} | |
| 10685 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-ChangeTy pe | |
| 10686 */ | |
| 10687 chrome.fileSystemProvider.ChangeType = { | |
| 10688 CHANGED: 'CHANGED', | |
| 10689 DELETED: 'DELETED', | |
| 10690 }; | |
| 10691 | |
| 10692 /** | |
| 10693 * @enum {string} | |
| 10694 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-CommonAc tionId | |
| 10695 */ | |
| 10696 chrome.fileSystemProvider.CommonActionId = { | |
| 10697 SAVE_FOR_OFFLINE: 'SAVE_FOR_OFFLINE', | |
| 10698 OFFLINE_NOT_NECESSARY: 'OFFLINE_NOT_NECESSARY', | |
| 10699 SHARE: 'SHARE', | |
| 10700 }; | |
| 10701 | |
| 10702 /** | |
| 10703 * @typedef {{ | |
| 10704 * isDirectory: (boolean|undefined), | |
| 10705 * name: (string|undefined), | |
| 10706 * size: (number|undefined), | |
| 10707 * modificationTime: (Object|undefined), | |
| 10708 * mimeType: (string|undefined), | |
| 10709 * thumbnail: (string|undefined) | |
| 10710 * }} | |
| 10711 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-EntryMet adata | |
| 10712 */ | |
| 10713 chrome.fileSystemProvider.EntryMetadata; | |
| 10714 | |
| 10715 /** | |
| 10716 * @typedef {{ | |
| 10717 * entryPath: string, | |
| 10718 * recursive: boolean, | |
| 10719 * lastTag: (string|undefined) | |
| 10720 * }} | |
| 10721 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-Watcher | |
| 10722 */ | |
| 10723 chrome.fileSystemProvider.Watcher; | |
| 10724 | |
| 10725 /** | |
| 10726 * @typedef {{ | |
| 10727 * openRequestId: number, | |
| 10728 * filePath: string, | |
| 10729 * mode: !chrome.fileSystemProvider.OpenFileMode | |
| 10730 * }} | |
| 10731 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-OpenedFi le | |
| 10732 */ | |
| 10733 chrome.fileSystemProvider.OpenedFile; | |
| 10734 | |
| 10735 /** | |
| 10736 * @typedef {{ | |
| 10737 * fileSystemId: string, | |
| 10738 * displayName: string, | |
| 10739 * writable: boolean, | |
| 10740 * openedFilesLimit: number, | |
| 10741 * openedFiles: !Array<!chrome.fileSystemProvider.OpenedFile>, | |
| 10742 * supportsNotifyTag: (boolean|undefined), | |
| 10743 * watchers: !Array<!chrome.fileSystemProvider.Watcher> | |
| 10744 * }} | |
| 10745 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-FileSyst emInfo | |
| 10746 */ | |
| 10747 chrome.fileSystemProvider.FileSystemInfo; | |
| 10748 | |
| 10749 /** | |
| 10750 * @typedef {{ | |
| 10751 * fileSystemId: string, | |
| 10752 * displayName: string, | |
| 10753 * writable: (boolean|undefined), | |
| 10754 * openedFilesLimit: (number|undefined), | |
| 10755 * supportsNotifyTag: (boolean|undefined) | |
| 10756 * }} | |
| 10757 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-MountOpt ions | |
| 10758 */ | |
| 10759 chrome.fileSystemProvider.MountOptions; | |
| 10760 | |
| 10761 /** | |
| 10762 * @typedef {{ | |
| 10763 * fileSystemId: string | |
| 10764 * }} | |
| 10765 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-UnmountO ptions | |
| 10766 */ | |
| 10767 chrome.fileSystemProvider.UnmountOptions; | |
| 10768 | |
| 10769 /** | |
| 10770 * @typedef {{ | |
| 10771 * fileSystemId: string, | |
| 10772 * requestId: number | |
| 10773 * }} | |
| 10774 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-UnmountR equestedOptions | |
| 10775 */ | |
| 10776 chrome.fileSystemProvider.UnmountRequestedOptions; | |
| 10777 | |
| 10778 /** | |
| 10779 * @typedef {{ | |
| 10780 * fileSystemId: string, | |
| 10781 * requestId: number, | |
| 10782 * entryPath: string, | |
| 10783 * isDirectory: boolean, | |
| 10784 * name: boolean, | |
| 10785 * size: boolean, | |
| 10786 * modificationTime: boolean, | |
| 10787 * mimeType: boolean, | |
| 10788 * thumbnail: boolean | |
| 10789 * }} | |
| 10790 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-GetMetad ataRequestedOptions | |
| 10791 */ | |
| 10792 chrome.fileSystemProvider.GetMetadataRequestedOptions; | |
| 10793 | |
| 10794 /** | |
| 10795 * @typedef {{ | |
| 10796 * fileSystemId: string, | |
| 10797 * requestId: number, | |
| 10798 * entryPaths: !Array<string> | |
| 10799 * }} | |
| 10800 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-GetActio nsRequestedOptions | |
| 10801 */ | |
| 10802 chrome.fileSystemProvider.GetActionsRequestedOptions; | |
| 10803 | |
| 10804 /** | |
| 10805 * @typedef {{ | |
| 10806 * fileSystemId: string, | |
| 10807 * requestId: number, | |
| 10808 * directoryPath: string, | |
| 10809 * isDirectory: boolean, | |
| 10810 * name: boolean, | |
| 10811 * size: boolean, | |
| 10812 * modificationTime: boolean, | |
| 10813 * mimeType: boolean, | |
| 10814 * thumbnail: boolean | |
| 10815 * }} | |
| 10816 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-ReadDire ctoryRequestedOptions | |
| 10817 */ | |
| 10818 chrome.fileSystemProvider.ReadDirectoryRequestedOptions; | |
| 10819 | |
| 10820 /** | |
| 10821 * @typedef {{ | |
| 10822 * fileSystemId: string, | |
| 10823 * requestId: number, | |
| 10824 * filePath: string, | |
| 10825 * mode: !chrome.fileSystemProvider.OpenFileMode | |
| 10826 * }} | |
| 10827 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-OpenFile RequestedOptions | |
| 10828 */ | |
| 10829 chrome.fileSystemProvider.OpenFileRequestedOptions; | |
| 10830 | |
| 10831 /** | |
| 10832 * @typedef {{ | |
| 10833 * fileSystemId: string, | |
| 10834 * requestId: number, | |
| 10835 * openRequestId: number | |
| 10836 * }} | |
| 10837 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-CloseFil eRequestedOptions | |
| 10838 */ | |
| 10839 chrome.fileSystemProvider.CloseFileRequestedOptions; | |
| 10840 | |
| 10841 /** | |
| 10842 * @typedef {{ | |
| 10843 * fileSystemId: string, | |
| 10844 * requestId: number, | |
| 10845 * openRequestId: number, | |
| 10846 * offset: number, | |
| 10847 * length: number | |
| 10848 * }} | |
| 10849 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-ReadFile RequestedOptions | |
| 10850 */ | |
| 10851 chrome.fileSystemProvider.ReadFileRequestedOptions; | |
| 10852 | |
| 10853 /** | |
| 10854 * @typedef {{ | |
| 10855 * fileSystemId: string, | |
| 10856 * requestId: number, | |
| 10857 * directoryPath: string, | |
| 10858 * recursive: boolean | |
| 10859 * }} | |
| 10860 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-CreateDi rectoryRequestedOptions | |
| 10861 */ | |
| 10862 chrome.fileSystemProvider.CreateDirectoryRequestedOptions; | |
| 10863 | |
| 10864 /** | |
| 10865 * @typedef {{ | |
| 10866 * fileSystemId: string, | |
| 10867 * requestId: number, | |
| 10868 * entryPath: string, | |
| 10869 * recursive: boolean | |
| 10870 * }} | |
| 10871 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-DeleteEn tryRequestedOptions | |
| 10872 */ | |
| 10873 chrome.fileSystemProvider.DeleteEntryRequestedOptions; | |
| 10874 | |
| 10875 /** | |
| 10876 * @typedef {{ | |
| 10877 * fileSystemId: string, | |
| 10878 * requestId: number, | |
| 10879 * filePath: string | |
| 10880 * }} | |
| 10881 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-CreateFi leRequestedOptions | |
| 10882 */ | |
| 10883 chrome.fileSystemProvider.CreateFileRequestedOptions; | |
| 10884 | |
| 10885 /** | |
| 10886 * @typedef {{ | |
| 10887 * fileSystemId: string, | |
| 10888 * requestId: number, | |
| 10889 * sourcePath: string, | |
| 10890 * targetPath: string | |
| 10891 * }} | |
| 10892 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-CopyEntr yRequestedOptions | |
| 10893 */ | |
| 10894 chrome.fileSystemProvider.CopyEntryRequestedOptions; | |
| 10895 | |
| 10896 /** | |
| 10897 * @typedef {{ | |
| 10898 * fileSystemId: string, | |
| 10899 * requestId: number, | |
| 10900 * sourcePath: string, | |
| 10901 * targetPath: string | |
| 10902 * }} | |
| 10903 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-MoveEntr yRequestedOptions | |
| 10904 */ | |
| 10905 chrome.fileSystemProvider.MoveEntryRequestedOptions; | |
| 10906 | |
| 10907 /** | |
| 10908 * @typedef {{ | |
| 10909 * fileSystemId: string, | |
| 10910 * requestId: number, | |
| 10911 * filePath: string, | |
| 10912 * length: number | |
| 10913 * }} | |
| 10914 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-Truncate RequestedOptions | |
| 10915 */ | |
| 10916 chrome.fileSystemProvider.TruncateRequestedOptions; | |
| 10917 | |
| 10918 /** | |
| 10919 * @typedef {{ | |
| 10920 * fileSystemId: string, | |
| 10921 * requestId: number, | |
| 10922 * openRequestId: number, | |
| 10923 * offset: number, | |
| 10924 * data: ArrayBuffer | |
| 10925 * }} | |
| 10926 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-WriteFil eRequestedOptions | |
| 10927 */ | |
| 10928 chrome.fileSystemProvider.WriteFileRequestedOptions; | |
| 10929 | |
| 10930 /** | |
| 10931 * @typedef {{ | |
| 10932 * fileSystemId: string, | |
| 10933 * requestId: number, | |
| 10934 * operationRequestId: number | |
| 10935 * }} | |
| 10936 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-AbortReq uestedOptions | |
| 10937 */ | |
| 10938 chrome.fileSystemProvider.AbortRequestedOptions; | |
| 10939 | |
| 10940 /** | |
| 10941 * @typedef {{ | |
| 10942 * fileSystemId: string, | |
| 10943 * requestId: number, | |
| 10944 * entryPath: string, | |
| 10945 * recursive: boolean | |
| 10946 * }} | |
| 10947 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-AddWatch erRequestedOptions | |
| 10948 */ | |
| 10949 chrome.fileSystemProvider.AddWatcherRequestedOptions; | |
| 10950 | |
| 10951 /** | |
| 10952 * @typedef {{ | |
| 10953 * fileSystemId: string, | |
| 10954 * requestId: number, | |
| 10955 * entryPath: string, | |
| 10956 * recursive: boolean | |
| 10957 * }} | |
| 10958 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-RemoveWa tcherRequestedOptions | |
| 10959 */ | |
| 10960 chrome.fileSystemProvider.RemoveWatcherRequestedOptions; | |
| 10961 | |
| 10962 /** | |
| 10963 * @typedef {{ | |
| 10964 * id: string, | |
| 10965 * title: (string|undefined) | |
| 10966 * }} | |
| 10967 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-Action | |
| 10968 */ | |
| 10969 chrome.fileSystemProvider.Action; | |
| 10970 | |
| 10971 /** | |
| 10972 * @typedef {{ | |
| 10973 * fileSystemId: string, | |
| 10974 * requestId: number, | |
| 10975 * entryPaths: !Array<string>, | |
| 10976 * actionId: string | |
| 10977 * }} | |
| 10978 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-ExecuteA ctionRequestedOptions | |
| 10979 */ | |
| 10980 chrome.fileSystemProvider.ExecuteActionRequestedOptions; | |
| 10981 | |
| 10982 /** | |
| 10983 * @typedef {{ | |
| 10984 * entryPath: string, | |
| 10985 * changeType: !chrome.fileSystemProvider.ChangeType | |
| 10986 * }} | |
| 10987 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-Change | |
| 10988 */ | |
| 10989 chrome.fileSystemProvider.Change; | |
| 10990 | |
| 10991 /** | |
| 10992 * @typedef {{ | |
| 10993 * fileSystemId: string, | |
| 10994 * observedPath: string, | |
| 10995 * recursive: boolean, | |
| 10996 * changeType: !chrome.fileSystemProvider.ChangeType, | |
| 10997 * changes: (!Array<!chrome.fileSystemProvider.Change>|undefined), | |
| 10998 * tag: (string|undefined) | |
| 10999 * }} | |
| 11000 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-NotifyOp tions | |
| 11001 */ | |
| 11002 chrome.fileSystemProvider.NotifyOptions; | |
| 11003 | |
| 11004 /** | |
| 11005 * @typedef {{ | |
| 11006 * fileSystemId: string, | |
| 11007 * requestId: number | |
| 11008 * }} | |
| 11009 * @see https://developer.chrome.com/extensions/fileSystemProvider#type-Configur eRequestedOptions | |
| 11010 */ | |
| 11011 chrome.fileSystemProvider.ConfigureRequestedOptions; | |
| 11012 | |
| 11013 /** | |
| 11014 * <p>Mounts a file system with the given <code>fileSystemId</code> and | |
| 11015 * <code>displayName</code>. <code>displayName</code> will be shown in the left | |
| 11016 * panel of Files.app. <code>displayName</code> can contain any characters | |
| 11017 * including '/', but cannot be an empty string. <code>displayName</code> must | |
| 11018 * be descriptive but doesn't have to be unique. The <code>fileSystemId</code> | |
| 11019 * must not be an empty string.</p><p>Depending on the type of the file system | |
| 11020 * being mounted, the <code>source</code> option must be set | |
| 11021 * appropriately.</p><p>In case of an error, $(ref:runtime.lastError) will be | |
| 11022 * set with a corresponding error code.</p> | |
| 11023 * @param {!chrome.fileSystemProvider.MountOptions} options | |
| 11024 * @param {function():void=} callback A generic result callback to indicate | |
| 11025 * success or failure. | |
| 11026 * @see https://developer.chrome.com/extensions/fileSystemProvider#method-mount | |
| 11027 */ | |
| 11028 chrome.fileSystemProvider.mount = function(options, callback) {}; | |
| 11029 | |
| 11030 /** | |
| 11031 * <p>Unmounts a file system with the given <code>fileSystemId</code>. It must | |
| 11032 * be called after $(ref:onUnmountRequested) is invoked. Also, the providing | |
| 11033 * extension can decide to perform unmounting if not requested (eg. in case of | |
| 11034 * lost connection, or a file error).</p><p>In case of an error, | |
| 11035 * $(ref:runtime.lastError) will be set with a corresponding error code.</p> | |
| 11036 * @param {!chrome.fileSystemProvider.UnmountOptions} options | |
| 11037 * @param {function():void=} callback A generic result callback to indicate | |
| 11038 * success or failure. | |
| 11039 * @see https://developer.chrome.com/extensions/fileSystemProvider#method-unmoun t | |
| 11040 */ | |
| 11041 chrome.fileSystemProvider.unmount = function(options, callback) {}; | |
| 11042 | |
| 11043 /** | |
| 11044 * Returns all file systems mounted by the extension. | |
| 11045 * @param {function(!Array<!chrome.fileSystemProvider.FileSystemInfo>):void} | |
| 11046 * callback Callback to receive the result of $(ref:getAll) function. | |
| 11047 * @see https://developer.chrome.com/extensions/fileSystemProvider#method-getAll | |
| 11048 */ | |
| 11049 chrome.fileSystemProvider.getAll = function(callback) {}; | |
| 11050 | |
| 11051 /** | |
| 11052 * Returns information about a file system with the passed | |
| 11053 * <code>fileSystemId</code>. | |
| 11054 * @param {string} fileSystemId | |
| 11055 * @param {function(!chrome.fileSystemProvider.FileSystemInfo):void} callback | |
| 11056 * Callback to receive the result of $(ref:get) function. | |
| 11057 * @see https://developer.chrome.com/extensions/fileSystemProvider#method-get | |
| 11058 */ | |
| 11059 chrome.fileSystemProvider.get = function(fileSystemId, callback) {}; | |
| 11060 | |
| 11061 /** | |
| 11062 * <p>Notifies about changes in the watched directory at | |
| 11063 * <code>observedPath</code> in <code>recursive</code> mode. If the file system | |
| 11064 * is mounted with <code>supportsNofityTag</code>, then <code>tag</code> must be | |
| 11065 * provided, and all changes since the last notification always reported, even | |
| 11066 * if the system was shutdown. The last tag can be obtained with | |
| 11067 * $(ref:getAll).</p><p>To use, the <code>file_system_provider.notify</code> | |
| 11068 * manifest option must be set to true.</p><p>Value of <code>tag</code> can be | |
| 11069 * any string which is unique per call, so it's possible to identify the last | |
| 11070 * registered notification. Eg. if the providing extension starts after a | |
| 11071 * reboot, and the last registered notification's tag is equal to "123", then it | |
| 11072 * should call $(ref:notify) for all changes which happened since the change | |
| 11073 * tagged as "123". It cannot be an empty string.</p><p>Not all providers are | |
| 11074 * able to provide a tag, but if the file system has a changelog, then the tag | |
| 11075 * can be eg. a change number, or a revision number.</p><p>Note that if a parent | |
| 11076 * directory is removed, then all descendant entries are also removed, and if | |
| 11077 * they are watched, then the API must be notified about the fact. Also, if a | |
| 11078 * directory is renamed, then all descendant entries are in fact removed, as | |
| 11079 * there is no entry under their original paths anymore.</p><p>In case of an | |
| 11080 * error, $(ref:runtime.lastError) will be set will a corresponding error | |
| 11081 * code.</p> | |
| 11082 * @param {!chrome.fileSystemProvider.NotifyOptions} options | |
| 11083 * @param {function():void=} callback A generic result callback to indicate | |
| 11084 * success or failure. | |
| 11085 * @see https://developer.chrome.com/extensions/fileSystemProvider#method-notify | |
| 11086 */ | |
| 11087 chrome.fileSystemProvider.notify = function(options, callback) {}; | |
| 11088 | |
| 11089 /** | |
| 11090 * Raised when unmounting for the file system with the <code>fileSystemId</code> | |
| 11091 * identifier is requested. In the response, the $(ref:unmount) API method must | |
| 11092 * be called together with <code>successCallback</code>. If unmounting is not | |
| 11093 * possible (eg. due to a pending operation), then <code>errorCallback</code> | |
| 11094 * must be called. | |
| 11095 * @type {!ChromeEvent} | |
| 11096 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onUnmou ntRequested | |
| 11097 */ | |
| 11098 chrome.fileSystemProvider.onUnmountRequested; | |
| 11099 | |
| 11100 /** | |
| 11101 * Raised when metadata of a file or a directory at <code>entryPath</code> is | |
| 11102 * requested. The metadata must be returned with the | |
| 11103 * <code>successCallback</code> call. In case of an error, | |
| 11104 * <code>errorCallback</code> must be called. | |
| 11105 * @type {!ChromeEvent} | |
| 11106 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onGetMe tadataRequested | |
| 11107 */ | |
| 11108 chrome.fileSystemProvider.onGetMetadataRequested; | |
| 11109 | |
| 11110 /** | |
| 11111 * Raised when a list of actions for a set of files or directories at | |
| 11112 * <code>entryPaths</code> is requested. All of the returned actions must be | |
| 11113 * applicable to each entry. If there are no such actions, an empty array should | |
| 11114 * be returned. The actions must be returned with the | |
| 11115 * <code>successCallback</code> call. In case of an error, | |
| 11116 * <code>errorCallback</code> must be called. | |
| 11117 * @type {!ChromeEvent} | |
| 11118 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onGetAc tionsRequested | |
| 11119 */ | |
| 11120 chrome.fileSystemProvider.onGetActionsRequested; | |
| 11121 | |
| 11122 /** | |
| 11123 * Raised when contents of a directory at <code>directoryPath</code> are | |
| 11124 * requested. The results must be returned in chunks by calling the | |
| 11125 * <code>successCallback</code> several times. In case of an error, | |
| 11126 * <code>errorCallback</code> must be called. | |
| 11127 * @type {!ChromeEvent} | |
| 11128 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onReadD irectoryRequested | |
| 11129 */ | |
| 11130 chrome.fileSystemProvider.onReadDirectoryRequested; | |
| 11131 | |
| 11132 /** | |
| 11133 * Raised when opening a file at <code>filePath</code> is requested. If the file | |
| 11134 * does not exist, then the operation must fail. Maximum number of files opened | |
| 11135 * at once can be specified with <code>MountOptions</code>. | |
| 11136 * @type {!ChromeEvent} | |
| 11137 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onOpenF ileRequested | |
| 11138 */ | |
| 11139 chrome.fileSystemProvider.onOpenFileRequested; | |
| 11140 | |
| 11141 /** | |
| 11142 * Raised when opening a file previously opened with <code>openRequestId</code> | |
| 11143 * is requested to be closed. | |
| 11144 * @type {!ChromeEvent} | |
| 11145 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onClose FileRequested | |
| 11146 */ | |
| 11147 chrome.fileSystemProvider.onCloseFileRequested; | |
| 11148 | |
| 11149 /** | |
| 11150 * Raised when reading contents of a file opened previously with | |
| 11151 * <code>openRequestId</code> is requested. The results must be returned in | |
| 11152 * chunks by calling <code>successCallback</code> several times. In case of an | |
| 11153 * error, <code>errorCallback</code> must be called. | |
| 11154 * @type {!ChromeEvent} | |
| 11155 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onReadF ileRequested | |
| 11156 */ | |
| 11157 chrome.fileSystemProvider.onReadFileRequested; | |
| 11158 | |
| 11159 /** | |
| 11160 * Raised when creating a directory is requested. The operation must fail with | |
| 11161 * the EXISTS error if the target directory already exists. If | |
| 11162 * <code>recursive</code> is true, then all of the missing directories on the | |
| 11163 * directory path must be created. | |
| 11164 * @type {!ChromeEvent} | |
| 11165 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onCreat eDirectoryRequested | |
| 11166 */ | |
| 11167 chrome.fileSystemProvider.onCreateDirectoryRequested; | |
| 11168 | |
| 11169 /** | |
| 11170 * Raised when deleting an entry is requested. If <code>recursive</code> is | |
| 11171 * true, and the entry is a directory, then all of the entries inside must be | |
| 11172 * recursively deleted as well. | |
| 11173 * @type {!ChromeEvent} | |
| 11174 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onDelet eEntryRequested | |
| 11175 */ | |
| 11176 chrome.fileSystemProvider.onDeleteEntryRequested; | |
| 11177 | |
| 11178 /** | |
| 11179 * Raised when creating a file is requested. If the file already exists, then | |
| 11180 * <code>errorCallback</code> must be called with the <code>"EXISTS"</code> | |
| 11181 * error code. | |
| 11182 * @type {!ChromeEvent} | |
| 11183 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onCreat eFileRequested | |
| 11184 */ | |
| 11185 chrome.fileSystemProvider.onCreateFileRequested; | |
| 11186 | |
| 11187 /** | |
| 11188 * Raised when copying an entry (recursively if a directory) is requested. If an | |
| 11189 * error occurs, then <code>errorCallback</code> must be called. | |
| 11190 * @type {!ChromeEvent} | |
| 11191 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onCopyE ntryRequested | |
| 11192 */ | |
| 11193 chrome.fileSystemProvider.onCopyEntryRequested; | |
| 11194 | |
| 11195 /** | |
| 11196 * Raised when moving an entry (recursively if a directory) is requested. If an | |
| 11197 * error occurs, then <code>errorCallback</code> must be called. | |
| 11198 * @type {!ChromeEvent} | |
| 11199 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onMoveE ntryRequested | |
| 11200 */ | |
| 11201 chrome.fileSystemProvider.onMoveEntryRequested; | |
| 11202 | |
| 11203 /** | |
| 11204 * Raised when truncating a file to a desired length is requested. If an error | |
| 11205 * occurs, then <code>errorCallback</code> must be called. | |
| 11206 * @type {!ChromeEvent} | |
| 11207 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onTrunc ateRequested | |
| 11208 */ | |
| 11209 chrome.fileSystemProvider.onTruncateRequested; | |
| 11210 | |
| 11211 /** | |
| 11212 * Raised when writing contents to a file opened previously with | |
| 11213 * <code>openRequestId</code> is requested. | |
| 11214 * @type {!ChromeEvent} | |
| 11215 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onWrite FileRequested | |
| 11216 */ | |
| 11217 chrome.fileSystemProvider.onWriteFileRequested; | |
| 11218 | |
| 11219 /** | |
| 11220 * Raised when aborting an operation with <code>operationRequestId</code> is | |
| 11221 * requested. The operation executed with <code>operationRequestId</code> must | |
| 11222 * be immediately stopped and <code>successCallback</code> of this abort request | |
| 11223 * executed. If aborting fails, then <code>errorCallback</code> must be called. | |
| 11224 * Note, that callbacks of the aborted operation must not be called, as they | |
| 11225 * will be ignored. Despite calling <code>errorCallback</code>, the request may | |
| 11226 * be forcibly aborted. | |
| 11227 * @type {!ChromeEvent} | |
| 11228 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onAbort Requested | |
| 11229 */ | |
| 11230 chrome.fileSystemProvider.onAbortRequested; | |
| 11231 | |
| 11232 /** | |
| 11233 * Raised when showing a configuration dialog for <code>fileSystemId</code> is | |
| 11234 * requested. If it's handled, the | |
| 11235 * <code>file_system_provider.configurable</code> manfiest option must be set to | |
| 11236 * true. | |
| 11237 * @type {!ChromeEvent} | |
| 11238 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onConfi gureRequested | |
| 11239 */ | |
| 11240 chrome.fileSystemProvider.onConfigureRequested; | |
| 11241 | |
| 11242 /** | |
| 11243 * Raised when showing a dialog for mounting a new file system is requested. If | |
| 11244 * the extension/app is a file handler, then this event shouldn't be handled. | |
| 11245 * Instead <code>app.runtime.onLaunched</code> should be handled in order to | |
| 11246 * mount new file systems when a file is opened. For multiple mounts, the | |
| 11247 * <code>file_system_provider.multiple_mounts</code> manifest option must be set | |
| 11248 * to true. | |
| 11249 * @type {!ChromeEvent} | |
| 11250 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onMount Requested | |
| 11251 */ | |
| 11252 chrome.fileSystemProvider.onMountRequested; | |
| 11253 | |
| 11254 /** | |
| 11255 * Raised when setting a new directory watcher is requested. If an error occurs, | |
| 11256 * then <code>errorCallback</code> must be called. | |
| 11257 * @type {!ChromeEvent} | |
| 11258 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onAddWa tcherRequested | |
| 11259 */ | |
| 11260 chrome.fileSystemProvider.onAddWatcherRequested; | |
| 11261 | |
| 11262 /** | |
| 11263 * Raised when the watcher should be removed. If an error occurs, then | |
| 11264 * <code>errorCallback</code> must be called. | |
| 11265 * @type {!ChromeEvent} | |
| 11266 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onRemov eWatcherRequested | |
| 11267 */ | |
| 11268 chrome.fileSystemProvider.onRemoveWatcherRequested; | |
| 11269 | |
| 11270 /** | |
| 11271 * Raised when executing an action for a set of files or directories is\ | |
| 11272 * requested. After the action is completed, <code>successCallback</code> must | |
| 11273 * be called. On error, <code>errorCallback</code> must be called. | |
| 11274 * @type {!ChromeEvent} | |
| 11275 * @see https://developer.chrome.com/extensions/fileSystemProvider#event-onExecu teActionRequested | |
| 11276 */ | |
| 11277 chrome.fileSystemProvider.onExecuteActionRequested; | |
| OLD | NEW |