toJson method

  1. @override
Map<String, dynamic> toJson()
override

Serializes this instance to a JSON-compatible map.

Used internally, not intended for direct use by consumers. The map structure may change without notice.

Implementation

@override
Map<String, dynamic> toJson() {
  final Map<String, dynamic> json = <String, dynamic>{};
  json['topleft'] = topLeft.toJson();
  json['bottomright'] = bottomRight.toJson();
  json['type'] = 2;
  return json;
}