Skip to main content

ContextConversionTarget

Trait ContextConversionTarget 

Source
pub trait ContextConversionTarget<S: Scale>: Sealed {
    type Output;

    // Required method
    fn convert_with(
        src: Time<S>,
        ctx: &TimeContext,
    ) -> Result<Self::Output, ConversionError>;
}
Expand description

Unified context-backed conversion target for Time<S>::to_with::<T>(&ctx).

Required Associated Types§

Required Methods§

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl ContextConversionTarget<UTC> for Unix

Source§

impl<S1, S2> ContextConversionTarget<S1> for S2
where S1: Scale + ContextScaleConvert<S2>, S2: Scale,

Source§

type Output = Time<S2>

Source§

impl<S> ContextConversionTarget<S> for GPS
where S: Scale + ContextScaleConvert<TAI>,

Source§

impl<S> ContextConversionTarget<S> for Unix
where S: Scale + ContextScaleConvert<UTC>,