MCPcopy Create free account
hub / github.com/denoland/std / decodeArray

Function decodeArray

msgpack/decode.ts:55–69  ·  view source on GitHub ↗
(
  uint8: Uint8Array,
  dataView: DataView,
  size: number,
  pointer: { consumed: number },
)

Source from the content-addressed store, hash-verified

53}
54
55function decodeArray(
56 uint8: Uint8Array,
57 dataView: DataView,
58 size: number,
59 pointer: { consumed: number },
60) {
61 const arr: ValueType[] = [];
62
63 for (let i = 0; i < size; i++) {
64 const value = decodeSlice(uint8, dataView, pointer);
65 arr.push(value);
66 }
67
68 return arr;
69}
70
71function decodeMap(
72 uint8: Uint8Array,

Callers 1

decodeSliceFunction · 0.85

Calls 2

decodeSliceFunction · 0.85
pushMethod · 0.45

Tested by

no test coverage detected