LeanGenerator class

Annotation for defining a code generator.

Classes annotated with LeanGenerator will be used to generate code during the build process. Generators typically transform input files into output files with specified extensions.

Annotations
  • @Target(<TargetKind>{TargetKind.classType})

Constructors

LeanGenerator.new(Set<String> outputExtensions, {String? key, bool? allowSyntaxErrors, bool? generateToCache, Set<Type>? registerTypes, Set<String>? generateFor, Set<String>? runsBefore, Map<String, dynamic>? options, Set<String>? applies})
Creates a generator that's used by LibraryBuilder
const
LeanGenerator.shared({String? key, bool? allowSyntaxErrors, Set<String>? applies, Set<Type>? registerTypes, Set<String>? generateFor, Set<String>? runsBefore, Map<String, dynamic>? options})
Creates a generator that's used by SharedPartBuilder
const

Properties

allowSyntaxErrors bool?
Whether to continue processing even when syntax errors are present.
final
applies Set<String>?
Builder keys that this generator applies to.
final
generateFor Set<String>?
Glob patterns specifying which files this generator should process.
final
generateToCache bool?
Whether output should be cached. If true, the generator's output will be stored in the build cache.
final
hashCode int
The hash code for this object.
no setterinherited
key String?
Optional unique identifier for this generator.
final
options Map<String, dynamic>?
Additional configuration options for this generator.
final
outputExtensions Set<String>
File extensions this generator will produce.
final
registerTypes Set<Type>?
The Types this builder intends to uses for type checking.
final
runsBefore Set<String>?
Generator keys that should run before this generator.
final
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