Struct fst::raw::Stream
[−]
[src]
pub struct Stream<'f, A = AlwaysMatch> where A: Automaton {
// some fields omitted
}
A lexicographically ordered stream of key-value pairs from an fst.
The A
type parameter corresponds to an optional automaton to filter
the stream. By default, no filtering is done.
The 'f
lifetime parameter refers to the lifetime of the underlying fst.
Methods
impl<'f, A: Automaton> Stream<'f, A>
[src]
fn into_byte_vec(self) -> Vec<(Vec<u8>, u64)>
Convert this stream into a vector of byte strings and outputs.
Note that this creates a new allocation for every key in the stream.
fn into_str_vec(self) -> Result<Vec<(String, u64)>>
Convert this stream into a vector of Unicode strings and outputs.
If any key is not valid UTF-8, then iteration on the stream is stopped and a UTF-8 decoding error is returned.
Note that this creates a new allocation for every key in the stream.
fn into_byte_keys(self) -> Vec<Vec<u8>>
Convert this stream into a vector of byte strings.
Note that this creates a new allocation for every key in the stream.
fn into_str_keys(self) -> Result<Vec<String>>
Convert this stream into a vector of Unicode strings.
If any key is not valid UTF-8, then iteration on the stream is stopped and a UTF-8 decoding error is returned.
Note that this creates a new allocation for every key in the stream.
fn into_values(self) -> Vec<u64>
Convert this stream into a vector of outputs.