def has_prefix

mylsm-lsm-store@0.6.0.1 · src/scan/ByteRange.bend:127

import mylsm-lsm-store@0.6.0.1/src/scan/ByteRange.bend as ByteRange
import Base
import bend-kit-bytes@0.3.2.0/bytes.bend as Bytes

127# Checks whether a byte key begins with the exact byte prefix.
128def has_prefix(key: Bytes.Bytes, prefix: Bytes.Bytes) -> Bool:
129  prefix.lengths(Bytes.length(key), Bytes.length(prefix))

Uses (4)

Used by (2)