pub struct UCalendar { /* private fields */ }
Expand description

Implements the UCalendar type from ucal.h.

The naming rust_icu_ucal::UCalendar is a bit repetetetitive, but makes it a bit more obvious what ICU type it is wrapping.

Implementations

Creates a new UCalendar.

Implements ucal_open.

Returns this UCalendar’s internal C representation. Use only for interfacing with the C low-level API.

Sets the calendar’s current date/time in milliseconds since the epoch.

Implements ucal_setMillis.

Gets the calendar’s current date/time in milliseconds since the epoch.

Implements ucal_getMillis.

Sets the calendar’s current date in the calendar’s local time zone.

Note that month is 0-based.

Implements ucal_setDate.

Sets the calendar’s current date and time in the calendar’s local time zone.

Note that month is 0-based.

Implements ucal_setDateTime.

Returns the calendar’s time zone’s offset from UTC in milliseconds, for the calendar’s current date/time.

This does not include the daylight savings offset, if any. Note that the calendar’s current date/time is significant because time zones are occasionally redefined – a time zone that has a +16.5 hour offset today might have had a +17 hour offset a decade ago.

Wraps ucal_get for UCAL_ZONE_OFFSET.

Returns the calendar’s daylight savings offset from its non-DST time, in milliseconds, for the calendar’s current date/time. This may be 0 if the time zone does not observe DST at all, or if the time zone is not in the daylight savings period at the calendar’s current date/time.

Wraps ucal_get for UCAL_ZONE_DST_OFFSET.

Returns true if the calendar is currently in daylight savings / summer time.

Implements ucal_inDaylightTime.

Implements ucal_get.

Consider using specific higher-level methods instead.

Trait Implementations

Formats the value using the given formatter. Read more

Deallocates the internal representation of UCalendar.

Implements ucal_close.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.