toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final Map<String, dynamic> data = new Map<String, dynamic>();
  data['ellipse'] = this.ellipse;
  data['height'] = this.height;
  data['id'] = this.id;
  data['name'] = this.name;
  if (this.polygon != null) {
    data['polygon'] = this.polygon?.map((v) => v.toJson()).toList();
  }
  if (this.polyline != null) {
    data['polyline'] = this.polyline?.map((v) => v.toJson()).toList();
  }
  data['rotation'] = this.rotation;
  data['type'] = this.type;
  data['visible'] = this.visible;
  data['width'] = this.width;
  data['x'] = this.x;
  data['y'] = this.y;
  return data;
}