Trait chronologic::TimeBounds
source · pub trait TimeBounds {
type TimePoint: TimePoint;
// Required methods
fn is_empty(&self) -> bool;
fn is_low_bounded(&self) -> bool;
fn is_up_bounded(&self) -> bool;
fn lower_bound(&self) -> Self::TimePoint;
fn upper_bound(&self) -> Self::TimePoint;
// Provided methods
fn is_singleton(&self) -> bool { ... }
fn is_bounded(&self) -> bool { ... }
}Expand description
§The envelope (the bounds) of a time window
A trait which describes the envelope of a time window.
Required Associated Types§
Required Methods§
sourcefn is_low_bounded(&self) -> bool
fn is_low_bounded(&self) -> bool
Checks if this time window has a finite lower bound
It returns also false if this time window is empty.
sourcefn is_up_bounded(&self) -> bool
fn is_up_bounded(&self) -> bool
Checks if this time window has a finite upper bound
It returns also false if this time window is empty.
sourcefn lower_bound(&self) -> Self::TimePoint
fn lower_bound(&self) -> Self::TimePoint
The lower bound of the time window
The behavior is undefined if the time window is empty
sourcefn upper_bound(&self) -> Self::TimePoint
fn upper_bound(&self) -> Self::TimePoint
The upper bound of the time window
The behavior is undefined if the time window is empty
Provided Methods§
sourcefn is_singleton(&self) -> bool
fn is_singleton(&self) -> bool
Checks if this time window contains exactly one value
A singleton is not empty and its lower bound equals its upper bound.
sourcefn is_bounded(&self) -> bool
fn is_bounded(&self) -> bool
Checks if this time window is bounded
It returns also false if this time window is empty.