MCPcopy Create free account
hub / github.com/base/base / encode_frames

Function encode_frames

crates/consensus/derive/src/test_utils/frames.rs:24–31  ·  view source on GitHub ↗
(frames: &[Frame])

Source from the content-addressed store, hash-verified

22}
23
24fn encode_frames(frames: &[Frame]) -> Bytes {
25 let mut bytes = Vec::new();
26 bytes.extend_from_slice(&[DERIVATION_VERSION_0]);
27 for frame in frames {
28 bytes.extend_from_slice(&frame.encode());
29 }
30 Bytes::from(bytes)
31}
32
33impl FrameQueueBuilder {
34 /// Create a new [`FrameQueueBuilder`] instance.

Callers 1

with_framesMethod · 0.85

Calls 2

newFunction · 0.50
encodeMethod · 0.45

Tested by

no test coverage detected