LiveStateFields class

Reads the fields a developer declared on the state metro live:run data described.

A Flutter app has no reflection, so the app itself can't enumerate them. Instead state.data leaves the state object in a top-level variable and says where, and this reads it back over the VM service: the variable, then the object's fields, keeping only those the state class declares itself. Each value is then encoded by the app, through the same JSON encoder every other live command uses, so models and dates come back as real JSON.

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

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

read(LiveApp app, Map<String, Object?> inspect, {Duration? timeout}) → Future<List<LiveStateField>>
Reads the fields of the state the app captured, described by the inspect block of a state.data reply.