GetUsageAndQuotaResult.fromJson constructor

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

Implementation

factory GetUsageAndQuotaResult.fromJson(Map<String, dynamic> json) {
  return GetUsageAndQuotaResult(
    usage: json['usage'] as num,
    quota: json['quota'] as num,
    overrideActive: json['overrideActive'] as bool? ?? false,
    usageBreakdown: (json['usageBreakdown'] as List)
        .map((e) => UsageForType.fromJson(e as Map<String, dynamic>))
        .toList(),
  );
}