pub trait IterParams {
type Input;
type Output;
// Required methods
fn bits() -> usize;
fn buffer() -> usize;
fn shift() -> usize;
fn to_byte(input: Self::Input) -> u8;
fn to_output(bits: u8) -> Self::Output;
// Provided methods
fn post_shift() -> usize { ... }
fn iterations() -> usize { ... }
fn validate() { ... }
}
Required Associated Types§
Required Methods§
Provided Methods§
Sourcefn post_shift() -> usize
fn post_shift() -> usize
Amount to shift buffer after all buffering, so the bits are lined up at the MSB.
Sourcefn iterations() -> usize
fn iterations() -> usize
Number of iterations before buffering.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.