IvSize

Trait IvSize 

Source
pub trait IvSize: Sealed {
    // Required method
    fn size() -> usize;

    // Provided method
    fn size_32() -> u32 { ... }
}
Expand description

A trait for types that represent initialization vector (IV) sizes.

This trait is sealed and can only be implemented within this crate.

Required Methods§

Source

fn size() -> usize

Returns the size of the IV in bytes.

Provided Methods§

Source

fn size_32() -> u32

Returns the size of the IV as a u32.

§Panics

In debug builds, this method will panic if the size is greater than u32::MAX.

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§