ResourceClaimSchedulingStatus.fromJson constructor

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

Creates a ResourceClaimSchedulingStatus from JSON data.

Implementation

factory ResourceClaimSchedulingStatus.fromJson(Map<String, dynamic> json) {
  final tempNameJson = json['name'];
  final tempUnsuitableNodesJson = json['unsuitableNodes'];

  final String? tempName = tempNameJson;
  final List<String>? tempUnsuitableNodes = tempUnsuitableNodesJson != null
      ? List<String>.from(tempUnsuitableNodesJson)
      : null;

  return ResourceClaimSchedulingStatus(
    name: tempName,
    unsuitableNodes: tempUnsuitableNodes,
  );
}