pub trait SignalGet<T: Clone> {
// Required method
fn id(&self) -> Id;
// Provided methods
fn get_untracked(&self) -> T
where T: 'static { ... }
fn get(&self) -> T
where T: 'static { ... }
fn try_get(&self) -> Option<T>
where T: 'static { ... }
fn try_get_untracked(&self) -> Option<T>
where T: 'static { ... }
}
Required Methods§
Provided Methods§
Sourcefn get_untracked(&self) -> Twhere
T: 'static,
fn get_untracked(&self) -> Twhere
T: 'static,
Clones and returns the current value stored in the Signal, but it doesn’t subscribe to the current running effect.
Sourcefn get(&self) -> Twhere
T: 'static,
fn get(&self) -> Twhere
T: 'static,
Clones and returns the current value stored in the Signal, and subscribes to the current running effect to this Signal.
Sourcefn try_get(&self) -> Option<T>where
T: 'static,
fn try_get(&self) -> Option<T>where
T: 'static,
Try to clone and return the current value stored in the Signal, and returns None if it’s already disposed. It subscribes to the current running effect.
Sourcefn try_get_untracked(&self) -> Option<T>where
T: 'static,
fn try_get_untracked(&self) -> Option<T>where
T: 'static,
Try to clone and return the current value stored in the Signal, and returns None if it’s already disposed. It doesn’t subscribe to the current running effect.