castJson static method
Implementation
static Curve castJson(Map<String, dynamic> json) {
String type = json["type"];
if (type == "Shape") {
return Shape.fromJson(json);
} else if (type == "Curve") {
return Curve.fromJson(json);
} else if (type == "LineCurve") {
return LineCurve.fromJson(json);
} else {
throw " type: $type Curve.castJSON is not support yet... ";
}
}