pub struct NotNull;
Expand description
No, this type cannot be null as it is marked as NOT NULL
at database level
This should be choosen for basically all manual impls of SqlType
beside implementing your own Nullable<>
wrapper type
Trait Implementations
sourceimpl AllAreNullable<IsNullable> for NotNull
impl AllAreNullable<IsNullable> for NotNull
sourceimpl AllAreNullable<NotNull> for IsNullable
impl AllAreNullable<NotNull> for IsNullable
sourceimpl<O> MaybeNullableType<O> for NotNullwhere
O: SqlType + TypedExpressionType,
impl<O> MaybeNullableType<O> for NotNullwhere
O: SqlType + TypedExpressionType,
type Out = O
type Out = O
See the trait documentation
sourceimpl OneIsNullable<IsNullable> for NotNull
impl OneIsNullable<IsNullable> for NotNull
type Out = IsNullable
type Out = IsNullable
See the trait documentation
sourceimpl OneIsNullable<NotNull> for IsNullable
impl OneIsNullable<NotNull> for IsNullable
type Out = IsNullable
type Out = IsNullable
See the trait documentation
impl Copy for NotNull
Auto Trait Implementations
impl RefUnwindSafe for NotNull
impl Send for NotNull
impl Sync for NotNull
impl Unpin for NotNull
impl UnwindSafe for NotNull
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> IntoSql for T
impl<T> IntoSql for T
sourcefn into_sql<T>(self) -> AsExprOf<Self, T>where
Self: AsExpression<T> + Sized,
T: SqlType + TypedExpressionType,
fn into_sql<T>(self) -> AsExprOf<Self, T>where
Self: AsExpression<T> + Sized,
T: SqlType + TypedExpressionType,
Convert
self
to an expression for Diesel’s query builder. Read moresourcefn as_sql<'a, T>(&'a self) -> AsExprOf<&'a Self, T>where
&'a Self: AsExpression<T>,
T: SqlType + TypedExpressionType,
fn as_sql<'a, T>(&'a self) -> AsExprOf<&'a Self, T>where
&'a Self: AsExpression<T>,
T: SqlType + TypedExpressionType,
Convert
&self
to an expression for Diesel’s query builder. Read more