export method
Converts an object of type List<num>
to a String
.
label
: An optional label as first row.delimiter
: Delimiter used to separate numerical values.precision
: Precision used when converting numbers toString
.
Implementation
String export({
String label = '',
String delimiter = ' ',
int precision = 20,
}) {
final b = StringBuffer();
if (label.isNotEmpty) b.writeln(label);
for (var i = 0; i < length; ++i) {
b.writeln('${this[i].toStringAsPrecision(precision)}$delimiter');
}
return b.toString();
}