fromJson static method

ElementPosition? fromJson(
  1. dynamic jsonObject
)

Implementation

static ElementPosition? fromJson(jsonObject) {
  if (jsonObject == null) return null;
  var result = new ElementPosition();

  result.docFormat = jsonObject["docFormat"];
  result.width = jsonObject["width"];
  result.height = jsonObject["height"];
  result.dpi = jsonObject["dpi"];
  result.pageIndex = jsonObject["pageIndex"];
  result.inverse = jsonObject["inverse"];
  result.perspectiveTr = jsonObject["perspectiveTr"];
  result.objArea = jsonObject["objArea"];
  result.objIntAngleDev = jsonObject["objIntAngleDev"];
  result.resultStatus = jsonObject["resultStatus"];
  result.angle = jsonObject["angle"] == null ? null : jsonObject["angle"].toDouble();
  result.center = Coordinate.fromJson(jsonObject["center"]);
  result.leftTop = Coordinate.fromJson(jsonObject["leftTop"]);
  result.leftBottom = Coordinate.fromJson(jsonObject["leftBottom"]);
  result.rightTop = Coordinate.fromJson(jsonObject["rightTop"]);
  result.rightBottom = Coordinate.fromJson(jsonObject["rightBottom"]);

  return result;
}