Skip to main content

Nullable

Struct Nullable 

Source
pub struct Nullable<T>(/* private fields */);
Expand description

Wraps a base SQL type as nullable. A distinct outer shape from any base type, so it can have its own WrapNullable<MaybeNull> impl without overlapping the per-base-type impls below.

Trait Implementations§

Source§

impl AssignsTo<Nullable<BigInt>> for Integer

Source§

impl AssignsTo<Nullable<BigInt>> for Nullable<Integer>

Source§

impl AssignsTo<Nullable<Numeric>> for Integer

Source§

impl AssignsTo<Nullable<Numeric>> for Nullable<Integer>

Source§

impl AssignsTo<Nullable<Numeric>> for BigInt

Source§

impl AssignsTo<Nullable<Numeric>> for Nullable<BigInt>

Source§

impl AssignsTo<Nullable<Numeric>> for Real

Source§

impl AssignsTo<Nullable<Numeric>> for Nullable<Real>

Source§

impl AssignsTo<Nullable<Real>> for Integer

Source§

impl AssignsTo<Nullable<Real>> for Nullable<Integer>

Source§

impl AssignsTo<Nullable<Real>> for BigInt

Source§

impl AssignsTo<Nullable<Real>> for Nullable<BigInt>

Source§

impl BoolLike for Nullable<Bool>

Source§

impl Comparable<BigInt> for Nullable<Integer>

Source§

impl Comparable<BigInt> for Nullable<Real>

Source§

impl Comparable<BigInt> for Nullable<Numeric>

Source§

impl Comparable<Integer> for Nullable<BigInt>

Source§

impl Comparable<Integer> for Nullable<Real>

Source§

impl Comparable<Integer> for Nullable<Numeric>

Source§

impl Comparable<Nullable<BigInt>> for Integer

Source§

impl Comparable<Nullable<BigInt>> for Nullable<Integer>

Source§

impl Comparable<Nullable<BigInt>> for Real

Source§

impl Comparable<Nullable<BigInt>> for Nullable<Real>

Source§

impl Comparable<Nullable<BigInt>> for Numeric

Source§

impl Comparable<Nullable<BigInt>> for Nullable<Numeric>

Source§

impl Comparable<Nullable<Integer>> for BigInt

Source§

impl Comparable<Nullable<Integer>> for Nullable<BigInt>

Source§

impl Comparable<Nullable<Integer>> for Real

Source§

impl Comparable<Nullable<Integer>> for Nullable<Real>

Source§

impl Comparable<Nullable<Integer>> for Numeric

Source§

impl Comparable<Nullable<Integer>> for Nullable<Numeric>

Source§

impl Comparable<Nullable<Numeric>> for Integer

Source§

impl Comparable<Nullable<Numeric>> for Nullable<Integer>

Source§

impl Comparable<Nullable<Numeric>> for BigInt

Source§

impl Comparable<Nullable<Numeric>> for Nullable<BigInt>

Source§

impl Comparable<Nullable<Numeric>> for Real

Source§

impl Comparable<Nullable<Numeric>> for Nullable<Real>

Source§

impl Comparable<Nullable<Real>> for Integer

Source§

impl Comparable<Nullable<Real>> for Nullable<Integer>

Source§

impl Comparable<Nullable<Real>> for BigInt

Source§

impl Comparable<Nullable<Real>> for Nullable<BigInt>

Source§

impl Comparable<Nullable<Real>> for Numeric

Source§

impl Comparable<Nullable<Real>> for Nullable<Numeric>

Source§

impl Comparable<Numeric> for Nullable<Integer>

Source§

impl Comparable<Numeric> for Nullable<BigInt>

Source§

impl Comparable<Numeric> for Nullable<Real>

Source§

impl Comparable<Real> for Nullable<Integer>

Source§

impl Comparable<Real> for Nullable<BigInt>

Source§

impl Comparable<Real> for Nullable<Numeric>

Source§

impl<T: SqlType> Comparable<T> for Nullable<T>

Source§

impl<S: Ordered> Ordered for Nullable<S>

A nullable column orders like its base type — the NULLs sort, they don’t stop the aggregate from existing.

Source§

impl<S: SqlType> SqlType for Nullable<S>

Source§

impl<T: Summable> Summable for Nullable<T>

Source§

const SUM_CAST: Option<CastTarget> = T::SUM_CAST

Source§

const AVG_CAST: Option<CastTarget> = T::AVG_CAST

Source§

type Sum = <T as Summable>::Sum

Source§

impl TextLike for Nullable<Text>

Source§

impl<T> WrapNullable<MaybeNull> for Nullable<T>

Auto Trait Implementations§

§

impl<T> Freeze for Nullable<T>
where PhantomData<T>: Freeze,

§

impl<T> RefUnwindSafe for Nullable<T>

§

impl<T> Send for Nullable<T>
where PhantomData<T>: Send,

§

impl<T> Sync for Nullable<T>
where PhantomData<T>: Sync,

§

impl<T> Unpin for Nullable<T>
where PhantomData<T>: Unpin,

§

impl<T> UnsafeUnpin for Nullable<T>

§

impl<T> UnwindSafe for Nullable<T>

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> AssignsTo<Nullable<T>> for T
where T: SqlType,

Source§

impl<T> AssignsTo<T> for T
where T: SqlType,

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> Comparable<Nullable<T>> for T
where T: SqlType,

Source§

impl<T> Comparable<T> for T
where T: SqlType,

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<S> Superset<Nil, Nil> for S

Source§

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

Source§

type Error = !

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

fn try_from(value: U) -> Result<T, !>

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.
Source§

impl<T> WrapNullable<NotNull> for T