1#![allow(unused_imports)]
2#![allow(clippy::all)]
3use super::*;
4use wasm_bindgen::prelude::*;
5#[wasm_bindgen]
6extern "C" {
7 # [wasm_bindgen (extends = :: js_sys :: Object , js_name = ReadableStreamBYOBRequest , typescript_type = "ReadableStreamBYOBRequest")]
8 #[derive(Debug, Clone, PartialEq, Eq)]
9 #[doc = "The `ReadableStreamByobRequest` class."]
10 #[doc = ""]
11 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStreamBYOBRequest)"]
12 #[doc = ""]
13 #[doc = "*This API requires the following crate features to be activated: `ReadableStreamByobRequest`*"]
14 pub type ReadableStreamByobRequest;
15 # [wasm_bindgen (structural , method , getter , js_class = "ReadableStreamBYOBRequest" , js_name = view)]
16 #[doc = "Getter for the `view` field of this object."]
17 #[doc = ""]
18 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStreamBYOBRequest/view)"]
19 #[doc = ""]
20 #[doc = "*This API requires the following crate features to be activated: `ReadableStreamByobRequest`*"]
21 pub fn view(this: &ReadableStreamByobRequest) -> Option<::js_sys::Object>;
22 # [wasm_bindgen (catch , method , structural , js_class = "ReadableStreamBYOBRequest" , js_name = respond)]
23 #[doc = "The `respond()` method."]
24 #[doc = ""]
25 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStreamBYOBRequest/respond)"]
26 #[doc = ""]
27 #[doc = "*This API requires the following crate features to be activated: `ReadableStreamByobRequest`*"]
28 pub fn respond_with_u32(
29 this: &ReadableStreamByobRequest,
30 bytes_written: u32,
31 ) -> Result<(), JsValue>;
32 # [wasm_bindgen (catch , method , structural , js_class = "ReadableStreamBYOBRequest" , js_name = respond)]
33 #[doc = "The `respond()` method."]
34 #[doc = ""]
35 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStreamBYOBRequest/respond)"]
36 #[doc = ""]
37 #[doc = "*This API requires the following crate features to be activated: `ReadableStreamByobRequest`*"]
38 pub fn respond_with_f64(
39 this: &ReadableStreamByobRequest,
40 bytes_written: f64,
41 ) -> Result<(), JsValue>;
42 # [wasm_bindgen (catch , method , structural , js_class = "ReadableStreamBYOBRequest" , js_name = respondWithNewView)]
43 #[doc = "The `respondWithNewView()` method."]
44 #[doc = ""]
45 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStreamBYOBRequest/respondWithNewView)"]
46 #[doc = ""]
47 #[doc = "*This API requires the following crate features to be activated: `ReadableStreamByobRequest`*"]
48 pub fn respond_with_new_view_with_array_buffer_view(
49 this: &ReadableStreamByobRequest,
50 view: &::js_sys::Object,
51 ) -> Result<(), JsValue>;
52 # [wasm_bindgen (catch , method , structural , js_class = "ReadableStreamBYOBRequest" , js_name = respondWithNewView)]
53 #[doc = "The `respondWithNewView()` method."]
54 #[doc = ""]
55 #[doc = "[MDN Documentation](https://developer.mozilla.org/en-US/docs/Web/API/ReadableStreamBYOBRequest/respondWithNewView)"]
56 #[doc = ""]
57 #[doc = "*This API requires the following crate features to be activated: `ReadableStreamByobRequest`*"]
58 pub fn respond_with_new_view_with_u8_array(
59 this: &ReadableStreamByobRequest,
60 view: &mut [u8],
61 ) -> Result<(), JsValue>;
62}
63