pub struct Range<ST>(_);
Expand description
The Range
SQL type.
This wraps another type to represent a SQL range of that type.
ToSql
impls
(Bound<T>, Bound<T>)
for anyT
which implementsToSql<ST>
.
FromSql
impls
(Bound<T>, Bound<T>)
for anyT
which implementsFromSql<ST>
.
Trait Implementations
sourceimpl<ST, T> AsExpression<Range<ST>> for (Bound<T>, Bound<T>)
impl<ST, T> AsExpression<Range<ST>> for (Bound<T>, Bound<T>)
type Expression = SqlBound<Range<ST>, Self>
type Expression = SqlBound<Range<ST>, Self>
The expression being returned
sourcefn as_expression(self) -> Self::Expression
fn as_expression(self) -> Self::Expression
Perform the conversion
sourceimpl<'a, ST, T> AsExpression<Range<ST>> for &'a (Bound<T>, Bound<T>)
impl<'a, ST, T> AsExpression<Range<ST>> for &'a (Bound<T>, Bound<T>)
type Expression = SqlBound<Range<ST>, Self>
type Expression = SqlBound<Range<ST>, Self>
The expression being returned
sourcefn as_expression(self) -> Self::Expression
fn as_expression(self) -> Self::Expression
Perform the conversion
sourceimpl<T, ST> FromSqlRow<Range<ST>, Pg> for (Bound<T>, Bound<T>) where
(Bound<T>, Bound<T>): FromSql<Range<ST>, Pg>,
impl<T, ST> FromSqlRow<Range<ST>, Pg> for (Bound<T>, Bound<T>) where
(Bound<T>, Bound<T>): FromSql<Range<ST>, Pg>,
sourceconst FIELDS_NEEDED: usize
const FIELDS_NEEDED: usize
The number of fields that this type will consume. Must be equal to
the number of times you would call row.take()
in build_from_row
Read more
sourceimpl HasSqlType<Range<BigInt>> for Pg
impl HasSqlType<Range<BigInt>> for Pg
sourcefn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
sourceimpl HasSqlType<Range<Date>> for Pg
impl HasSqlType<Range<Date>> for Pg
sourcefn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
sourceimpl HasSqlType<Range<Integer>> for Pg
impl HasSqlType<Range<Integer>> for Pg
sourcefn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
sourceimpl HasSqlType<Range<Numeric>> for Pg
impl HasSqlType<Range<Numeric>> for Pg
sourcefn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
sourceimpl HasSqlType<Range<Timestamp>> for Pg
impl HasSqlType<Range<Timestamp>> for Pg
sourcefn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
sourceimpl HasSqlType<Range<Timestamptz>> for Pg
impl HasSqlType<Range<Timestamptz>> for Pg
sourcefn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
fn metadata(_: &PgMetadataLookup) -> PgTypeMetadata
Fetch the metadata for the given type Read more
sourceimpl<ST: QueryId> QueryId for Range<ST>
impl<ST: QueryId> QueryId for Range<ST>
sourceimpl<T, ST> Queryable<Range<ST>, Pg> for (Bound<T>, Bound<T>) where
T: FromSql<ST, Pg> + Queryable<ST, Pg>,
impl<T, ST> Queryable<Range<ST>, Pg> for (Bound<T>, Bound<T>) where
T: FromSql<ST, Pg> + Queryable<ST, Pg>,
impl<ST: Copy> Copy for Range<ST>
impl<ST> NotNull for Range<ST>
impl<ST> SingleValue for Range<ST>
Auto Trait Implementations
impl<ST> RefUnwindSafe for Range<ST> where
ST: RefUnwindSafe,
impl<ST> Send for Range<ST> where
ST: Send,
impl<ST> Sync for Range<ST> where
ST: Sync,
impl<ST> Unpin for Range<ST> where
ST: Unpin,
impl<ST> UnwindSafe for Range<ST> where
ST: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> IntoNullable for T where
T: NotNull,
impl<T> IntoNullable for T where
T: NotNull,
sourceimpl<T> IntoSql for T
impl<T> IntoSql for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more