pub enum Range {
Integer(RangeImpl<Integer>),
NonNegativeInteger(RangeImpl<usize>),
TimestampPrecision(RangeImpl<TimestampPrecision>),
Timestamp(RangeImpl<Timestamp>),
Decimal(RangeImpl<Decimal>),
Float(RangeImpl<f64>),
Number(RangeImpl<Number>),
}Expand description
Represents ISL Ranges where some constraints can be defined using a range
<RANGE<RANGE_TYPE>> ::= range::[
Variants
Integer(RangeImpl<Integer>)
NonNegativeInteger(RangeImpl<usize>)
TimestampPrecision(RangeImpl<TimestampPrecision>)
Timestamp(RangeImpl<Timestamp>)
Decimal(RangeImpl<Decimal>)
Float(RangeImpl<f64>)
Number(RangeImpl<Number>)
Implementations
sourceimpl Range
impl Range
sourcepub fn contains(&self, value: &OwnedElement) -> bool
pub fn contains(&self, value: &OwnedElement) -> bool
Provides a boolean value to specify whether the given value is within the range or not
sourcepub fn from_ion_element(
value: &OwnedElement,
range_type: RangeType
) -> IonSchemaResult<Range>
pub fn from_ion_element(
value: &OwnedElement,
range_type: RangeType
) -> IonSchemaResult<Range>
Parse an OwnedElement into a Range using the RangeType
Trait Implementations
sourceimpl From<RangeImpl<Decimal>> for Range
impl From<RangeImpl<Decimal>> for Range
sourcefn from(value: DecimalRange) -> Self
fn from(value: DecimalRange) -> Self
Converts to this type from the input type.
sourceimpl From<RangeImpl<Integer>> for Range
impl From<RangeImpl<Integer>> for Range
sourcefn from(value: IntegerRange) -> Self
fn from(value: IntegerRange) -> Self
Converts to this type from the input type.
sourceimpl From<RangeImpl<Number>> for Range
impl From<RangeImpl<Number>> for Range
sourcefn from(value: NumberRange) -> Self
fn from(value: NumberRange) -> Self
Converts to this type from the input type.
sourceimpl From<RangeImpl<Timestamp>> for Range
impl From<RangeImpl<Timestamp>> for Range
sourcefn from(value: TimestampRange) -> Self
fn from(value: TimestampRange) -> Self
Converts to this type from the input type.
sourceimpl From<RangeImpl<TimestampPrecision>> for Range
impl From<RangeImpl<TimestampPrecision>> for Range
sourcefn from(value: TimestampPrecisionRange) -> Self
fn from(value: TimestampPrecisionRange) -> Self
Converts to this type from the input type.
sourceimpl From<RangeImpl<f64>> for Range
impl From<RangeImpl<f64>> for Range
sourcefn from(value: FloatRange) -> Self
fn from(value: FloatRange) -> Self
Converts to this type from the input type.
sourceimpl From<RangeImpl<usize>> for Range
impl From<RangeImpl<usize>> for Range
sourcefn from(value: NonNegativeIntegerRange) -> Self
fn from(value: NonNegativeIntegerRange) -> Self
Converts to this type from the input type.
sourceimpl PartialEq<Range> for Range
impl PartialEq<Range> for Range
impl StructuralPartialEq for Range
Auto Trait Implementations
impl RefUnwindSafe for Range
impl Send for Range
impl Sync for Range
impl Unpin for Range
impl UnwindSafe for Range
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more