fromMap static method

StatisticalValue? fromMap(
  1. Map<String, dynamic>? _map
)
override

Construct from Map.

Implementation

static StatisticalValue? fromMap(Map<String, dynamic>? _map) {
  if (_map == null) return null;
  var _ = _map["@type"];
  if (_ != CONSTRUCTOR) return null;
  var extra = _map['@extra'];
  var clientId = _map['@clientId'];
  var value = _map['value']! as double;
  var previous_value = _map['previous_value']! as double;
  var growth_rate_percentage = _map['growth_rate_percentage']! as double;
  return StatisticalValue(
    extra: extra,
    clientId: clientId,
    value: value,
    previous_value: previous_value,
    growth_rate_percentage: growth_rate_percentage,
  );
}