RxCompositeMap<K, V extends Rx> class

Composite version of RxMap that notifies when elements do

Note that keeping track of element streams is not free, and a lot of operations are done multiple times

Inheritance
Mixed in types
Available Extensions

Constructors

RxCompositeMap([Map<K, V>? value])
Constructor

Properties

entries Iterable<MapEntry<K, V>>
The map entries of this.
no setterinherited
hashCode int
The hash code for this object.
no setterinherited
isEmpty bool
Whether there is no key/value pair in the map.
no setterinherited
isNotEmpty bool
Whether there is at least one key/value pair in the map.
no setterinherited
keys Iterable<K>
The keys of this.
no setterinherited
length int
The number of key/value pairs in the map.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stream Stream<Map<K, V>>
Stream of value changes
no setterinherited
unregisteredValue Map<K, V>
Read the current value without calling register
no setterinherited
value Map<K, V>
Get the current value and register with the current zone's RxRegistrar
getter/setter pairinherited
values Iterable<V>
The values of this.
no setterinherited

Methods

addAll(Map<K, V> other) → void
Adds all key/value pairs of other to this map.
override
addEntries(Iterable<MapEntry<K, V>> newEntries) → void
Adds all key/value pairs of newEntries to this map.
inherited
addRx(Rx rx) → void
Add an Rx to this composite
inherited
cast<RK, RV>() Map<RK, RV>
Provides a view of this map as having RK keys and RV instances, if necessary.
inherited
clear() → void
Removes all entries from the map.
override
containsKey(Object? key) bool
Whether this map contains the given key.
inherited
containsValue(Object? value) bool
Whether this map contains the given value.
inherited
copyValue() Map<K, V>
Copy the value for update emission
inherited
forEach(void action(K key, V value)) → void
Applies action to each key/value pair of the map.
inherited
hasStream(int id) bool
Check if an Rx stream is registered for testing
inherited
internalSetValue(Map<K, V> value) → void
Internal setter for _value. Should only be used in Rx extensions and never externally. Does not notify.
inherited
map<K2, V2>(MapEntry<K2, V2> convert(K key, V value)) Map<K2, V2>
Returns a new map where all entries of this map are transformed by the given convert function.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notify() → void
Notify listeners with the current value
inherited
notifyIfChanged<U>(U transform()) → U
Notify if transform changed the value such that shouldNotify returns true
inherited
notifyWithValue(Map<K, V> value) → void
Notify listeners with the given value
inherited
putIfAbsent(K key, V ifAbsent()) → V
Look up the value of key, or add a new entry if it isn't there.
override
register() → void
Register with the current zone's RxRegistrar if it exists
inherited
remove(Object? key) → V?
Removes key and its associated value, if present, from the map.
override
removeRx(Rx rx) → void
Remove an Rx from this composite
inherited
removeWhere(bool test(K key, V value)) → void
Removes all entries of this map that satisfy the given test.
override
replaceAll(Map<K, V> elements) → void
Convenience method to replace all current elements with elements
override
run(RxAction action, {bool notify = true}) bool
Run action with registration and notifications disabled. Will notify after action is completed if notify is true and the child implementation decides a notification should be sent.
inherited
shouldNotify(Map<K, V> oldValue) bool
Check if the value has changed
inherited
toString() String
A string representation of this object.
inherited
update(K key, V update(V value), {V ifAbsent()?}) → V
Updates the value for the provided key.
override
updateAll(V update(K key, V value)) → void
Updates all values.
override

Operators

operator ==(Object other) bool
Returns true if both RxValue values are equal
inherited
operator [](Object? key) → V?
The value for the given key, or null if key is not in the map.
inherited
operator []=(K key, V value) → void
Associates the key with the given value.
override