pub enum IntervalUnit {
Show 13 variants
Day,
DayToHour,
DayToMinute,
DayToSecond,
Hour,
HourToMinute,
HourToSecond,
Minute,
MinuteToSecond,
Month,
Second,
Year,
YearToMonth,
}Expand description
The specified units for SQL Interval types.
INTERVAL 1 DAY, INTERVAL 1 DAY TO HOUR, INTERVAL 1 DAY TO MINUTE,
would yield Day, DayToHour, DayToMinute, as the IntervalUnit respectively.
Variants§
Day
Unit for INTERVAL ... DAY.
DayToHour
Unit for INTERVAL ... DAY TO HOUR.
DayToMinute
Unit for INTERVAL ... DAY TO MINUTE.
DayToSecond
Unit for INTERVAL ... DAY TO SECOND.
Hour
Unit for INTERVAL ... HOUR.
HourToMinute
Unit for INTERVAL ... HOUR TO MINUTE.
HourToSecond
Unit for INTERVAL ... HOUR TO SECOND.
Minute
Unit for INTERVAL ... MINUTE.
MinuteToSecond
Unit for INTERVAL ... MINUTE TO SECOND.
Month
Unit for INTERVAL ... MONTH.
Second
Unit for INTERVAL ... SECOND.
Year
Unit for INTERVAL ... YEAR.
YearToMonth
Unit for INTERVAL ... YEAR TO MONTH.
Trait Implementations§
source§impl Clone for IntervalUnit
impl Clone for IntervalUnit
source§fn clone(&self) -> IntervalUnit
fn clone(&self) -> IntervalUnit
Returns a copy of the value. Read more
1.6.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for IntervalUnit
impl Debug for IntervalUnit
source§impl<'de> Deserialize<'de> for IntervalUnit
impl<'de> Deserialize<'de> for IntervalUnit
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for IntervalUnit
impl PartialEq for IntervalUnit
source§impl Serialize for IntervalUnit
impl Serialize for IntervalUnit
source§impl<'__s> ToSchema<'__s> for IntervalUnit
impl<'__s> ToSchema<'__s> for IntervalUnit
impl Copy for IntervalUnit
impl Eq for IntervalUnit
impl StructuralPartialEq for IntervalUnit
Auto Trait Implementations§
impl Freeze for IntervalUnit
impl RefUnwindSafe for IntervalUnit
impl Send for IntervalUnit
impl Sync for IntervalUnit
impl Unpin for IntervalUnit
impl UnwindSafe for IntervalUnit
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit)source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.