(&self, ctx: &Ctx<'_>, data: &[u8])
| 17 | |
| 18 | impl StringDecoder { |
| 19 | fn make_string(&self, ctx: &Ctx<'_>, data: &[u8]) -> Result<String> { |
| 20 | self.encoder |
| 21 | .encode_to_string(data, true) |
| 22 | .map_err(|_| Exception::throw_internal(ctx, "Encoding error")) |
| 23 | } |
| 24 | |
| 25 | /// Try to decode the given buffer and store the incomplete bytes. |
| 26 | /// The logic was adapted from the [Node implementation]. |
no test coverage detected