Struct icu_datetime::time_zone::LocalizedGmtFormat
source · pub(crate) struct LocalizedGmtFormat {}
Trait Implementations§
source§impl Clone for LocalizedGmtFormat
impl Clone for LocalizedGmtFormat
source§fn clone(&self) -> LocalizedGmtFormat
fn clone(&self) -> LocalizedGmtFormat
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for LocalizedGmtFormat
impl Debug for LocalizedGmtFormat
source§impl FormatTimeZone for LocalizedGmtFormat
impl FormatTimeZone for LocalizedGmtFormat
source§fn format<W: PartsWrite + ?Sized>(
&self,
sink: &mut W,
time_zone: &impl TimeZoneInput,
data_payloads: &TimeZoneDataPayloads,
) -> Result<Result, DateTimeError>
fn format<W: PartsWrite + ?Sized>( &self, sink: &mut W, time_zone: &impl TimeZoneInput, data_payloads: &TimeZoneDataPayloads, ) -> Result<Result, DateTimeError>
Tries to write the timezone to the sink. If a DateTimeError is returned, the sink
has not been touched, so another format can be attempted.
source§impl FormatTimeZoneWithFallback for LocalizedGmtFormat
impl FormatTimeZoneWithFallback for LocalizedGmtFormat
source§fn format_gmt_offset<W: PartsWrite + ?Sized>(
&self,
sink: &mut W,
gmt_offset: GmtOffset,
data_payloads: &TimeZoneDataPayloads,
) -> Result
fn format_gmt_offset<W: PartsWrite + ?Sized>( &self, sink: &mut W, gmt_offset: GmtOffset, data_payloads: &TimeZoneDataPayloads, ) -> Result
Writes the time zone in localized GMT format according to the CLDR localized hour format. This goes explicitly against the UTS-35 spec, which specifies long or short localized GMT formats regardless of locale.
You can see more information about our decision to resolve this conflict here: https://docs.google.com/document/d/16GAqaDRS6hzL8jNYjus5MglSevGBflISM-BrIS7bd4A/edit?usp=sharing
source§fn format_with_last_resort_fallback<W: PartsWrite + ?Sized>(
&self,
sink: &mut W,
time_zone: &impl TimeZoneInput,
data_payloads: &TimeZoneDataPayloads,
) -> Result<Result<(), DateTimeError>, Error>
fn format_with_last_resort_fallback<W: PartsWrite + ?Sized>( &self, sink: &mut W, time_zone: &impl TimeZoneInput, data_payloads: &TimeZoneDataPayloads, ) -> Result<Result<(), DateTimeError>, Error>
Formats the GMT offset, or falls back to a fallback string. This does
lossy writing, so even in the Ok(Err(_)) case, something has been written.
source§impl PartialEq for LocalizedGmtFormat
impl PartialEq for LocalizedGmtFormat
impl Copy for LocalizedGmtFormat
impl StructuralPartialEq for LocalizedGmtFormat
Auto Trait Implementations§
impl Freeze for LocalizedGmtFormat
impl RefUnwindSafe for LocalizedGmtFormat
impl Send for LocalizedGmtFormat
impl Sync for LocalizedGmtFormat
impl Unpin for LocalizedGmtFormat
impl UnwindSafe for LocalizedGmtFormat
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§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)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