DartSourceRenderer class
Emits and formats Dart source in memory.
Constructors
- DartSourceRenderer({DartCodeBuilder codeBuilder = const DefaultDartCodeBuilder()})
-
Uses codeBuilder to build each library before formatting.
const
Properties
- codeBuilder → DartCodeBuilder
-
Builds the syntax tree before formatting.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
formatSource(
String source, GenerationConfig config) → String - Formats a library with the selected output width.
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
render(
PlannedDartFile file, GenerationConfig config) → GeneratedFile - Renders one planned file with the specified formatting options.
-
renderAdditionalFiles(
GenerationPlan plan, GenerationConfig config) → Iterable< GeneratedFile> - Renders extra files after the planned libraries. Empty by default. Paths must be unique across both sets of files.
-
toString(
) → String -
A string representation of this object.
inherited
-
validatePlan(
GenerationPlan plan) → void - Checks the file plan before rendering starts.
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited