pub struct VariantOffsetsCalculator { /* private fields */ }Expand description
VariantOffsetsCalculator uses data from the data provider to calculate time zone offsets.
Implementations§
Source§impl VariantOffsetsCalculator
 
impl VariantOffsetsCalculator
Sourcepub const fn new() -> VariantOffsetsCalculatorBorrowed<'static>
 
pub const fn new() -> VariantOffsetsCalculatorBorrowed<'static>
Constructs a VariantOffsetsCalculator using compiled data.
✨ Enabled with the compiled_data Cargo feature.
Sourcepub fn try_new_with_buffer_provider(
    provider: &(impl BufferProvider + ?Sized),
) -> Result<VariantOffsetsCalculator, DataError>
 
pub fn try_new_with_buffer_provider( provider: &(impl BufferProvider + ?Sized), ) -> Result<VariantOffsetsCalculator, DataError>
A version of [Self :: new] that uses custom data provided by a BufferProvider.
✨ Enabled with the serde feature.
Sourcepub fn try_new_unstable(
    provider: &(impl DataProvider<TimezoneVariantsOffsetsV1> + ?Sized),
) -> Result<VariantOffsetsCalculator, DataError>
 
pub fn try_new_unstable( provider: &(impl DataProvider<TimezoneVariantsOffsetsV1> + ?Sized), ) -> Result<VariantOffsetsCalculator, DataError>
A version of Self::new that uses custom data provided by a DataProvider.
⚠️ The bounds on provider may change over time, including in SemVer minor releases.
Sourcepub fn as_borrowed(&self) -> VariantOffsetsCalculatorBorrowed<'_>
 
pub fn as_borrowed(&self) -> VariantOffsetsCalculatorBorrowed<'_>
Returns a borrowed version of the calculator that can be queried.
This avoids a small potential indirection cost when querying.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for VariantOffsetsCalculator
impl RefUnwindSafe for VariantOffsetsCalculator
impl !Send for VariantOffsetsCalculator
impl !Sync for VariantOffsetsCalculator
impl Unpin for VariantOffsetsCalculator
impl UnwindSafe for VariantOffsetsCalculator
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> 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