[−][src]Trait spaces::BoundedSpace
Trait for defining spaces bounded to lie on an interval I.
Note: If both inf
and sup
are well defined (i.e. are not None), then the interval is
bounded and you have defined a compact space; this is true in spaces
as the Interval type is
closed.
Associated Types
type BoundValue: PartialOrd + Copy
The upper/lower bound type; not necessarily equal to Space::Value
.
Required methods
fn inf(&self) -> Option<Self::BoundValue>
Returns the value of the dimension's infimum, if it exists.
fn sup(&self) -> Option<Self::BoundValue>
Returns the value of the dimension's supremum, if it exists.
fn contains(&self, val: Self::BoundValue) -> bool
Returns true iff val
lies within the dimension's bounds (closed).