pub struct ReferenceWithTimezone {
pub instant: JsDate,
pub timezone_offset: Option<i64>,
}Expand description
upstream ReferenceWithTimezone.
Fields§
§instant: JsDate§timezone_offset: Option<i64>Minutes east of UTC, or None (use the system time zone, which is UTC).
Implementations§
Source§impl ReferenceWithTimezone
impl ReferenceWithTimezone
pub fn new( instant: JsDate, timezone_offset: Option<i64>, ) -> ReferenceWithTimezone
Sourcepub fn from_input(
input: &ReferenceInput,
overrides: &TimezoneAbbrMap,
now: JsDate,
) -> ReferenceWithTimezone
pub fn from_input( input: &ReferenceInput, overrides: &TimezoneAbbrMap, now: JsDate, ) -> ReferenceWithTimezone
ReferenceWithTimezone.fromInput(input, timezoneOverrides). now is used where upstream calls new Date().
Sourcepub fn get_date_with_adjusted_timezone(&self) -> JsDate
pub fn get_date_with_adjusted_timezone(&self) -> JsDate
getDateWithAdjustedTimezone(): a date whose (system-local = UTC) fields equal the
reference’s wall-clock fields in the reference time zone.
Sourcepub fn get_system_timezone_adjustment_minute(
&self,
date: Option<JsDate>,
override_offset: Option<i64>,
) -> i64
pub fn get_system_timezone_adjustment_minute( &self, date: Option<JsDate>, override_offset: Option<i64>, ) -> i64
getSystemTimezoneAdjustmentMinute(date, overrideTimezoneOffset).
Sourcepub fn get_timezone_offset(&self) -> i64
pub fn get_timezone_offset(&self) -> i64
getTimezoneOffset().
Trait Implementations§
Source§impl Clone for ReferenceWithTimezone
impl Clone for ReferenceWithTimezone
impl Copy for ReferenceWithTimezone
Source§impl Debug for ReferenceWithTimezone
impl Debug for ReferenceWithTimezone
impl Eq for ReferenceWithTimezone
Source§impl PartialEq for ReferenceWithTimezone
impl PartialEq for ReferenceWithTimezone
impl StructuralPartialEq for ReferenceWithTimezone
Auto Trait Implementations§
impl Forget for ReferenceWithTimezone
impl Freeze for ReferenceWithTimezone
impl RefUnwindSafe for ReferenceWithTimezone
impl Send for ReferenceWithTimezone
impl Sync for ReferenceWithTimezone
impl Unpin for ReferenceWithTimezone
impl UnsafeUnpin for ReferenceWithTimezone
impl UnwindSafe for ReferenceWithTimezone
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