fn kmers_from_bytes(str: &[u8]) -> Vec<Self> {
        let mut r = Vec::new();

        if str.len() < Self::k() {
            return r;
        }

        let mut k0 = Self::empty();

        for i in 0..Self::k() {
            k0.set_mut(i, str[i]);
        }

        r.push(k0.clone());

        for i in Self::k()..str.len() {
            k0 = k0.extend_right(str[i]);
            r.push(k0.clone());
        }

        r
    }
/// Generate vector of all kmers contained in `str` encoded as 0-4.
Generate vector of all kmers contained in `str` encoded as 0-4.
Generate vector of all kmers contained in ` str ` encoded as 0 - 4 .
fn kmers_from_bytes(str: &[u8]) -> Vec<Self> {
        let mut r = Vec::new();
        if str.len() < Self::k() {
            return r;
        }
        let mut k0 = Self::empty();
        for i in 0..Self::k() {
            k0.set_mut(i, str[i]);
        }
        r.push(k0.clone());
        for i in Self::k()..str.len() {
            k0 = k0.extend_right(str[i]);
            r.push(k0.clone());
        }
        r
    }
fn kmers_from_bytes ( str : & [ u8 ] ) -> Vec < Self > { let mut r = Vec :: new ( ) ; if str . len ( ) < Self :: k ( ) { return r ; } let mut k0 = Self :: empty ( ) ; for i in 0 .. Self :: k ( ) { k0 . set_mut ( i , str [ i ] ) ; } r . push ( k0 . clone ( ) ) ; for i in Self :: k ( ) .. str . len ( ) { k0 = k0 . extend_right ( str [ i ] ) ; r . push ( k0 . clone ( ) ) ; } r }
Generate vector of all kmers contained in `str` encoded as 0-4.
Generate vector of all kmers contained in ` str ` encoded as 0 - 4 .
str
&[u8]
str
&[u8]