Struct IsoWeek
struct IsoWeek { ... }
ISO 8601 week.
This type, combined with Weekday,
constitutes the ISO 8601 week date.
One can retrieve this type from the existing Datelike types
via the Datelike::iso_week method.
Implementations
impl IsoWeek
const fn year(self: &Self) -> i32Returns the year number for this ISO week.
Example
use ; let d = from_isoywd_opt.unwrap; assert_eq!;This year number might not match the calendar year number. Continuing the example...
# use ; # let d = from_isoywd_opt.unwrap; assert_eq!; assert_eq!;const fn week(self: &Self) -> u32Returns the ISO week number starting from 1.
The return value ranges from 1 to 53. (The last week of year differs by years.)
Example
use ; let d = from_isoywd_opt.unwrap; assert_eq!;const fn week0(self: &Self) -> u32Returns the ISO week number starting from 0.
The return value ranges from 0 to 52. (The last week of year differs by years.)
Example
use ; let d = from_isoywd_opt.unwrap; assert_eq!;
impl Clone for IsoWeek
fn clone(self: &Self) -> IsoWeek
impl Copy for IsoWeek
impl Debug for IsoWeek
fn fmt(self: &Self, f: &mut Formatter<'_>) -> Result
impl Eq for IsoWeek
impl Freeze for IsoWeek
impl Hash for IsoWeek
fn hash<__H: $crate::hash::Hasher>(self: &Self, state: &mut __H)
impl Ord for IsoWeek
fn cmp(self: &Self, other: &IsoWeek) -> Ordering
impl PartialEq for IsoWeek
fn eq(self: &Self, other: &IsoWeek) -> bool
impl PartialOrd for IsoWeek
fn partial_cmp(self: &Self, other: &IsoWeek) -> Option<Ordering>
impl RefUnwindSafe for IsoWeek
impl Send for IsoWeek
impl StructuralPartialEq for IsoWeek
impl Sync for IsoWeek
impl Unpin for IsoWeek
impl UnsafeUnpin for IsoWeek
impl UnwindSafe for IsoWeek
impl<T> Any for IsoWeek
fn type_id(self: &Self) -> TypeId
impl<T> Borrow for IsoWeek
fn borrow(self: &Self) -> &T
impl<T> BorrowMut for IsoWeek
fn borrow_mut(self: &mut Self) -> &mut T
impl<T> CloneToUninit for IsoWeek
unsafe fn clone_to_uninit(self: &Self, dest: *mut u8)
impl<T> From for IsoWeek
fn from(t: T) -> TReturns the argument unchanged.
impl<T> ToOwned for IsoWeek
fn to_owned(self: &Self) -> Tfn clone_into(self: &Self, target: &mut T)
impl<T, U> Into for IsoWeek
fn into(self: Self) -> UCalls
U::from(self).That is, this conversion is whatever the implementation of
[From]<T> for Uchooses to do.
impl<T, U> TryFrom for IsoWeek
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
impl<T, U> TryInto for IsoWeek
fn try_into(self: Self) -> Result<U, <U as TryFrom<T>>::Error>