MCPcopy Create free account
hub / github.com/awslabs/llrt / array_buffer_ref

Method array_buffer_ref

modules/llrt_buffer/src/blob.rs:211–213  ·  view source on GitHub ↗

Zero-copy access to the underlying `ArrayBuffer`. Cloning the handle is cheap (it's a JS-refcount bump); no bytes are copied. Useful for consumers that want to pass the Blob body on to hyper via `ObjectBytes::DataView` without the `get_bytes()` allocation.

(&self)

Source from the content-addressed store, hash-verified

209 };
210 let data = shared_array_buffer_view(ctx, &self.data, start, end.saturating_sub(start))?;
211 let mime_type = get_coerced_defined_string(&content_type);
212 let mime_type = mime_type.map(normalize_type).unwrap_or_default();
213 Ok(Blob { mime_type, data })
214 }
215}
216

Callers 1

get_fetch_optionsFunction · 0.80

Calls 1

cloneMethod · 0.45

Tested by

no test coverage detected