BaseGenerator class abstract

Base contract for all code and structure generators.

Implementers

Constructors

BaseGenerator({required FileManager fileManager, required ProjectConfig config, Directory? projectDir, bool dryRun = false, bool force = false, bool skipExisting = false})

Properties

config → ProjectConfig
final
dryRun → bool
final
fileManager → FileManager
final
force → bool
final
hashCode → int
The hash code for this object.
no setterinherited
packageName → String
Retrieves the Flutter app package name from pubspec.yaml.
no setter
projectDir → Directory
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
skipExisting → bool
final

Methods

generate() → Future<List<FileGenerationResult>>
Executes the generator.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
renderAndWrite({required String relativePath, required String templateName, required String defaultContent, required Map<String, dynamic> context}) → FileGenerationResult
Helper to render and safely write a template.
toString() → String
A string representation of this object.
inherited

Operators

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