BrownfieldPatternTarget class final
Public app-level locator for semantic brownfield patterns.
Prefer selectors derived from a fresh inspect snapshot. Use byKey when you truly need an exact existing node. Use structural selectors like byType, byName, or slot when you want rerun-stable targeting across regenerated keys.
Example:
final cta = BrownfieldPatternTarget.singleExistingButton();
final search = BrownfieldPatternTarget.byName('SearchField');
final appBarSlot = BrownfieldPatternTarget.slot('appBar');
- Annotations
-
- @immutable
Constructors
- BrownfieldPatternTarget.byKey(String key)
-
Targets one exact existing widget key from brownfield inspect output.
factory
- BrownfieldPatternTarget.byName(String name)
-
Targets an existing widget by its DSL/widget
name:.factory - BrownfieldPatternTarget.byPath(String path)
-
Targets an existing widget by its deterministic tree path.
factory
- BrownfieldPatternTarget.byText(String text)
-
Targets existing widgets by visible text.
factory
- BrownfieldPatternTarget.byType(String type)
-
Targets existing widgets by FlutterFlow widget type name.
factory
- BrownfieldPatternTarget.singleExistingButton()
-
Stable shorthand for the common case where a page has exactly one button.
factory
- BrownfieldPatternTarget.singleExistingTextField()
-
Stable shorthand for the common case where a page has exactly one text field.
factory
- BrownfieldPatternTarget.slot(String slotName)
-
Targets a named structural slot such as
appBaror an insertion slot.factory
Properties
Methods
-
describe(
) → String -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toSelection(
BrownfieldWidgetEditor editor) → BrownfieldSelection -
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited