fromJson static method

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

Implementation

static Requirement fromJson(Map<String, dynamic> json) {
  if (json["toolkit"] != null) {
    return RequiredToolkit.fromJson(json);
  } else if (json["schema"] != null) {
    return RequiredSchema.fromJson(json);
  }
  throw Exception("Unexpected requirement");
}