Skip to main content

SetIvState

Trait SetIvState 

Source
pub trait SetIvState: IvState {
    // Required method
    fn set_iv(&mut self, iv: &Iv<Self>);

    // Provided method
    fn peek<T>(&mut self, f: impl FnOnce(&mut Self) -> T) -> T { ... }
}
Expand description

Trait for setting current IV state.

Required Methods§

Source

fn set_iv(&mut self, iv: &Iv<Self>)

Set IV.

Provided Methods§

Source

fn peek<T>(&mut self, f: impl FnOnce(&mut Self) -> T) -> T

Execute the f closure with the current state and reset it back to the original state before the method returns.

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.

Implementors§