pub struct KeyFn<T: 'static, K: 'static>(pub Rc<dyn Fn(&T) -> K + 'static>);Expand description
Fn(&T) -> K — the “key extractor” closure for a keyed-list
control flow. Items whose keys match across reactive reruns
reuse their owners + per-item state.
Tuple Fields§
§0: Rc<dyn Fn(&T) -> K + 'static>Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<T, K> !RefUnwindSafe for KeyFn<T, K>
impl<T, K> !Send for KeyFn<T, K>
impl<T, K> !Sync for KeyFn<T, K>
impl<T, K> !UnwindSafe for KeyFn<T, K>
impl<T, K> Freeze for KeyFn<T, K>
impl<T, K> Unpin for KeyFn<T, K>
impl<T, K> UnsafeUnpin for KeyFn<T, K>
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