utf16_iter

Trait Utf16CharsEx

Source
pub trait Utf16CharsEx {
    // Required methods
    fn chars(&self) -> Utf16Chars<'_> ;
    fn char_indices(&self) -> Utf16CharIndices<'_> ;
}
Expand description

Convenience trait that adds chars() and char_indices() methods similar to the ones on string slices to u16 slices.

Required Methods§

Implementations on Foreign Types§

Source§

impl Utf16CharsEx for [u16]

Source§

fn chars(&self) -> Utf16Chars<'_>

Convenience method for creating an UTF-16 iterator for the slice.

Source§

fn char_indices(&self) -> Utf16CharIndices<'_>

Convenience method for creating a code unit index and UTF-16 iterator for the slice.

Implementors§