pub struct GenSignal<T: 'static> { /* private fields */ }
Trait Implementations§
type Value = T
fn try_unwrap(self) -> Result<Self::Value, Self>where
Self: Sized,
fn get(&self) -> Twhere
T: Copy,
fn get_cloned(&self) -> Twhere
T: Clone,
fn map<R>(&self, f: impl FnOnce(&T) -> R) -> R
fn map_mut<R>(&self, f: impl FnOnce(&mut T) -> R) -> R
Source§fn equivalent_to(&self, other: &Self) -> bool
fn equivalent_to(&self, other: &Self) -> bool
Returns
true
if self
and other
are sharing values from the same allocation.
In that case, self
and other
are equivalent to each other
because calling the same method on either of them leads to the same result.fn unwrap_or_get_cloned(self) -> Self::Value
fn set(&self, new_value: Self::Value)
Source§impl<T> Signal for GenSignal<T>
impl<T> Signal for GenSignal<T>
type SignalHook = GenSignalHook<T>
fn is_signal_of(&self, signal_hook: &Self::SignalHook) -> bool
Source§fn to_signal_hook(&self) -> Self::SignalHook
fn to_signal_hook(&self) -> Self::SignalHook
This is the opposite of
SignalHook::to_signal
.fn update_signal_hook(&self, hook: Pin<&mut Self::SignalHook>)
fn h_signal_hook<'hook>( &self, hook: Pin<&'hook mut <Self::SignalHook as SignalHook>::SignalHookUninitialized>, ) -> Value<'hook, Self::SignalHook>
fn notify_changed(&self)
fn map_mut_and_notify_if<R>( &self, f: impl FnOnce(&mut Self::Value) -> (R, bool), ) -> R
fn use_signal(&self) -> UseSignal<'_, Self>
impl<T: 'static> Copy for GenSignal<T>
impl<T: 'static> Eq for GenSignal<T>
Auto Trait Implementations§
impl<T> Freeze for GenSignal<T>
impl<T> !RefUnwindSafe for GenSignal<T>
impl<T> !Send for GenSignal<T>
impl<T> !Sync for GenSignal<T>
impl<T> Unpin for GenSignal<T>
impl<T> !UnwindSafe for GenSignal<T>
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