asDataProvider method
Implementation
FutureOr<raw.DataProvider> asDataProvider() {
final representations = <raw.DataRepresentation>[];
for (final data in this.data) {
if (data is Future) {
return _asDataProviderAsync();
}
for (final representation in data.representations) {
representations.add(representation);
}
}
return raw.DataProvider(
representations: representations,
suggestedName: suggestedName,
);
}