HorizontalPodAutoscalerSpec.fromJson constructor
Creates a HorizontalPodAutoscalerSpec from JSON data.
Implementation
HorizontalPodAutoscalerSpec.fromJson(Map<String, dynamic> json)
: this(
behavior: json['behavior'] != null
? HorizontalPodAutoscalerBehavior.fromJson(json['behavior'])
: null,
maxReplicas: json['maxReplicas'],
metrics: json['metrics'] != null
? MetricSpec.listFromJson(
(json['metrics'] as Iterable).cast<Map<String, dynamic>>())
: null,
minReplicas: json['minReplicas'],
scaleTargetRef:
CrossVersionObjectReference.fromJson(json['scaleTargetRef']),
);