Enum WindowEnd
pub enum WindowEnd {
Date(NaiveDate),
Contract(String),
}Expand description
One end of a window locator: a date, or a quarterly IMM contract code standing for its third Wednesday.
Variants§
Date(NaiveDate)
A calendar date.
Contract(String)
A quarterly IMM code such as SEP27: the third Wednesday of that month.
Implementations§
§impl WindowEnd
impl WindowEnd
pub fn date(&self) -> Result<NaiveDate, RungBuildError>
pub fn date(&self) -> Result<NaiveDate, RungBuildError>
The date this end stands for.
§Errors
RungBuildError::Contract for a code naming no quarterly IMM month.
Trait Implementations§
impl Eq for WindowEnd
impl StructuralPartialEq for WindowEnd
Auto Trait Implementations§
impl Freeze for WindowEnd
impl RefUnwindSafe for WindowEnd
impl Send for WindowEnd
impl Sync for WindowEnd
impl Unpin for WindowEnd
impl UnsafeUnpin for WindowEnd
impl UnwindSafe for WindowEnd
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