Struct parquet::data_type::ByteArray[][src]

pub struct ByteArray { /* fields omitted */ }
Expand description

Rust representation for BYTE_ARRAY and FIXED_LEN_BYTE_ARRAY Parquet physical types. Value is backed by a byte buffer.

Implementations

impl ByteArray[src]

pub fn new() -> Self[src]

Creates new byte array with no data set.

pub fn len(&self) -> usize[src]

Gets length of the underlying byte buffer.

pub fn is_empty(&self) -> bool[src]

Checks if the underlying buffer is empty.

pub fn data(&self) -> &[u8][src]

Returns slice of data.

pub fn set_data(&mut self, data: ByteBufferPtr)[src]

Set data from another byte buffer.

pub fn slice(&self, start: usize, len: usize) -> Self[src]

Returns ByteArray instance with slice of values for a data.

pub fn as_utf8(&self) -> Result<&str>[src]

Trait Implementations

impl AsBytes for ByteArray[src]

fn as_bytes(&self) -> &[u8][src]

Returns slice of bytes for this data type.

impl Clone for ByteArray[src]

fn clone(&self) -> ByteArray[src]

Returns a copy of the value. Read more

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for ByteArray[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl Default for ByteArray[src]

fn default() -> Self[src]

Returns the “default value” for a type. Read more

impl Display for ByteArray[src]

fn fmt(&self, f: &mut Formatter<'_>) -> Result[src]

Formats the value using the given formatter. Read more

impl<'a> From<&'a str> for ByteArray[src]

fn from(s: &'a str) -> ByteArray[src]

Performs the conversion.

impl From<Buffer<u8>> for ByteArray[src]

fn from(buf: ByteBuffer) -> ByteArray[src]

Performs the conversion.

impl From<BufferPtr<u8>> for ByteArray[src]

fn from(ptr: ByteBufferPtr) -> ByteArray[src]

Performs the conversion.

impl From<ByteArray> for FixedLenByteArray[src]

fn from(other: ByteArray) -> Self[src]

Performs the conversion.

impl From<FixedLenByteArray> for ByteArray[src]

fn from(other: FixedLenByteArray) -> Self[src]

Performs the conversion.

impl From<Vec<u8, Global>> for ByteArray[src]

fn from(buf: Vec<u8>) -> ByteArray[src]

Performs the conversion.

impl PartialEq<ByteArray> for ByteArray[src]

fn eq(&self, other: &ByteArray) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

impl PartialEq<ByteArray> for FixedLenByteArray[src]

fn eq(&self, other: &ByteArray) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

impl PartialEq<FixedLenByteArray> for ByteArray[src]

fn eq(&self, other: &FixedLenByteArray) -> bool[src]

This method tests for self and other values to be equal, and is used by ==. Read more

#[must_use]
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests for !=.

impl PartialOrd<ByteArray> for ByteArray[src]

fn partial_cmp(&self, other: &ByteArray) -> Option<Ordering>[src]

This method returns an ordering between self and other values if one exists. Read more

#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests less than (for self and other) and is used by the < operator. Read more

#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests greater than (for self and other) and is used by the > operator. Read more

#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl PartialOrd<ByteArray> for FixedLenByteArray[src]

fn partial_cmp(&self, other: &ByteArray) -> Option<Ordering>[src]

This method returns an ordering between self and other values if one exists. Read more

#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests less than (for self and other) and is used by the < operator. Read more

#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests greater than (for self and other) and is used by the > operator. Read more

#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl PartialOrd<FixedLenByteArray> for ByteArray[src]

fn partial_cmp(&self, other: &FixedLenByteArray) -> Option<Ordering>[src]

This method returns an ordering between self and other values if one exists. Read more

#[must_use]
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests less than (for self and other) and is used by the < operator. Read more

#[must_use]
fn le(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests less than or equal to (for self and other) and is used by the <= operator. Read more

#[must_use]
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests greater than (for self and other) and is used by the > operator. Read more

#[must_use]
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]

This method tests greater than or equal to (for self and other) and is used by the >= operator. Read more

impl SliceAsBytes for ByteArray[src]

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

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

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

Return the internal representation as a mutable slice Read more

Auto Trait Implementations

Blanket Implementations

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

pub fn type_id(&self) -> TypeId[src]

Gets the TypeId of self. Read more

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

pub fn borrow(&self) -> &T[src]

Immutably borrows from an owned value. Read more

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

pub fn borrow_mut(&mut self) -> &mut T[src]

Mutably borrows from an owned value. Read more

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

pub fn from(t: T) -> T[src]

Performs the conversion.

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

pub fn into(self) -> U[src]

Performs the conversion.

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

pub fn to_owned(&self) -> T[src]

Creates owned data from borrowed data, usually by cloning. Read more

pub fn clone_into(&self, target: &mut T)[src]

🔬 This is a nightly-only experimental API. (toowned_clone_into)

recently added

Uses borrowed data to replace owned data, usually by cloning. Read more

impl<T> ToString for T where
    T: Display + ?Sized
[src]

pub default fn to_string(&self) -> String[src]

Converts the given value to a String. Read more

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.

pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]

Performs the conversion.

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.

pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]

Performs the conversion.

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

pub fn vzip(self) -> V