pub struct BusinessDay { /* private fields */ }Expand description
One Europe/Berlin electricity business day.
Implementations§
Source§impl BusinessDay
impl BusinessDay
Sourcepub fn new(date: Date) -> Result<Self, CalendarError>
pub fn new(date: Date) -> Result<Self, CalendarError>
The business day for a local calendar date.
§Errors
CalendarError::Unsupported outside the supported years.
Sourcepub fn containing(instant: OffsetDateTime) -> Result<Self, CalendarError>
pub fn containing(instant: OffsetDateTime) -> Result<Self, CalendarError>
The business day containing instant.
§Errors
CalendarError::Unsupported outside the supported years.
Sourcepub const fn start(&self) -> OffsetDateTime
pub const fn start(&self) -> OffsetDateTime
Start instant (UTC), inclusive.
Sourcepub const fn end(&self) -> OffsetDateTime
pub const fn end(&self) -> OffsetDateTime
End instant (UTC), exclusive.
Sourcepub fn quarters(&self) -> impl Iterator<Item = Quarter> + '_
pub fn quarters(&self) -> impl Iterator<Item = Quarter> + '_
The quarters of this day in time order.
Sourcepub fn next(&self) -> Result<Self, CalendarError>
pub fn next(&self) -> Result<Self, CalendarError>
Trait Implementations§
Source§impl Clone for BusinessDay
impl Clone for BusinessDay
impl Copy for BusinessDay
Source§impl Debug for BusinessDay
impl Debug for BusinessDay
impl Eq for BusinessDay
Source§impl PartialEq for BusinessDay
impl PartialEq for BusinessDay
impl StructuralPartialEq for BusinessDay
Auto Trait Implementations§
impl Forget for BusinessDay
impl Freeze for BusinessDay
impl Move for BusinessDay
impl RefUnwindSafe for BusinessDay
impl Send for BusinessDay
impl Sync for BusinessDay
impl Unpin for BusinessDay
impl UnsafeUnpin for BusinessDaywhere
NonZeroI32Inner: UnsafeUnpin,
impl UnwindSafe for BusinessDay
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