pub trait Reactive<T>:
Clone
+ Send
+ Sync
+ 'static{
// Required methods
fn get(&self) -> T;
fn subscribe_with_source<F>(&self, callback: F) -> SignalSubscription
where F: Fn(T, Option<Uuid>) + Send + Sync + 'static;
// Provided methods
fn subscribe<F>(&self, callback: F) -> SignalSubscription
where F: Fn(T) + Send + Sync + 'static { ... }
fn keepalive(&self) -> Option<Arc<dyn Send + Sync>> { ... }
}Required Methods§
fn get(&self) -> T
fn subscribe_with_source<F>(&self, callback: F) -> SignalSubscription
Provided Methods§
fn subscribe<F>(&self, callback: F) -> SignalSubscription
fn keepalive(&self) -> Option<Arc<dyn Send + Sync>>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".