Skip to main content

web_sys/features/
gen_FileSystemFileHandle.rs

1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7    # [wasm_bindgen (extends = FileSystemHandle , extends = :: js_sys :: Object , js_name = FileSystemFileHandle , typescript_type = "FileSystemFileHandle")]
8    #[derive(Debug, Clone, PartialEq, Eq)]
9    #[doc = "The `FileSystemFileHandle` class."]
10    #[doc = ""]
11    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle)"]
12    #[doc = ""]
13    #[doc = "*This API requires the following crate features to be activated: `FileSystemFileHandle`*"]
14    pub type FileSystemFileHandle;
15    # [wasm_bindgen (method , structural , js_class = "FileSystemFileHandle" , js_name = createSyncAccessHandle)]
16    #[doc = "The `createSyncAccessHandle()` method."]
17    #[doc = ""]
18    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle/createSyncAccessHandle)"]
19    #[doc = ""]
20    #[doc = "*This API requires the following crate features to be activated: `FileSystemFileHandle`*"]
21    pub fn create_sync_access_handle(this: &FileSystemFileHandle) -> ::js_sys::Promise;
22    #[cfg(web_sys_unstable_apis)]
23    #[cfg(all(
24        feature = "FileSystemSyncAccessHandle",
25        feature = "FileSystemSyncAccessHandleOptions",
26    ))]
27    # [wasm_bindgen (method , structural , js_class = "FileSystemFileHandle" , js_name = createSyncAccessHandle)]
28    #[doc = "The `createSyncAccessHandle()` method."]
29    #[doc = ""]
30    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle/createSyncAccessHandle)"]
31    #[doc = ""]
32    #[doc = "*This API requires the following crate features to be activated: `FileSystemFileHandle`, `FileSystemSyncAccessHandle`, `FileSystemSyncAccessHandleOptions`*"]
33    #[doc = ""]
34    #[doc = "*This API is unstable and requires `--cfg=web_sys_unstable_apis` to be activated, as"]
35    #[doc = "[described in the `wasm-bindgen` guide](https://wasm-bindgen.github.io/wasm-bindgen/web-sys/unstable-apis.html)*"]
36    pub fn create_sync_access_handle_with_options(
37        this: &FileSystemFileHandle,
38        options: &FileSystemSyncAccessHandleOptions,
39    ) -> ::js_sys::Promise<FileSystemSyncAccessHandle>;
40    # [wasm_bindgen (method , structural , js_class = "FileSystemFileHandle" , js_name = createWritable)]
41    #[doc = "The `createWritable()` method."]
42    #[doc = ""]
43    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle/createWritable)"]
44    #[doc = ""]
45    #[doc = "*This API requires the following crate features to be activated: `FileSystemFileHandle`*"]
46    pub fn create_writable(this: &FileSystemFileHandle) -> ::js_sys::Promise;
47    #[cfg(feature = "FileSystemCreateWritableOptions")]
48    # [wasm_bindgen (method , structural , js_class = "FileSystemFileHandle" , js_name = createWritable)]
49    #[doc = "The `createWritable()` method."]
50    #[doc = ""]
51    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle/createWritable)"]
52    #[doc = ""]
53    #[doc = "*This API requires the following crate features to be activated: `FileSystemCreateWritableOptions`, `FileSystemFileHandle`*"]
54    pub fn create_writable_with_options(
55        this: &FileSystemFileHandle,
56        options: &FileSystemCreateWritableOptions,
57    ) -> ::js_sys::Promise;
58    # [wasm_bindgen (method , structural , js_class = "FileSystemFileHandle" , js_name = getFile)]
59    #[doc = "The `getFile()` method."]
60    #[doc = ""]
61    #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/FileSystemFileHandle/getFile)"]
62    #[doc = ""]
63    #[doc = "*This API requires the following crate features to be activated: `FileSystemFileHandle`*"]
64    pub fn get_file(this: &FileSystemFileHandle) -> ::js_sys::Promise;
65}