[][src]Struct elastic_types::date::prelude::FormattableDateValue

pub struct FormattableDateValue<TFormat>(_, _);

A date value paired with a format.

FormattableDateValue<F> bundles a DateValue with a specific format and is used to ensure the formats of mappable date types aren't accidentally changed. Like DateValue, this type is used for binding generics in methods that accept date values but it requires the input type uses a specific format. You probably don't need to use it directly except to ensure date formats aren't silently changed.

Methods

impl<TFormat> FormattableDateValue<TFormat> where
    TFormat: DateFormat
[src]

pub fn format<'a>(&'a self) -> FormattedDate<'a>[src]

Format the wrapped date value using the generic format.

pub fn parse(date: &str) -> Result<Self, ParseError>[src]

Parse a date value using the generic format.

Trait Implementations

impl<TFormat: PartialEq> PartialEq<FormattableDateValue<TFormat>> for FormattableDateValue<TFormat>[src]

impl<TFormat> PartialEq<DateTime<Utc>> for FormattableDateValue<TFormat>[src]

impl<TFormat> PartialEq<FormattableDateValue<TFormat>> for ChronoDateTime[src]

impl<TFormat> From<FormattableDateValue<TFormat>> for DateValue[src]

impl<TFormat> From<DateValue> for FormattableDateValue<TFormat>[src]

impl From<DateTime<Utc>> for FormattableDateValue<ChronoFormat>[src]

impl<TMapping> From<Date<TMapping>> for FormattableDateValue<TMapping::Format> where
    TMapping: DateMapping
[src]

impl<TMapping> From<FormattableDateValue<<TMapping as DateMapping>::Format>> for Date<TMapping> where
    TMapping: DateMapping
[src]

impl<TFormat: Clone> Clone for FormattableDateValue<TFormat>[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl<TFormat: Debug> Debug for FormattableDateValue<TFormat>[src]

impl<TFormat> Borrow<DateTime<Utc>> for FormattableDateValue<TFormat>[src]

Auto Trait Implementations

impl<TFormat> Send for FormattableDateValue<TFormat> where
    TFormat: Send

impl<TFormat> Sync for FormattableDateValue<TFormat> where
    TFormat: Sync

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Same for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf for SP where
    SS: SubsetOf<SP>,