pub struct Keyed<T>(pub T);
Expand description
A NewType style struct which marks the inner element is created with
Keyed<T>
doesn’t need to impl Node
as it’s not necessary to assign keys for direct child nodes.
Vec<Keyed<T>>
and Vec<Option<Keyed<T>>>
(and also corresponding slices and arrays)
impl Node
as long as T
impl [IntoElement
],
so that list of keyed elements can be used as child nodes.
Tuple Fields
0: T
Implementations
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for Keyed<T> where
T: RefUnwindSafe,
impl<T> Send for Keyed<T> where
T: Send,
impl<T> Sync for Keyed<T> where
T: Sync,
impl<T> Unpin for Keyed<T> where
T: Unpin,
impl<T> UnwindSafe for Keyed<T> where
T: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
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
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more