pub struct Ref<'a, C>(pub &'a C);Expand description
This exists as a wrapper around &'a T so that
Date<&'a C> is possible for calendar C.
Unfortunately,
AsCalendar cannot be implemented on &'a T directly because
&'a T is #[fundamental] and the impl would clash with the one above with
AsCalendar for C: Calendar.
Use Date<Ref<'a, C>> where you would use Date<&'a C>
Tuple Fields§
§0: &'a CTrait Implementations§
Source§impl<C> AsCalendar for Ref<'_, C>where
    C: AsCalendar,
 
impl<C> AsCalendar for Ref<'_, C>where
    C: AsCalendar,
Source§type Calendar = <C as AsCalendar>::Calendar
 
type Calendar = <C as AsCalendar>::Calendar
The calendar being wrapped
Source§fn as_calendar(&self) -> &<Ref<'_, C> as AsCalendar>::Calendar
 
fn as_calendar(&self) -> &<Ref<'_, C> as AsCalendar>::Calendar
Obtain the inner calendar
impl<C> Copy for Ref<'_, C>
impl<'a, C> Eq for Ref<'a, C>where
    C: Eq,
impl<'a, C> StructuralPartialEq for Ref<'a, C>
Auto Trait Implementations§
impl<'a, C> Freeze for Ref<'a, C>
impl<'a, C> RefUnwindSafe for Ref<'a, C>where
    C: RefUnwindSafe,
impl<'a, C> Send for Ref<'a, C>where
    C: Sync,
impl<'a, C> Sync for Ref<'a, C>where
    C: Sync,
impl<'a, C> Unpin for Ref<'a, C>
impl<'a, C> UnwindSafe for Ref<'a, C>where
    C: RefUnwindSafe,
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§impl<T> IntoEither for T
 
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
 
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts 
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
 
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts 
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more