Trait icu_datetime::neo_marker::ConvertCalendar

source ·
pub trait ConvertCalendar {
    type Converted<'a>: Sized;

    // Required method
    fn to_calendar<'a>(&self, calendar: &'a AnyCalendar) -> Self::Converted<'a>;
}
Expand description

A type that can be converted into a specific calendar system.

Required Associated Types§

source

type Converted<'a>: Sized

The converted type. This can be the same as the receiver type.

Required Methods§

source

fn to_calendar<'a>(&self, calendar: &'a AnyCalendar) -> Self::Converted<'a>

Converts self to the specified [AnyCalendar].

Object Safety§

This trait is not object safe.

Implementations on Foreign Types§

source§

impl ConvertCalendar for CustomTimeZone

§

type Converted<'a> = CustomTimeZone

source§

fn to_calendar<'a>(&self, _: &'a AnyCalendar) -> Self::Converted<'a>

source§

impl ConvertCalendar for Time

§

type Converted<'a> = Time

source§

fn to_calendar<'a>(&self, _: &'a AnyCalendar) -> Self::Converted<'a>

source§

impl<C: IntoAnyCalendar, A: AsCalendar<Calendar = C>> ConvertCalendar for CustomZonedDateTime<A>

§

type Converted<'a> = CustomZonedDateTime<Ref<'a, AnyCalendar>>

source§

fn to_calendar<'a>(&self, calendar: &'a AnyCalendar) -> Self::Converted<'a>

source§

impl<C: IntoAnyCalendar, A: AsCalendar<Calendar = C>> ConvertCalendar for Date<A>

§

type Converted<'a> = Date<Ref<'a, AnyCalendar>>

source§

fn to_calendar<'a>(&self, calendar: &'a AnyCalendar) -> Self::Converted<'a>

source§

impl<C: IntoAnyCalendar, A: AsCalendar<Calendar = C>> ConvertCalendar for DateTime<A>

§

type Converted<'a> = DateTime<Ref<'a, AnyCalendar>>

source§

fn to_calendar<'a>(&self, calendar: &'a AnyCalendar) -> Self::Converted<'a>

Implementors§