pub type FieldSlice<'a, P> = FieldBuffer<P, FieldSliceData<'a, P>>;Expand description
Alias for a field buffer over a borrowed slice.
Aliased Type§
pub struct FieldSlice<'a, P> { /* private fields */ }Implementations§
Source§impl<'a, P: PackedField> FieldSlice<'a, P>
impl<'a, P: PackedField> FieldSlice<'a, P>
Sourcepub fn from_slice(log_len: usize, slice: &'a [P]) -> Self
pub fn from_slice(log_len: usize, slice: &'a [P]) -> Self
Create a new FieldSlice from a slice of packed values.
§Preconditions
slice.len()must equal the expected packed length forlog_len.
Trait Implementations§
Source§impl<'a, P: PackedField, Data: Deref<Target = [P]>> From<&'a FieldBuffer<P, Data>> for FieldSlice<'a, P>
impl<'a, P: PackedField, Data: Deref<Target = [P]>> From<&'a FieldBuffer<P, Data>> for FieldSlice<'a, P>
Source§fn from(buffer: &'a FieldBuffer<P, Data>) -> Self
fn from(buffer: &'a FieldBuffer<P, Data>) -> Self
Converts to this type from the input type.