fromJson static method

MatchFacesComparedFacesPair? fromJson(
  1. dynamic jsonObject
)

Implementation

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

  result.first = MatchFacesComparedFace.fromJson(jsonObject["first"]);
  result.second = MatchFacesComparedFace.fromJson(jsonObject["second"]);
  result.similarity = jsonObject["similarity"] == null
      ? null
      : jsonObject["similarity"].toDouble();
  result.score =
      jsonObject["score"] == null ? null : jsonObject["score"].toDouble();
  result.exception = MatchFacesException.fromJson(jsonObject["exception"]);

  return result;
}