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

Method new

modules/llrt_buffer/src/buffer.rs:28–35  ·  view source on GitHub ↗
(ctx: &Ctx<'js>)

Source from the content-addressed store, hash-verified

26
27impl<'js> Primordial<'js> for BufferPrimordials<'js> {
28 fn new(ctx: &Ctx<'js>) -> Result<Self>
29 where
30 Self: Sized,
31 {
32 let constructor: Constructor = ctx.globals().get(stringify!(Buffer))?;
33
34 Ok(Self { constructor })
35 }
36}
37
38pub struct Buffer(pub Vec<u8>);

Callers

nothing calls this directly

Calls 1

getMethod · 0.45

Tested by

no test coverage detected