MCPcopy Create free account
hub / github.com/docknetwork/crypto / new_with_right_offset

Method new_with_right_offset

utils/src/pairs.rs:62–70  ·  view source on GitHub ↗

Applies offset to the right slice, and then combines two slices together if they have equal length.

(
        left: &'left [Left],
        right: &'right [Right],
        right_offset: usize,
    )

Source from the content-addressed store, hash-verified

60
61 /// Applies offset to the right slice, and then combines two slices together if they have equal length.
62 pub fn new_with_right_offset(
63 left: &'left [Left],
64 right: &'right [Right],
65 right_offset: usize,
66 ) -> Option<Self> {
67 let right_with_offset = right.get(right_offset..)?;
68
69 Self::build_if_equal(left, right_with_offset)
70 }
71
72 /// Applies offsets to the both slices, and then combines them together if they have equal length.
73 pub fn new_with_left_and_right_offset(

Callers

nothing calls this directly

Calls 1

getMethod · 0.80

Tested by

no test coverage detected