Video.fromJson constructor
Implementation
Video.fromJson(Map<String, dynamic> json) {
if (json["rating"] is Map)
this.rating =
json["rating"] == null ? null : Rating.fromJson(json["rating"]);
if (json["version"] is Map)
this.version =
json["version"] == null ? null : Version.fromJson(json["version"]);
if (json["height"] is int) this.height = json["height"];
if (json["duration"] is int) this.duration = json["duration"];
// if (json["thumbs"] is Map)
// this.thumbs =
// json["thumbs"] == null ? null : Thumbs.fromJson(json["thumbs"]);
if (json["owner"] is Map)
this.owner =
json["owner"] == null ? null : VimeoOwner.fromJson(json["owner"]);
if (json["id"] is int) this.id = json["id"];
if (json["embed_code"] is String) this.embedCode = json["embed_code"];
if (json["title"] is String) this.title = json["title"];
if (json["share_url"] is String) this.shareUrl = json["share_url"];
if (json["width"] is int) this.width = json["width"];
if (json["embed_permission"] is String)
this.embedPermission = json["embed_permission"];
if (json["fps"] is int) this.fps = json["fps"];
if (json["spatial"] is int) this.spatial = json["spatial"];
this.liveEvent = json["live_event"];
if (json["allow_hd"] is int) this.allowHd = json["allow_hd"];
if (json["hd"] is int) this.hd = json["hd"];
this.lang = json["lang"];
if (json["default_to_hd"] is int) this.defaultToHd = json["default_to_hd"];
if (json["url"] is String) this.url = json["url"];
if (json["privacy"] is String) this.privacy = json["privacy"];
this.unlistedHash = json["unlisted_hash"];
}