StateDiscoverer class
Discovers live state holders inside the connected app isolate.
Two strategies are used, because neither is available everywhere:
- Native (VM desktop / mobile):
getClassList+getInstancesfinds live objects whose class name looks like state. Also scans top-level library variables. - Flutter Web: neither RPC exists (and
dart:mirrorsis unavailable), so enumeration is impossible. Callers must instead name the holders and have them probed with probeExpressions.
Constructors
- StateDiscoverer(VmBridge _bridge)
- Creates a discoverer bound to the connected VM bridge.
Properties
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
discoverStateHolders(
) → Future< List< Map< >String, dynamic> > - Returns holders found by class name and by root-library variables.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
probeExpressions(
List< String> expressions, {String? libraryUri}) → Future<List< Map< >String, dynamic> > - Probes caller-supplied expressions and reports each value.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited