pub struct DurationLiteral {
pub months: i32,
pub days: i32,
pub nanos: i64,
}
Fields§
§months: i32
§days: i32
§nanos: i64
Implementations§
Source§impl DurationLiteral
impl DurationLiteral
pub fn ns(self, ns: i64) -> Self
pub fn us(self, us: i64) -> Self
pub fn ms(self, ms: i64) -> Self
pub fn s(self, s: i64) -> Self
pub fn m(self, m: i32) -> Self
pub fn h(self, h: i32) -> Self
pub fn d(self, d: i32) -> Self
pub fn w(self, w: i32) -> Self
pub fn mo(self, mo: i32) -> Self
pub fn y(self, y: i32) -> Self
Trait Implementations§
Source§impl Clone for DurationLiteral
impl Clone for DurationLiteral
Source§fn clone(&self) -> DurationLiteral
fn clone(&self) -> DurationLiteral
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl<'a> CustomToTokens<'a> for DurationLiteral
impl<'a> CustomToTokens<'a> for DurationLiteral
Source§impl Debug for DurationLiteral
impl Debug for DurationLiteral
Source§impl Default for DurationLiteral
impl Default for DurationLiteral
Source§fn default() -> DurationLiteral
fn default() -> DurationLiteral
Returns the “default value” for a type. Read more
Source§impl Display for DurationLiteral
impl Display for DurationLiteral
Source§impl From<Duration> for DurationLiteral
impl From<Duration> for DurationLiteral
Source§impl From<NaiveDateTime> for DurationLiteral
impl From<NaiveDateTime> for DurationLiteral
Source§fn from(dt: NaiveDateTime) -> Self
fn from(dt: NaiveDateTime) -> Self
Converts to this type from the input type.
Source§impl FromStr for DurationLiteral
impl FromStr for DurationLiteral
Source§impl Parse for DurationLiteral
impl Parse for DurationLiteral
type Output = DurationLiteral
fn parse(s: &mut StatementStream<'_>) -> Result<Self::Output>
Source§impl PartialEq for DurationLiteral
impl PartialEq for DurationLiteral
Source§impl ToTokens for DurationLiteral
impl ToTokens for DurationLiteral
Source§fn to_token_stream(&self) -> TokenStream
fn to_token_stream(&self) -> TokenStream
Source§fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
fn into_token_stream(self) -> TokenStreamwhere
Self: Sized,
impl Eq for DurationLiteral
impl StructuralPartialEq for DurationLiteral
Auto Trait Implementations§
impl Freeze for DurationLiteral
impl RefUnwindSafe for DurationLiteral
impl Send for DurationLiteral
impl Sync for DurationLiteral
impl Unpin for DurationLiteral
impl UnwindSafe for DurationLiteral
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