pub struct DayOfYearNoLeap(/* private fields */);Expand description
The supported range of “day of year,” but never including Feb 29.
This means that the valid range for all years is 1..=365. And there
is no way to refer to Feb 29 in this scheme.
Implementations§
Source§impl DayOfYearNoLeap
impl DayOfYearNoLeap
pub const MIN: i16 = <DayOfYearNoLeap as Bounds>::MIN
pub const MAX: i16 = <DayOfYearNoLeap as Bounds>::MAX
pub const LEN: i128
pub const fn error() -> BoundsError
pub fn check(n: impl Into<i64>) -> Result<i16, BoundsError>
pub const fn checkc(n: i64) -> Result<i16, BoundsError>
pub const fn checked_add(n1: i16, n2: i16) -> Result<i16, BoundsError>
pub fn checked_mul(n1: i16, n2: i16) -> Result<i16, BoundsError>
Trait Implementations§
Source§impl Bounds for DayOfYearNoLeap
impl Bounds for DayOfYearNoLeap
Source§const WHAT: &'static str = "day-of-year (skipping Feb 29)"
const WHAT: &'static str = "day-of-year (skipping Feb 29)"
A short human readable description of the values represented by these
bounds. This is used in error messages.
Source§type Error = BoundsError
type Error = BoundsError
The error type returned when a value is considered out of range for
this particular implementation. Read more
Source§fn error() -> BoundsError
fn error() -> BoundsError
Create an error when a value is outside the bounds for this type.
Source§fn check(n: impl Into<i64>) -> Result<Self::Primitive, Self::Error>
fn check(n: impl Into<i64>) -> Result<Self::Primitive, Self::Error>
Converts the 64-bit integer provided into the primitive representation
of these bounds. Read more
Source§fn check_self(n: Self::Primitive) -> Result<Self::Primitive, Self::Error>
fn check_self(n: Self::Primitive) -> Result<Self::Primitive, Self::Error>
Checks whether the given integer, in the same primitive representation
as this boundary type, is in bounds. Read more
impl Eq for DayOfYearNoLeap
Source§impl PartialEq for DayOfYearNoLeap
impl PartialEq for DayOfYearNoLeap
impl StructuralPartialEq for DayOfYearNoLeap
Auto Trait Implementations§
impl Forget for DayOfYearNoLeap
impl Freeze for DayOfYearNoLeap
impl Move for DayOfYearNoLeap
impl RefUnwindSafe for DayOfYearNoLeap
impl Send for DayOfYearNoLeap
impl Sync for DayOfYearNoLeap
impl Unpin for DayOfYearNoLeap
impl UnsafeUnpin for DayOfYearNoLeap
impl UnwindSafe for DayOfYearNoLeap
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