Struct arrow::array::FixedSizeBinaryArray[][src]

pub struct FixedSizeBinaryArray { /* fields omitted */ }

A type of FixedSizeListArray whose elements are binaries.

Implementations

impl FixedSizeBinaryArray[src]

pub fn value(&self, i: usize) -> &[u8]

Notable traits for &'_ [u8]

impl<'_> Read for &'_ [u8]impl<'_> Write for &'_ mut [u8]
[src]

Returns the element at index i as a byte slice.

pub fn value_offset(&self, i: usize) -> i32[src]

Returns the offset for the element at index i.

Note this doesn’t do any bound checking, for performance reason.

pub fn value_length(&self) -> i32[src]

Returns the length for an element.

All elements have the same length as the array is a fixed size.

pub fn value_data(&self) -> Buffer[src]

Returns a clone of the value data buffer

pub fn try_from_sparse_iter<T, U>(iter: T) -> Result<Self, ArrowError> where
    T: Iterator<Item = Option<U>>,
    U: AsRef<[u8]>, 
[src]

Create an array from an iterable argument of sparse byte slices. Sparsity means that items returned by the iterator are optional, i.e input argument can contain None items.

Examles

use arrow::array::FixedSizeBinaryArray;
let input_arg = vec![
    None,
    Some(vec![7, 8]),
    Some(vec![9, 10]),
    None,
    Some(vec![13, 14]),
    None,
];
let array = FixedSizeBinaryArray::try_from_sparse_iter(input_arg.into_iter()).unwrap();

Errors

Returns error if argument has length zero, or sizes of nested slices don’t match.

pub fn try_from_iter<T, U>(iter: T) -> Result<Self, ArrowError> where
    T: Iterator<Item = U>,
    U: AsRef<[u8]>, 
[src]

Create an array from an iterable argument of byte slices.

Examles

use arrow::array::FixedSizeBinaryArray;
let input_arg = vec![
    vec![1, 2],
    vec![3, 4],
    vec![5, 6],
];
let array = FixedSizeBinaryArray::try_from_iter(input_arg.into_iter()).unwrap();

Errors

Returns error if argument has length zero, or sizes of nested slices don’t match.

Trait Implementations

impl Array for FixedSizeBinaryArray[src]

fn get_buffer_memory_size(&self) -> usize[src]

Returns the total number of bytes of memory occupied by the buffers owned by this FixedSizeBinaryArray.

fn get_array_memory_size(&self) -> usize[src]

Returns the total number of bytes of memory occupied physically by this FixedSizeBinaryArray.

impl Debug for FixedSizeBinaryArray[src]

impl From<ArrayData> for FixedSizeBinaryArray[src]

impl From<FixedSizeListArray> for FixedSizeBinaryArray[src]

Creates a FixedSizeBinaryArray from FixedSizeList<u8> array

impl JsonEqual for FixedSizeBinaryArray[src]

impl PartialEq<FixedSizeBinaryArray> for FixedSizeBinaryArray[src]

impl PartialEq<Value> for FixedSizeBinaryArray[src]

Auto Trait Implementations

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,