pub type RangeUpperBound<B> = RangeBound<B, true>;
Expand description
A RangeBound
that sorts correctly for use as an upper bound.
Aliased Type§
struct RangeUpperBound<B> {
pub inclusive: bool,
pub bound: Option<B>,
}
Fields§
§inclusive: bool
§bound: Option<B>
None value represents an infinite bound.
Implementations
Source§impl<'a, const UPPER: bool> RangeBound<Datum<'a>, UPPER>
impl<'a, const UPPER: bool> RangeBound<Datum<'a>, UPPER>
Sourcepub fn new(d: Datum<'a>, inclusive: bool) -> RangeBound<Datum<'a>, UPPER>
pub fn new(d: Datum<'a>, inclusive: bool) -> RangeBound<Datum<'a>, UPPER>
Create a new RangeBound
whose value is “infinite” (i.e. None) if d == Datum::Null
, otherwise finite (i.e. Some).
There is not a corresponding generic implementation of this because genericizing how to express infinite bounds is less clear.
Trait Implementations
Source§impl<B: Clone, const UPPER: bool> Clone for RangeBound<B, UPPER>
impl<B: Clone, const UPPER: bool> Clone for RangeBound<B, UPPER>
Source§fn clone(&self) -> RangeBound<B, UPPER>
fn clone(&self) -> RangeBound<B, UPPER>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read more