#[non_exhaustive]pub struct WeekNumber {
pub padding: Padding,
pub repr: WeekNumberRepr,
}use WeekNumberIso, WeekNumberSunday, or WeekNumberMonday instead
cookies and (crate features formatting or parsing) only.Expand description
Week within the year.
Fields (Non-exhaustive)ยง
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.padding: Paddinguse WeekNumberIso, WeekNumberSunday, or WeekNumberMonday instead
The padding to obtain the minimum width.
repr: WeekNumberRepruse WeekNumberIso, WeekNumberSunday, or WeekNumberMonday instead
What kind of representation should be used?
Implementationsยง
Sourceยงimpl WeekNumber
impl WeekNumber
Sourcepub const fn default() -> WeekNumber
pub const fn default() -> WeekNumber
Creates a modifier that indicates that the value is padded with zeroes
and uses the Iso representation.
This function exists since Default::default() cannot be used in a const context.
It may be removed once that becomes possible. As the Default trait is in the
prelude, removing this function in the future will not cause any resolution failures for
the overwhelming majority of users; only users who use #![no_implicit_prelude] will be
affected. As such it will not be considered a breaking change.
Sourceยงimpl WeekNumber
impl WeekNumber
Sourcepub const fn with_padding(self, padding: Padding) -> WeekNumber
pub const fn with_padding(self, padding: Padding) -> WeekNumber
Set the padding type.
Sourcepub const fn with_repr(self, repr: WeekNumberRepr) -> WeekNumber
pub const fn with_repr(self, repr: WeekNumberRepr) -> WeekNumber
Set the manner in which the week number is represented.
Trait Implementationsยง
Sourceยงimpl Clone for WeekNumber
impl Clone for WeekNumber
Sourceยงfn clone(&self) -> WeekNumber
fn clone(&self) -> WeekNumber
1.0.0 (const: unstable) ยท Sourceยงfn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for WeekNumber
Sourceยงimpl Debug for WeekNumber
impl Debug for WeekNumber
Sourceยงimpl Default for WeekNumber
Creates a modifier that indicates that the value is padded with zeroes
and uses the Iso representation.
impl Default for WeekNumber
Creates a modifier that indicates that the value is padded with zeroes
and uses the Iso representation.
Sourceยงfn default() -> WeekNumber
fn default() -> WeekNumber
impl Eq for WeekNumber
Sourceยงimpl PartialEq for WeekNumber
impl PartialEq for WeekNumber
Sourceยงfn eq(&self, other: &WeekNumber) -> bool
fn eq(&self, other: &WeekNumber) -> bool
self and other values to be equal, and is used by ==.impl StructuralPartialEq for WeekNumber
Auto Trait Implementationsยง
impl Freeze for WeekNumber
impl RefUnwindSafe for WeekNumber
impl Send for WeekNumber
impl Sync for WeekNumber
impl Unpin for WeekNumber
impl UnsafeUnpin for WeekNumber
impl UnwindSafe for WeekNumber
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
Sourceยงimpl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Sourceยงimpl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Sourceยงimpl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Sourceยงfn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.