Struct Transition

pub struct Transition { /* private fields */ }

A representation a single time zone transition.

Implementations

impl Transition

fn timestamp(&self) -> Timestamp

Returns the timestamp at which this transition began.

fn offset(&self) -> Offset

Returns the offset corresponding to this time zone transition. All instants at and following this transition's timestamp (and before the next transition's timestamp) need to apply this offset from UTC to get the civil or "local" time in the corresponding time zone.

fn abbreviation(&self) -> &Abbreviation

Returns the time zone abbreviation corresponding to this time zone transition.

fn dst(&self) -> Dst

Returns whether daylight saving time is enabled for this time zone transition.

fn into_offset_info(self) -> OffsetInfo

Consumes this transition and returns the underlying OffsetInfo.

Trait Implementations

impl Clone for Transition

fn clone(&self) -> Transition

impl Debug for Transition

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Auto Trait Implementations

impl Freeze for Transition

impl RefUnwindSafe for Transition

impl Send for Transition

impl Sync for Transition

impl Unpin for Transition

impl UnsafeUnpin for Transition

impl UnwindSafe for Transition

Blanket Implementations

impl<T> Any for Transition where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for Transition where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for Transition where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> CloneToUninit for Transition where T: Clone,

unsafe fn clone_to_uninit(&self, dest: *mut u8)

impl<T> From<T> for Transition

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> ToOwned for Transition where T: Clone,

type Owned = T;
fn to_owned(&self) -> T
fn clone_into(&self, target: &mut T)

impl<T, U> Into<U> for Transition where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for Transition where U: Into<T>,

type Error = Infallible;
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto<U> for Transition where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>