pub enum DateField {
Single(NaiveDate),
Range {
from: NaiveDate,
to: NaiveDate,
},
Multi(Vec<NaiveDate>),
}Expand description
The types that appear in the public fields of a Work, re-exported so a
caller of Crossref::works can name them without reaching into
response::work.
The types that appear in the public fields of a Work, re-exported so a
caller of Crossref::works can name them without reaching into
response::work.
The types that appear in the public fields of a Work, re-exported so a
caller of Crossref::works can name them without reaching into
response::work.
Helper struct to capture all possible occurrences of dates in the crossref api, a nested Vec of numbers
Variants§
Single(NaiveDate)
only a single date vector
Range
two date vectors represent a range
Multi(Vec<NaiveDate>)
more than two date vectors are present
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for DateField
impl<'de> Deserialize<'de> for DateField
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
impl Eq for DateField
impl StructuralPartialEq for DateField
Auto Trait Implementations§
impl Freeze for DateField
impl RefUnwindSafe for DateField
impl Send for DateField
impl Sync for DateField
impl Unpin for DateField
impl UnsafeUnpin for DateField
impl UnwindSafe for DateField
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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.