FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    IConnectableCache

    trait · ferroui-dynamic-data · v0.5.0

    trait IConnectableCache<T, K>
    

    A cache that can be observed (IConnectableCache<TObject, TKey>).

    View source

    Members

    count_changed

    fn count_changed(self: &Self) -> Rc<dyn IObservable<usize>>
    

    The number of items, now and whenever it changes (CountChanged).

    Source

    connect_with

    fn connect_with(self: &Self, predicate: Option<Rc<dyn Fn(&T) -> bool>>, suppress_empty_change_sets: bool) -> Rc<dyn IObservable<ChangeSet<T, K>>>
    

    The items as additions, then the changes, of the items that predicate accepts; empty change sets are left out unless suppress_empty_change_sets is false (Connect).

    Source

    preview_with

    fn preview_with(self: &Self, predicate: Option<Rc<dyn Fn(&T) -> bool>>) -> Rc<dyn IObservable<ChangeSet<T, K>>>
    

    The changes before they are applied, while the items are as they were (Preview).

    Source

    watch

    fn watch(self: &Self, key: K) -> Rc<dyn IObservable<Change<T, K>>>
    

    The changes of the item of key (Watch).

    Source

    connect

    fn connect(self: &Self) -> Rc<dyn IObservable<ChangeSet<T, K>>>
    

    The items and their changes (Connect()).

    Source

    connect_filtered

    fn connect_filtered(self: &Self, predicate: impl Fn(&T) -> bool + 'static) -> Rc<dyn IObservable<ChangeSet<T, K>>>
    where Self: Sized
    

    The items that predicate accepts and their changes (Connect(Func<TObject, bool>)).

    Source

    preview

    fn preview(self: &Self) -> Rc<dyn IObservable<ChangeSet<T, K>>>
    

    The changes before they are applied (Preview()).

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.