parquet::data_type

Trait SliceAsBytes

Source
pub trait SliceAsBytes: Sized {
    // Required methods
    fn slice_as_bytes(self_: &[Self]) -> &[u8] ;
    unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8] ;
}
Expand description

Converts an slice of a data type to a slice of bytes.

Required Methods§

Source

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Returns slice of bytes for a slice of this data type.

Source

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Return the internal representation as a mutable slice

§Safety

If modified you are required to ensure the internal representation is valid and correct for the actual raw data

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.

Implementations on Foreign Types§

Source§

impl SliceAsBytes for bool

Source§

fn slice_as_bytes(_self: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(_self: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for f32

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for f64

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for i8

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for i16

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for i32

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for i64

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for u8

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for u16

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for u32

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Source§

impl SliceAsBytes for u64

Source§

fn slice_as_bytes(self_: &[Self]) -> &[u8]

Source§

unsafe fn slice_as_bytes_mut(self_: &mut [Self]) -> &mut [u8]

Implementors§