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> Freeze for Keyed<T>where
T: Freeze,
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§
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