BodyTransformer class

Rewrites method bodies from mutable ChangeNotifier/BLoC style to immutable Riverpod state-update style using regex-based pattern substitution.

Handles .add, .addAll, .remove, .removeWhere, .clear, assignment (=, +=, -=), increment/decrement (++, --), null-coalescing assignment (??=), and notifyListeners() / emit() removal.

Constructors

BodyTransformer()

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
transformBody(String body, List<FieldInfo> stateFields) String
Transform a method body from ChangeNotifier mutation style to Riverpod state-update style.

Operators

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