toJson method
Converts the TimeDistanceMatrix to a Map having String keys 'durations', 'destinations', and 'sources'.
Implementation
Map<String, dynamic> toJson() => <String, dynamic>{
'durations': durations,
'destinations': destinations
.map<Map<String, dynamic>>(
(TimeDistanceMatrixLocation e) => e.toJson())
.toList(),
'sources': sources
.map<Map<String, dynamic>>(
(TimeDistanceMatrixLocation e) => e.toJson())
.toList(),
};