FlatVector

Struct FlatVector 

Source
pub struct FlatVector { /* private fields */ }
Expand description

A flat vector

Implementations§

Source§

impl FlatVector

Source

pub fn capacity(&self) -> usize

Returns the capacity of the vector

Source

pub fn row_is_null(&self, row: u64) -> bool

Returns true if the row at the given index is null

Source

pub fn as_mut_ptr<T>(&self) -> *mut T

Returns an unsafe mutable pointer to the vector’s

Source

pub fn as_slice<T>(&self) -> &[T]

Returns a slice of the vector

Source

pub fn as_slice_with_len<T>(&self, len: usize) -> &[T]

Returns a slice of the vector up to a certain length

Source

pub fn as_mut_slice<T>(&mut self) -> &mut [T]

Returns a mutable slice of the vector

Source

pub fn as_mut_slice_with_len<T>(&mut self, len: usize) -> &mut [T]

Returns a mutable slice of the vector up to a certain length

Source

pub fn logical_type(&self) -> LogicalTypeHandle

Returns the logical type of the vector

Source

pub fn set_null(&mut self, row: usize)

Set row as null

Source

pub fn copy<T: Copy>(&mut self, data: &[T])

Copy data to the vector.

Trait Implementations§

Source§

impl From<*mut _duckdb_vector> for FlatVector

Source§

fn from(ptr: duckdb_vector) -> Self

Converts to this type from the input type.
Source§

impl Inserter<&[u8]> for FlatVector

Source§

fn insert(&self, index: usize, value: &[u8])

Insert a value into the vector.
Source§

impl Inserter<&str> for FlatVector

Source§

fn insert(&self, index: usize, value: &str)

Insert a value into the vector.
Source§

impl Inserter<CString> for FlatVector

Source§

fn insert(&self, index: usize, value: CString)

Insert a value into the vector.
Source§

impl Vector for FlatVector

Source§

fn as_any(&self) -> &dyn Any

Returns a reference to the underlying Any type that this trait object
Source§

fn as_mut_any(&mut self) -> &mut dyn Any

Returns a mutable reference to the underlying Any type that this trait object

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

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

Performs the conversion.