pub struct UnknownPayload<U> { /* private fields */ }Expand description
A payload of the open union U whose tag U does not list, as it arrived. Built only by
UnknownPayload::from_payload.
Implementations§
Source§impl<U: OpenUnion> UnknownPayload<U>
impl<U: OpenUnion> UnknownPayload<U>
Sourcepub fn from_payload(value: Value) -> Option<Self>
pub fn from_payload(value: Value) -> Option<Self>
value as U’s catch-all: None where it is not an object, its tag property is missing
or not a string, or U lists the tag.
Trait Implementations§
Source§impl<U> Clone for UnknownPayload<U>
impl<U> Clone for UnknownPayload<U>
Source§impl<U> Debug for UnknownPayload<U>
impl<U> Debug for UnknownPayload<U>
Source§impl<U> PartialEq for UnknownPayload<U>
impl<U> PartialEq for UnknownPayload<U>
Auto Trait Implementations§
impl<U> Freeze for UnknownPayload<U>
impl<U> RefUnwindSafe for UnknownPayload<U>
impl<U> Send for UnknownPayload<U>
impl<U> Sync for UnknownPayload<U>
impl<U> Unpin for UnknownPayload<U>
impl<U> UnsafeUnpin for UnknownPayload<U>
impl<U> UnwindSafe for UnknownPayload<U>
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> CompatExt for T
impl<T> CompatExt for T
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
Create a new handle for an Arc value Read more
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
Clone a handle Read more
§unsafe fn consume_handle(handle: Handle) -> Arc<T> ⓘ
unsafe fn consume_handle(handle: Handle) -> Arc<T> ⓘ
Consume a handle, getting back the initial
Arc<> Read more§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§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