pub struct RwSignal<T: 'static> { /* private fields */ }Implementations§
Source§impl<T: 'static> RwSignal<T>
impl<T: 'static> RwSignal<T>
pub fn set(&self, value: T)
pub fn update(&self, f: impl FnOnce(&mut T))
pub fn with<R>(&self, f: impl FnOnce(&T) -> R) -> R
Sourcepub fn peek_with<R>(&self, f: impl FnOnce(&T) -> R) -> R
pub fn peek_with<R>(&self, f: impl FnOnce(&T) -> R) -> R
As with, but does not subscribe the caller — for reads from an event handler, where
tracking would attach the value to whatever effect happens to be running.
pub fn read_only(&self) -> ReadSignal<T>
Trait Implementations§
Auto Trait Implementations§
impl<T> Freeze for RwSignal<T>
impl<T> RefUnwindSafe for RwSignal<T>where
T: RefUnwindSafe,
impl<T> Send for RwSignal<T>where
T: Send,
impl<T> Sync for RwSignal<T>where
T: Sync,
impl<T> Unpin for RwSignal<T>where
T: Unpin,
impl<T> UnsafeUnpin for RwSignal<T>
impl<T> UnwindSafe for RwSignal<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