ItemCollectionMetrics.fromJson constructor

ItemCollectionMetrics.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory ItemCollectionMetrics.fromJson(Map<String, dynamic> json) {
  return ItemCollectionMetrics(
    itemCollectionKey: (json['ItemCollectionKey'] as Map<String, dynamic>?)
        ?.map((k, e) =>
            MapEntry(k, AttributeValue.fromJson(e as Map<String, dynamic>))),
    sizeEstimateRangeGB: (json['SizeEstimateRangeGB'] as List?)
        ?.whereNotNull()
        .map((e) => e as double)
        .toList(),
  );
}