Object.fromJson constructor

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

type that contain String value type of avatar image version is contain upadted or latest version left,scaleX,scaleY is double value used to alignment of image fill, src, avatarType contains string value animation Contains object values

Implementation

factory Object.fromJson(Map<String, dynamic> json) => Object(
      type: json["type"],
      version: json["version"],
      left: json["left"]?.toDouble(),
      top: json["top"],
      fill: json["fill"],
      scaleX: json["scaleX"]?.toDouble(),
      scaleY: json["scaleY"]?.toDouble(),
      src: json["src"],
      avatarType: json["avatarType"],
      animation: json["animation"] == null
          ? null
          : Animation.fromJson(json["animation"]),
    );