GoogleCloudRetailV2Rating.fromJson constructor

GoogleCloudRetailV2Rating.fromJson(
  1. Map json_
)

Implementation

GoogleCloudRetailV2Rating.fromJson(core.Map json_)
    : this(
        averageRating: json_.containsKey('averageRating')
            ? (json_['averageRating'] as core.num).toDouble()
            : null,
        ratingCount: json_.containsKey('ratingCount')
            ? json_['ratingCount'] as core.int
            : null,
        ratingHistogram: json_.containsKey('ratingHistogram')
            ? (json_['ratingHistogram'] as core.List)
                .map((value) => value as core.int)
                .toList()
            : null,
      );