WidgetClassGlobalDependencies class

Tracks which global resources a widget class actually uses.

This is used during graph building to determine the edges from widget class nodes to global dependency nodes.

Granular Tracking

Where possible, this class tracks specific resource keys rather than just boolean flags. This enables more precise incremental regeneration:

  • appStateVariableKeys: Specific app state variables used
  • apiCallKeys: Specific API endpoint keys used
  • actionBlockKeys: Specific action block keys used
  • customFunctionKeys: Specific custom function keys used
  • customWidgetKeys: Specific custom widget keys used
  • customActionKeys: Specific custom action keys used
  • dataStructKeys: Specific data struct keys used
  • enumKeys: Specific enum keys used

The boolean usesXxx properties are computed from these sets for backwards compatibility.

Constructors

WidgetClassGlobalDependencies.analyze(FFWidgetClass widgetClass)
Analyze a widget class node to determine its actual global dependencies.
factory
WidgetClassGlobalDependencies.testInstance()
Creates a test instance with all fields at defaults.
factory

Properties

actionBlockKeys Set<String>
Specific action block keys this widget class uses. Empty set means no action blocks are used.
getter/setter pair
actionBlockParamPasses Map<String, Set<String>>
Map of action block keys → param keys passed. Enables queries like "what passes userId to submitForm action block?"
getter/setter pair
allLibraryProjectIds Set<String>
All unique library project IDs referenced by this widget class.
no setter
apiCallKeys Set<String>
Specific API endpoint keys this widget class uses. Empty set means no API calls are used.
getter/setter pair
appConstantKeys Set<String>
Specific app constant keys this widget class uses. Empty set means no app constants are used.
getter/setter pair
appEventKeys Set<String>
Specific app event keys this widget class uses. Empty set means no app events are used.
getter/setter pair
appStateVariableKeys Set<String>
Specific app state variable keys this widget class uses. Empty set means no app state variables are used.
getter/setter pair
assetAudioPaths Set<String>
Audio asset paths this widget class uses (ASSET type only). Empty set means no audio assets are used.
getter/setter pair
assetFontNames Set<String>
Custom font family names this widget class uses. Note: These need to be filtered against project.theme.customFonts to exclude system fonts.
getter/setter pair
assetIconFamilies Set<String>
Custom icon family names this widget class uses (is_custom = true only). Empty set means no custom icons are used.
getter/setter pair
assetImagePaths Set<String>
Image asset paths this widget class uses (ASSET type only). Empty set means no image assets are used.
getter/setter pair
assetLottiePaths Set<String>
Lottie animation asset paths this widget class uses (ASSET source only). Empty set means no Lottie assets are used.
getter/setter pair
assetVideoPaths Set<String>
Video asset paths this widget class uses (ASSET type only). Empty set means no video assets are used.
getter/setter pair
customActionKeys Set<String>
Specific custom action keys this widget class uses. Empty set means no custom actions are used.
getter/setter pair
customFunctionKeys Set<String>
Specific custom function keys this widget class uses. Empty set means no custom functions are used.
getter/setter pair
customWidgetKeys Set<String>
Specific custom widget keys this widget class uses. Empty set means no custom widgets are used.
getter/setter pair
dataStructFieldAccesses Map<String, Set<String>>
Map of struct keys → field keys accessed. Enables queries like "what uses UserStruct.email field?"
getter/setter pair
dataStructKeys Set<String>
Specific data struct keys this widget class uses. Empty set means no data structs are used.
getter/setter pair
enumKeys Set<String>
Specific enum keys this widget class uses. Empty set means no enums are used.
getter/setter pair
firestoreCollectionKeys Set<String>
Specific Firestore collection keys this widget class uses. Empty set means no Firestore collections are used.
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
hasNavigationTargets bool
Whether this widget class has navigation targets.
no setter
hasSheetDialogComponents bool
Whether this widget class shows components in bottom sheets/dialogs.
no setter
libraryBottomSheetProjectIds Set<String>
Library project IDs referenced via bottom sheet actions.
getter/setter pair
libraryComponentProjectIds Set<String>
Library project IDs referenced via component instances in the widget tree.
getter/setter pair
libraryCustomDialogProjectIds Set<String>
Library project IDs referenced via custom dialog actions.
getter/setter pair
libraryNavigationProjectIds Set<String>
Library project IDs referenced via navigation actions.
getter/setter pair
Page keys this widget class navigates to via actions. Empty set means no navigation targets.
getter/setter pair
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
sheetDialogComponentKeys Set<String>
Component keys this widget class shows in bottom sheets or custom dialogs. Empty set means no bottom sheet/dialog components.
getter/setter pair
supabaseTableKeys Set<String>
Specific Supabase/Postgres table keys this widget class uses. Empty set means no Supabase tables are used.
getter/setter pair
usesActionBlocks bool
Whether this widget class uses any action blocks.
no setter
usesApiCalls bool
Whether this widget class uses any API calls.
no setter
usesAppConstants bool
Whether this widget class uses any app constants.
no setter
usesAppEvents bool
Whether this widget class uses any app events.
no setter
usesAppState bool
Whether this widget class uses any app state variables.
no setter
usesAssetAudio bool
Whether this widget class uses any audio assets.
no setter
usesAssetFonts bool
Whether this widget class uses any custom fonts.
no setter
usesAssetIcons bool
Whether this widget class uses any custom icons.
no setter
usesAssetImages bool
Whether this widget class uses any image assets.
no setter
usesAssetLottie bool
Whether this widget class uses any Lottie assets.
no setter
usesAssetVideos bool
Whether this widget class uses any video assets.
no setter
usesCustomActions bool
Whether this widget class uses any custom actions.
no setter
usesCustomCode bool
Whether this widget class uses any custom code. This includes custom functions, custom widgets, and custom actions. Note: API calls are tracked separately via usesApiCalls.
no setter
usesCustomFunctions bool
Whether this widget class uses any custom functions.
no setter
usesCustomWidgets bool
Whether this widget class uses any custom widgets.
no setter
usesDataSchema bool
Whether this widget class uses any data schema. This is the aggregate of data structs, enums, Firestore collections, and Supabase tables.
no setter
usesDataStructFields bool
Whether this widget class accesses any data struct fields.
no setter
usesDataStructs bool
Whether this widget class uses any data structs.
no setter
usesEnums bool
Whether this widget class uses any enums.
no setter
usesFirestoreCollections bool
Whether this widget class uses any Firestore collections.
no setter
usesLibraries bool
Whether this widget class references any library projects.
no setter
usesSupabaseTables bool
Whether this widget class uses any Supabase tables.
no setter
usesTheme bool
getter/setter pair

Methods

applyToGraph(ProjectGraph graph, String nodeId) → void
Apply these global dependencies to the graph for the given node.
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