Code class

a String representing a piece of Dart code

Inheritance
Implementers

Constructors

Code.new(String code)

Properties

code String
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

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toFormattedString({String? lineEnding, int? pageWidth, int? indent, List<String>? experimentFlags}) String
Converts the CodeNode to a formatted String, using the constructor parameters. Using the official (dartfmt)https://github.com/dart-lang/dart_style/wiki/Formatting-Rules with the dart_style package Note that this formatter may throw parsing exceptions. You can use the toUnFormattedString method when you need a code partial that can not be parsed by the Dart formatter
inherited
toString() String
A string representation of this object.
inherited
toUnFormattedString(Imports imports) String
Converts the CodeNode to an unformatted String. It should not throw parsing exceptions.
override

Operators

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