pub trait AsAlignedChunks<A: Alignment, M: ArrayLength<u8> + PartialDiv<A::Num>> {
// Required methods
fn as_aligned_chunks(&self) -> &[Aligned<A, GenericArray<u8, M>>];
fn as_mut_aligned_chunks(
&mut self,
) -> &mut [Aligned<A, GenericArray<u8, M>>];
}
Expand description
Trait for types which can be viewed as aligned chunks of bytes This should generally just be, larger chunks of dumb bytes or similar.
Required Methods§
Sourcefn as_aligned_chunks(&self) -> &[Aligned<A, GenericArray<u8, M>>]
fn as_aligned_chunks(&self) -> &[Aligned<A, GenericArray<u8, M>>]
Break self into aligned chunks of size M. This is not required to cover all the bytes of Self, trailing bytes that don’t fit may be left off.
Sourcefn as_mut_aligned_chunks(&mut self) -> &mut [Aligned<A, GenericArray<u8, M>>]
fn as_mut_aligned_chunks(&mut self) -> &mut [Aligned<A, GenericArray<u8, M>>]
Break self into mutable aligned chunks of size M. This is not required to cover all the bytes of Self, but must agree with as_aligned_chunks.