report method
Future<void>
report(
- Iterable<
UnusedCodeFileReport> records, { - Iterable<
void> summary = const [], - UnusedCodeReportParams? additionalParams,
override
Implementation
@override
Future<void> report(
Iterable<UnusedCodeFileReport> records, {
Iterable<void> summary = const [],
UnusedCodeReportParams? additionalParams,
}) async {
if (records.isEmpty) {
return;
}
final encodedReport = json.encode({
'formatVersion': formatVersion,
'timestamp': getTimestamp(),
'unusedCode': records.map(_unusedCodeFileReportToJson).toList(),
});
output.write(encodedReport);
}