pub enum Asymmetric {
Anything,
Any(TypeTag),
ArrayContaining(Vec<Value>),
ObjectContaining(Map<String, Value>),
StringContaining(String),
StringMatching(StringOrRegex),
CloseTo {
value: f64,
digits: u8,
},
Not(Box<Asymmetric>),
}Variants§
Anything
Any(TypeTag)
ArrayContaining(Vec<Value>)
ObjectContaining(Map<String, Value>)
StringContaining(String)
StringMatching(StringOrRegex)
CloseTo
Not(Box<Asymmetric>)
Implementations§
Source§impl Asymmetric
impl Asymmetric
Sourcepub fn from_value(v: &Value) -> Option<Asymmetric>
pub fn from_value(v: &Value) -> Option<Asymmetric>
Decode from a tagged JSON object. Returns None for any value
that is not a properly tagged asymmetric.
pub fn matches(&self, actual: &Value) -> bool
pub fn description(&self) -> String
Trait Implementations§
Source§impl Clone for Asymmetric
impl Clone for Asymmetric
Source§fn clone(&self) -> Asymmetric
fn clone(&self) -> Asymmetric
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for Asymmetric
impl RefUnwindSafe for Asymmetric
impl Send for Asymmetric
impl Sync for Asymmetric
impl Unpin for Asymmetric
impl UnsafeUnpin for Asymmetric
impl UnwindSafe for Asymmetric
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more