Enum duckdb::types::ToSqlOutput

source ·
#[non_exhaustive]
pub enum ToSqlOutput<'a> { Borrowed(ValueRef<'a>), Owned(Value), }
Expand description

ToSqlOutput represents the possible output types for implementers of the ToSql trait.

Variants (Non-exhaustive)§

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
§

Borrowed(ValueRef<'a>)

A borrowed SQLite-representable value.

§

Owned(Value)

An owned SQLite-representable value.

Trait Implementations§

source§

impl<'a> Clone for ToSqlOutput<'a>

source§

fn clone(&self) -> ToSqlOutput<'a>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<'a> Debug for ToSqlOutput<'a>

source§

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

Formats the value using the given formatter. Read more
source§

impl<'a, T: ?Sized> From<&'a T> for ToSqlOutput<'a>
where &'a T: Into<ValueRef<'a>>,

source§

fn from(t: &'a T) -> Self

Converts to this type from the input type.
source§

impl From<Null> for ToSqlOutput<'_>

source§

fn from(t: Null) -> Self

Converts to this type from the input type.
source§

impl From<String> for ToSqlOutput<'_>

source§

fn from(t: String) -> Self

Converts to this type from the input type.
source§

impl From<Vec<u8>> for ToSqlOutput<'_>

source§

fn from(t: Vec<u8>) -> Self

Converts to this type from the input type.
source§

impl From<bool> for ToSqlOutput<'_>

source§

fn from(t: bool) -> Self

Converts to this type from the input type.
source§

impl From<f32> for ToSqlOutput<'_>

source§

fn from(t: f32) -> Self

Converts to this type from the input type.
source§

impl From<f64> for ToSqlOutput<'_>

source§

fn from(t: f64) -> Self

Converts to this type from the input type.
source§

impl From<i128> for ToSqlOutput<'_>

source§

fn from(t: i128) -> Self

Converts to this type from the input type.
source§

impl From<i16> for ToSqlOutput<'_>

source§

fn from(t: i16) -> Self

Converts to this type from the input type.
source§

impl From<i32> for ToSqlOutput<'_>

source§

fn from(t: i32) -> Self

Converts to this type from the input type.
source§

impl From<i64> for ToSqlOutput<'_>

source§

fn from(t: i64) -> Self

Converts to this type from the input type.
source§

impl From<i8> for ToSqlOutput<'_>

source§

fn from(t: i8) -> Self

Converts to this type from the input type.
source§

impl From<isize> for ToSqlOutput<'_>

source§

fn from(t: isize) -> Self

Converts to this type from the input type.
source§

impl From<u16> for ToSqlOutput<'_>

source§

fn from(t: u16) -> Self

Converts to this type from the input type.
source§

impl From<u32> for ToSqlOutput<'_>

source§

fn from(t: u32) -> Self

Converts to this type from the input type.
source§

impl From<u64> for ToSqlOutput<'_>

source§

fn from(t: u64) -> Self

Converts to this type from the input type.
source§

impl From<u8> for ToSqlOutput<'_>

source§

fn from(t: u8) -> Self

Converts to this type from the input type.
source§

impl From<usize> for ToSqlOutput<'_>

source§

fn from(t: usize) -> Self

Converts to this type from the input type.
source§

impl<'a> PartialEq for ToSqlOutput<'a>

source§

fn eq(&self, other: &ToSqlOutput<'a>) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl ToSql for ToSqlOutput<'_>

source§

fn to_sql(&self) -> Result<ToSqlOutput<'_>>

Converts Rust value to DuckDB value
source§

impl<'a> StructuralPartialEq for ToSqlOutput<'a>

Auto Trait Implementations§

§

impl<'a> Freeze for ToSqlOutput<'a>

§

impl<'a> !RefUnwindSafe for ToSqlOutput<'a>

§

impl<'a> Send for ToSqlOutput<'a>

§

impl<'a> Sync for ToSqlOutput<'a>

§

impl<'a> Unpin for ToSqlOutput<'a>

§

impl<'a> !UnwindSafe for ToSqlOutput<'a>

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> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

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

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

§

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>,

§

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.