Use the chrome.fileSystemProvider API to create file systems, that can be accessible from the file manager on Chrome OS.
Use the chrome.fileSystemProvider API to create file systems, that can be accessible from the file manager on Chrome OS. * available since Chrome 40 * https://developer.chrome.com/extensions/fileSystemProvider
(get file-system-id)
Returns information about a file system with the passed fileSystemId.
|file-system-id| - https://developer.chrome.com/extensions/fileSystemProvider#property-get-fileSystemId.
This function returns a core.async channel of type promise-chan
which eventually receives a result value.
Signature of the result value put on the channel is [file-system] where:
|file-system| - https://developer.chrome.com/extensions/fileSystemProvider#property-callback-fileSystem.
In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.
https://developer.chrome.com/extensions/fileSystemProvider#method-get.
Returns information about a file system with the passed fileSystemId. |file-system-id| - https://developer.chrome.com/extensions/fileSystemProvider#property-get-fileSystemId. This function returns a core.async channel of type `promise-chan` which eventually receives a result value. Signature of the result value put on the channel is [file-system] where: |file-system| - https://developer.chrome.com/extensions/fileSystemProvider#property-callback-fileSystem. In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error. https://developer.chrome.com/extensions/fileSystemProvider#method-get.
(get-all)
Returns all file systems mounted by the extension.
This function returns a core.async channel of type promise-chan
which eventually receives a result value.
Signature of the result value put on the channel is [file-systems] where:
|file-systems| - https://developer.chrome.com/extensions/fileSystemProvider#property-callback-fileSystems.
In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.
https://developer.chrome.com/extensions/fileSystemProvider#method-getAll.
Returns all file systems mounted by the extension. This function returns a core.async channel of type `promise-chan` which eventually receives a result value. Signature of the result value put on the channel is [file-systems] where: |file-systems| - https://developer.chrome.com/extensions/fileSystemProvider#property-callback-fileSystems. In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error. https://developer.chrome.com/extensions/fileSystemProvider#method-getAll.
(mount options)
Mounts a file system with the given fileSystemId and displayName. displayName will be shown in the left panel of the Files app. displayName can contain any characters including '/', but cannot be an empty string. displayName must be descriptive but doesn't have to be unique. The fileSystemId must not be an empty string.Depending on the type of the file system being mounted, the source option must be set appropriately.In case of an error, 'runtime.lastError' will be set with a corresponding error code.
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-mount-options.
This function returns a core.async channel of type promise-chan
which eventually receives a result value.
Signature of the result value put on the channel is [].
In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.
https://developer.chrome.com/extensions/fileSystemProvider#method-mount.
Mounts a file system with the given fileSystemId and displayName. displayName will be shown in the left panel of the Files app. displayName can contain any characters including '/', but cannot be an empty string. displayName must be descriptive but doesn't have to be unique. The fileSystemId must not be an empty string.Depending on the type of the file system being mounted, the source option must be set appropriately.In case of an error, 'runtime.lastError' will be set with a corresponding error code. |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-mount-options. This function returns a core.async channel of type `promise-chan` which eventually receives a result value. Signature of the result value put on the channel is []. In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error. https://developer.chrome.com/extensions/fileSystemProvider#method-mount.
(notify options)
Notifies about changes in the watched directory at observedPath in recursive mode. If the file system is mounted with supportsNofityTag, then tag must be provided, and all changes since the last notification always reported, even if the system was shutdown. The last tag can be obtained with 'getAll'.To use, the file_system_provider.notify manifest option must be set to true.Value of tag can be any string which is unique per call, so it's possible to identify the last registered notification. Eg. if the providing extension starts after a reboot, and the last registered notification's tag is equal to '123', then it should call 'notify' for all changes which happened since the change tagged as '123'. It cannot be an empty string.Not all providers are able to provide a tag, but if the file system has a changelog, then the tag can be eg. a change number, or a revision number.Note that if a parent directory is removed, then all descendant entries are also removed, and if they are watched, then the API must be notified about the fact. Also, if a directory is renamed, then all descendant entries are in fact removed, as there is no entry under their original paths anymore.In case of an error, 'runtime.lastError' will be set will a corresponding error code.
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-notify-options.
This function returns a core.async channel of type promise-chan
which eventually receives a result value.
Signature of the result value put on the channel is [].
In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.
https://developer.chrome.com/extensions/fileSystemProvider#method-notify.
Notifies about changes in the watched directory at observedPath in recursive mode. If the file system is mounted with supportsNofityTag, then tag must be provided, and all changes since the last notification always reported, even if the system was shutdown. The last tag can be obtained with 'getAll'.To use, the file_system_provider.notify manifest option must be set to true.Value of tag can be any string which is unique per call, so it's possible to identify the last registered notification. Eg. if the providing extension starts after a reboot, and the last registered notification's tag is equal to '123', then it should call 'notify' for all changes which happened since the change tagged as '123'. It cannot be an empty string.Not all providers are able to provide a tag, but if the file system has a changelog, then the tag can be eg. a change number, or a revision number.Note that if a parent directory is removed, then all descendant entries are also removed, and if they are watched, then the API must be notified about the fact. Also, if a directory is renamed, then all descendant entries are in fact removed, as there is no entry under their original paths anymore.In case of an error, 'runtime.lastError' will be set will a corresponding error code. |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-notify-options. This function returns a core.async channel of type `promise-chan` which eventually receives a result value. Signature of the result value put on the channel is []. In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error. https://developer.chrome.com/extensions/fileSystemProvider#method-notify.
(tap-all-events chan)
Taps all valid non-deprecated events in chromex.ext.file-system-provider namespace.
Taps all valid non-deprecated events in chromex.ext.file-system-provider namespace.
(tap-on-abort-requested-events channel & args)
Raised when aborting an operation with operationRequestId is requested. The operation executed with operationRequestId must be immediately stopped and successCallback of this abort request executed. If aborting fails, then errorCallback must be called. Note, that callbacks of the aborted operation must not be called, as they will be ignored. Despite calling errorCallback, the request may be forcibly aborted.
Events will be put on the |channel| with signature [::on-abort-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onAbortRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onAbortRequested.
Raised when aborting an operation with operationRequestId is requested. The operation executed with operationRequestId must be immediately stopped and successCallback of this abort request executed. If aborting fails, then errorCallback must be called. Note, that callbacks of the aborted operation must not be called, as they will be ignored. Despite calling errorCallback, the request may be forcibly aborted. Events will be put on the |channel| with signature [::on-abort-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onAbortRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onAbortRequested.
(tap-on-add-watcher-requested-events channel & args)
Raised when setting a new directory watcher is requested. If an error occurs, then errorCallback must be called.
Events will be put on the |channel| with signature [::on-add-watcher-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onAddWatcherRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onAddWatcherRequested.
Raised when setting a new directory watcher is requested. If an error occurs, then errorCallback must be called. Events will be put on the |channel| with signature [::on-add-watcher-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onAddWatcherRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onAddWatcherRequested.
(tap-on-close-file-requested-events channel & args)
Raised when opening a file previously opened with openRequestId is requested to be closed.
Events will be put on the |channel| with signature [::on-close-file-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCloseFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onCloseFileRequested.
Raised when opening a file previously opened with openRequestId is requested to be closed. Events will be put on the |channel| with signature [::on-close-file-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCloseFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onCloseFileRequested.
(tap-on-configure-requested-events channel & args)
Raised when showing a configuration dialog for fileSystemId is requested. If it's handled, the file_system_provider.configurable manfiest option must be set to true.
Events will be put on the |channel| with signature [::on-configure-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onConfigureRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onConfigureRequested.
Raised when showing a configuration dialog for fileSystemId is requested. If it's handled, the file_system_provider.configurable manfiest option must be set to true. Events will be put on the |channel| with signature [::on-configure-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onConfigureRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onConfigureRequested.
(tap-on-copy-entry-requested-events channel & args)
Raised when copying an entry (recursively if a directory) is requested. If an error occurs, then errorCallback must be called.
Events will be put on the |channel| with signature [::on-copy-entry-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCopyEntryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onCopyEntryRequested.
Raised when copying an entry (recursively if a directory) is requested. If an error occurs, then errorCallback must be called. Events will be put on the |channel| with signature [::on-copy-entry-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCopyEntryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onCopyEntryRequested.
(tap-on-create-directory-requested-events channel & args)
Raised when creating a directory is requested. The operation must fail with the EXISTS error if the target directory already exists. If recursive is true, then all of the missing directories on the directory path must be created.
Events will be put on the |channel| with signature [::on-create-directory-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCreateDirectoryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onCreateDirectoryRequested.
Raised when creating a directory is requested. The operation must fail with the EXISTS error if the target directory already exists. If recursive is true, then all of the missing directories on the directory path must be created. Events will be put on the |channel| with signature [::on-create-directory-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCreateDirectoryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onCreateDirectoryRequested.
(tap-on-create-file-requested-events channel & args)
Raised when creating a file is requested. If the file already exists, then errorCallback must be called with the 'EXISTS' error code.
Events will be put on the |channel| with signature [::on-create-file-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCreateFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onCreateFileRequested.
Raised when creating a file is requested. If the file already exists, then errorCallback must be called with the 'EXISTS' error code. Events will be put on the |channel| with signature [::on-create-file-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onCreateFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onCreateFileRequested.
(tap-on-delete-entry-requested-events channel & args)
Raised when deleting an entry is requested. If recursive is true, and the entry is a directory, then all of the entries inside must be recursively deleted as well.
Events will be put on the |channel| with signature [::on-delete-entry-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onDeleteEntryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onDeleteEntryRequested.
Raised when deleting an entry is requested. If recursive is true, and the entry is a directory, then all of the entries inside must be recursively deleted as well. Events will be put on the |channel| with signature [::on-delete-entry-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onDeleteEntryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onDeleteEntryRequested.
(tap-on-execute-action-requested-events channel & args)
Raised when executing an action for a set of files or directories is\ requested. After the action is completed, successCallback must be called. On error, errorCallback must be called.
Events will be put on the |channel| with signature [::on-execute-action-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onExecuteActionRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onExecuteActionRequested.
Raised when executing an action for a set of files or directories is\ requested. After the action is completed, successCallback must be called. On error, errorCallback must be called. Events will be put on the |channel| with signature [::on-execute-action-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onExecuteActionRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onExecuteActionRequested.
(tap-on-get-actions-requested-events channel & args)
Raised when a list of actions for a set of files or directories at entryPaths is requested. All of the returned actions must be applicable to each entry. If there are no such actions, an empty array should be returned. The actions must be returned with the successCallback call. In case of an error, errorCallback must be called.
Events will be put on the |channel| with signature [::on-get-actions-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onGetActionsRequested-options. |success-callback| - Success callback for the 'onGetActionsRequested' event.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onGetActionsRequested.
Raised when a list of actions for a set of files or directories at entryPaths is requested. All of the returned actions must be applicable to each entry. If there are no such actions, an empty array should be returned. The actions must be returned with the successCallback call. In case of an error, errorCallback must be called. Events will be put on the |channel| with signature [::on-get-actions-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onGetActionsRequested-options. |success-callback| - Success callback for the 'onGetActionsRequested' event. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onGetActionsRequested.
(tap-on-get-metadata-requested-events channel & args)
Raised when metadata of a file or a directory at entryPath is requested. The metadata must be returned with the successCallback call. In case of an error, errorCallback must be called.
Events will be put on the |channel| with signature [::on-get-metadata-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onGetMetadataRequested-options. |success-callback| - Success callback for the 'onGetMetadataRequested' event.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onGetMetadataRequested.
Raised when metadata of a file or a directory at entryPath is requested. The metadata must be returned with the successCallback call. In case of an error, errorCallback must be called. Events will be put on the |channel| with signature [::on-get-metadata-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onGetMetadataRequested-options. |success-callback| - Success callback for the 'onGetMetadataRequested' event. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onGetMetadataRequested.
(tap-on-mount-requested-events channel & args)
Raised when showing a dialog for mounting a new file system is requested. If the extension/app is a file handler, then this event shouldn't be handled. Instead app.runtime.onLaunched should be handled in order to mount new file systems when a file is opened. For multiple mounts, the file_system_provider.multiple_mounts manifest option must be set to true.
Events will be put on the |channel| with signature [::on-mount-requested [success-callback error-callback]] where:
|success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onMountRequested.
Raised when showing a dialog for mounting a new file system is requested. If the extension/app is a file handler, then this event shouldn't be handled. Instead app.runtime.onLaunched should be handled in order to mount new file systems when a file is opened. For multiple mounts, the file_system_provider.multiple_mounts manifest option must be set to true. Events will be put on the |channel| with signature [::on-mount-requested [success-callback error-callback]] where: |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onMountRequested.
(tap-on-move-entry-requested-events channel & args)
Raised when moving an entry (recursively if a directory) is requested. If an error occurs, then errorCallback must be called.
Events will be put on the |channel| with signature [::on-move-entry-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onMoveEntryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onMoveEntryRequested.
Raised when moving an entry (recursively if a directory) is requested. If an error occurs, then errorCallback must be called. Events will be put on the |channel| with signature [::on-move-entry-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onMoveEntryRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onMoveEntryRequested.
(tap-on-open-file-requested-events channel & args)
Raised when opening a file at filePath is requested. If the file does not exist, then the operation must fail. Maximum number of files opened at once can be specified with MountOptions.
Events will be put on the |channel| with signature [::on-open-file-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onOpenFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onOpenFileRequested.
Raised when opening a file at filePath is requested. If the file does not exist, then the operation must fail. Maximum number of files opened at once can be specified with MountOptions. Events will be put on the |channel| with signature [::on-open-file-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onOpenFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onOpenFileRequested.
(tap-on-read-directory-requested-events channel & args)
Raised when contents of a directory at directoryPath are requested. The results must be returned in chunks by calling the successCallback several times. In case of an error, errorCallback must be called.
Events will be put on the |channel| with signature [::on-read-directory-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onReadDirectoryRequested-options. |success-callback| - Success callback for the 'onReadDirectoryRequested' event. If more entries will be returned, then hasMore must be true, and it has to be called again with additional entries. If no more entries are available, then hasMore must be set to false.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onReadDirectoryRequested.
Raised when contents of a directory at directoryPath are requested. The results must be returned in chunks by calling the successCallback several times. In case of an error, errorCallback must be called. Events will be put on the |channel| with signature [::on-read-directory-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onReadDirectoryRequested-options. |success-callback| - Success callback for the 'onReadDirectoryRequested' event. If more entries will be returned, then hasMore must be true, and it has to be called again with additional entries. If no more entries are available, then hasMore must be set to false. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onReadDirectoryRequested.
(tap-on-read-file-requested-events channel & args)
Raised when reading contents of a file opened previously with openRequestId is requested. The results must be returned in chunks by calling successCallback several times. In case of an error, errorCallback must be called.
Events will be put on the |channel| with signature [::on-read-file-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onReadFileRequested-options. |success-callback| - Success callback for the 'onReadFileRequested' event. If more data will be returned, then hasMore must be true, and it has to be called again with additional entries. If no more data is available, then hasMore must be set to false.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onReadFileRequested.
Raised when reading contents of a file opened previously with openRequestId is requested. The results must be returned in chunks by calling successCallback several times. In case of an error, errorCallback must be called. Events will be put on the |channel| with signature [::on-read-file-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onReadFileRequested-options. |success-callback| - Success callback for the 'onReadFileRequested' event. If more data will be returned, then hasMore must be true, and it has to be called again with additional entries. If no more data is available, then hasMore must be set to false. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onReadFileRequested.
(tap-on-remove-watcher-requested-events channel & args)
Raised when the watcher should be removed. If an error occurs, then errorCallback must be called.
Events will be put on the |channel| with signature [::on-remove-watcher-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onRemoveWatcherRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onRemoveWatcherRequested.
Raised when the watcher should be removed. If an error occurs, then errorCallback must be called. Events will be put on the |channel| with signature [::on-remove-watcher-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onRemoveWatcherRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onRemoveWatcherRequested.
(tap-on-truncate-requested-events channel & args)
Raised when truncating a file to a desired length is requested. If an error occurs, then errorCallback must be called.
Events will be put on the |channel| with signature [::on-truncate-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onTruncateRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onTruncateRequested.
Raised when truncating a file to a desired length is requested. If an error occurs, then errorCallback must be called. Events will be put on the |channel| with signature [::on-truncate-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onTruncateRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onTruncateRequested.
(tap-on-unmount-requested-events channel & args)
Raised when unmounting for the file system with the fileSystemId identifier is requested. In the response, the 'unmount' API method must be called together with successCallback. If unmounting is not possible (eg. due to a pending operation), then errorCallback must be called.
Events will be put on the |channel| with signature [::on-unmount-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onUnmountRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onUnmountRequested.
Raised when unmounting for the file system with the fileSystemId identifier is requested. In the response, the 'unmount' API method must be called together with successCallback. If unmounting is not possible (eg. due to a pending operation), then errorCallback must be called. Events will be put on the |channel| with signature [::on-unmount-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onUnmountRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onUnmountRequested.
(tap-on-write-file-requested-events channel & args)
Raised when writing contents to a file opened previously with openRequestId is requested.
Events will be put on the |channel| with signature [::on-write-file-requested [options success-callback error-callback]] where:
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onWriteFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success.
Note: |args| will be passed as additional parameters into Chrome event's .addListener call.
https://developer.chrome.com/extensions/fileSystemProvider#event-onWriteFileRequested.
Raised when writing contents to a file opened previously with openRequestId is requested. Events will be put on the |channel| with signature [::on-write-file-requested [options success-callback error-callback]] where: |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-onWriteFileRequested-options. |success-callback| - Callback to be called by the providing extension in case of a success. Note: |args| will be passed as additional parameters into Chrome event's .addListener call. https://developer.chrome.com/extensions/fileSystemProvider#event-onWriteFileRequested.
(unmount options)
Unmounts a file system with the given fileSystemId. It must be called after 'onUnmountRequested' is invoked. Also, the providing extension can decide to perform unmounting if not requested (eg. in case of lost connection, or a file error).In case of an error, 'runtime.lastError' will be set with a corresponding error code.
|options| - https://developer.chrome.com/extensions/fileSystemProvider#property-unmount-options.
This function returns a core.async channel of type promise-chan
which eventually receives a result value.
Signature of the result value put on the channel is [].
In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error.
https://developer.chrome.com/extensions/fileSystemProvider#method-unmount.
Unmounts a file system with the given fileSystemId. It must be called after 'onUnmountRequested' is invoked. Also, the providing extension can decide to perform unmounting if not requested (eg. in case of lost connection, or a file error).In case of an error, 'runtime.lastError' will be set with a corresponding error code. |options| - https://developer.chrome.com/extensions/fileSystemProvider#property-unmount-options. This function returns a core.async channel of type `promise-chan` which eventually receives a result value. Signature of the result value put on the channel is []. In case of an error the channel closes without receiving any value and relevant error object can be obtained via chromex.error/get-last-error. https://developer.chrome.com/extensions/fileSystemProvider#method-unmount.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close