(this: This<Class<'js, Self>>, ctx: Ctx<'js>, size: Opt<usize>)
| 171 | } |
| 172 | |
| 173 | fn read(this: This<Class<'js, Self>>, ctx: Ctx<'js>, size: Opt<usize>) -> Result<Value<'js>> { |
| 174 | if let Some(data) = this.borrow().inner().buffer.read(size.0) { |
| 175 | return Buffer(data).into_js(&ctx); |
| 176 | } |
| 177 | |
| 178 | Ok(Null.into_value(ctx)) |
| 179 | } |
| 180 | |
| 181 | fn drain(this: Class<'js, Self>, ctx: &Ctx<'js>) -> Result<()> { |
| 182 | let this2 = this.clone(); |
nothing calls this directly
no test coverage detected