StatefulSetStatus.fromJson constructor
Creates a StatefulSetStatus from JSON data.
Implementation
factory StatefulSetStatus.fromJson(Map<String, dynamic> json) {
final tempAvailableReplicasJson = json['availableReplicas'];
final tempCollisionCountJson = json['collisionCount'];
final tempConditionsJson = json['conditions'];
final tempCurrentReplicasJson = json['currentReplicas'];
final tempCurrentRevisionJson = json['currentRevision'];
final tempObservedGenerationJson = json['observedGeneration'];
final tempReadyReplicasJson = json['readyReplicas'];
final tempReplicasJson = json['replicas'];
final tempUpdateRevisionJson = json['updateRevision'];
final tempUpdatedReplicasJson = json['updatedReplicas'];
final int? tempAvailableReplicas = tempAvailableReplicasJson;
final int? tempCollisionCount = tempCollisionCountJson;
final List<StatefulSetCondition>? tempConditions =
tempConditionsJson != null
? List<dynamic>.from(tempConditionsJson)
.map(
(e) => StatefulSetCondition.fromJson(
Map<String, dynamic>.from(e),
),
)
.toList()
: null;
final int? tempCurrentReplicas = tempCurrentReplicasJson;
final String? tempCurrentRevision = tempCurrentRevisionJson;
final int? tempObservedGeneration = tempObservedGenerationJson;
final int? tempReadyReplicas = tempReadyReplicasJson;
final int tempReplicas = tempReplicasJson;
final String? tempUpdateRevision = tempUpdateRevisionJson;
final int? tempUpdatedReplicas = tempUpdatedReplicasJson;
return StatefulSetStatus(
availableReplicas: tempAvailableReplicas,
collisionCount: tempCollisionCount,
conditions: tempConditions,
currentReplicas: tempCurrentReplicas,
currentRevision: tempCurrentRevision,
observedGeneration: tempObservedGeneration,
readyReplicas: tempReadyReplicas,
replicas: tempReplicas,
updateRevision: tempUpdateRevision,
updatedReplicas: tempUpdatedReplicas,
);
}