pub trait Batched: Sized + IntoExactSizeIterator<Item = Self::Item> {
type Item;
type Size: Positive;
// Provided method
fn batch_size() -> usize { ... }
}Expand description
A trait to define batching types that contain a compile-time known size of elements.
Required Associated Types§
Provided Methods§
Sourcefn batch_size() -> usize
fn batch_size() -> usize
Returns the size of the batch as a usize.
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.